Subject: 29.0.50; org-mode: modification-time error with git controled file

From: TAKAHASHI Yoshio <[email-masked]>
Date: Sun, 24 Oct 2021 11:18:07 +0900

Hi,

With git controled file,
{{{modification-time(%Y-%02m-%02dT%02H:%02M:%02S+09:00, 1)}}}
causes "Wrong type argument: stringp, " error.

`org-macro--vc-modified-time' in org-macro.el should pass list of FILE
to `vc-call', because `vc-git-print-log' expects list of file as its 1st
argument.

diff --git a/lisp/org/org-macro.el b/lisp/org/org-macro.el
index b8d3373418..9e70844963 100644
--- a/lisp/org/org-macro.el
+++ b/lisp/org/org-macro.el
@@ -368,7 +368,7 @@ org-macro--vc-modified-time
 	    date)
 	(unwind-protect
 	    (progn
-	      (vc-call print-log file buf nil nil 1)
+	      (vc-call print-log (list file) buf nil nil 1)
 	      (with-current-buffer buf
 		(vc-exec-after
 		 (lambda ()

In GNU Emacs 29.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20, cairo version 1.16.0)
 of 2021-10-23 built on LAPTOP-89LTAUNV
Repository revision: fbf57cbd44f3cf18fd22be4ea0b448bfdf22de25
Repository branch: master
Windowing system distributor 'HC-Consult', version 11.0.12009000
System Description: Ubuntu 20.04.3 LTS

Configured using:
 'configure 'CC=ccache gcc' 'CFLAGS=-O2 -march=native -mtune=native
 -pipe -s' 'LDFLAGS=-pipe -s' --enable-link-time-optimization
 --with-modules --with-cairo --without-compress-install --without-pop
 --prefix=/opt/emacs'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 M17N_FLT MODULES NOTIFY
INOTIFY PDUMPER PNG RSVG SECCOMP SOUND THREADS TIFF TOOLKIT_SCROLL_BARS
X11 XDBE XIM XPM GTK3 ZLIB

Important settings:
  value of $LC_MESSAGES: C
  value of $LC_TIME: C
  value of $LANG: ja_JP.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Group

Minor modes in effect:
  gnus-topic-mode: t
  global-git-commit-mode: t
  magit-auto-revert-mode: t
  gnus-undo-mode: t
  shell-dirtrack-mode: t
  auto-insert-mode: t
  recentf-mode: t
  marginalia-mode: t
  company-prescient-mode: t
  company-posframe-mode: t
  company-quickhelp-mode: t
  company-quickhelp-local-mode: t
  global-company-mode: t
  company-mode: t
  override-global-mode: t
  savehist-mode: t
  vertico-mode: t
  prescient-persist-mode: t
  delete-selection-mode: t
  cua-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  buffer-read-only: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
/home/tkh/.emacs.d/elpa/transient-20211013.2148/transient hides /opt/emacs/share/emacs/29.0.50/lisp/transient

Features:
(shadow emacsbug mm-archive smiley gnus-async gnus-bcklg gnus-salt
gnus-dup gnus-ml disp-table qp pop3 utf-7 gnutls rfc2104 network-stream
nsm mailalias smtpmail sendmail sort gnus-cite mail-extr footnote
gnus-topic nndraft nnmh nnagent nnml nnnil gnus-agent gnus-srvr
gnus-score score-mode nnvirtual gnus-msg nntp gnus-cache whitespace
magit-patch magit-subtree magit-gitignore magit-ediff ediff ediff-merg
ediff-mult ediff-wind ediff-diff ediff-help ediff-init ediff-util
magit-extras smartparens-lua lua-mode magit-bookmark magit-submodule
magit-obsolete magit-blame magit-stash magit-reflog magit-bisect
magit-push magit-pull magit-fetch magit-clone magit-remote magit-commit
magit-sequence magit-notes magit-worktree magit-tag magit-merge
magit-branch magit-reset magit-files magit-refs magit-status magit
magit-repos magit-apply magit-wip magit-log which-func imenu magit-diff
smerge-mode diff git-commit magit-core magit-autorevert autorevert
filenotify magit-margin magit-transient magit-process with-editor
magit-mode transient magit-git magit-section magit-utils crm
bug-reference vc-annotate vc-filewise edebug shortdoc log-view log-edit
pcvs-util add-log vc-dir ewoc ibuf-ext ibuffer ibuffer-loaddefs vc-mtn
vc-hg vc-bzr vc-src vc-sccs vc-svn vc-cvs vc-rcs deadgrep spinner
mule-util vc misearch multi-isearch help-fns radix-tree cl-print debug
backtrace cus-start cus-load time-stamp org-variable-pitch face-remap
org-indent image-file image-converter ffap ol-eww eww xdg mm-url
ol-rmail ol-mhe ol-irc ol-info ol-gnus nnselect gnus-search eieio-opt
speedbar ezimage dframe gnus-art mm-uu mml2015 mm-view mml-smime smime
dig gnus-sum gnus-group gnus-undo gnus-start gnus-dbus dbus gnus-cloud
nnimap nnmail mail-source utf7 netrc nnoo parse-time gnus-spec gnus-int
gnus-range gnus-win gnus nnheader ol-docview doc-view jka-compr
image-mode exif ol-bibtex ol-bbdb ol-w3m ol-doi org-link-doi dired-aux
vertico-directory cursor-sensor smartparens-config smartparens-org
smartparens-text smartparens goto-addr hl-line elfeed-show elfeed-search
vc-git diff-mode vc-dispatcher message rmc rfc822 mml mml-sec gnus-util
rmail rmail-loaddefs mm-decode mm-bodies mm-encode mail-parse rfc2231
rfc2047 rfc2045 mm-util ietf-drums mail-prsvr mailabbrev mail-utils
gmm-utils mailheader shr puny svg dom elfeed-csv elfeed elfeed-curl
elfeed-log elfeed-db elfeed-lib thingatpt url-queue xml-query xml
recentf-ext pdf-loader pdf-tools-autoloads org-journal org-crypt epa
derived epg rfc6068 epg-config cal-iso org-make-toc org-id org-clock
ob-shell shell ob-ditaa skeletor compile let-alist f
ox-sidenote-right-html ox-sidenote-right-latex ox-pandoc ht ox-org
ox-extra ox-odt rng-loc rng-uri rng-parse rng-match rng-dt rng-util
rng-pttrn nxml-parse nxml-ns nxml-enc xmltok nxml-util ox-latex
ox-icalendar org-agenda org-refile ox-html table ox-ascii ox-publish ox
org-element avl-tree org-inlinetask migemo japanese-holidays holidays
hol-loaddefs generic-x noflet dash cl-indent ls-lisp autoinsert affe
server consult-vertico consult recentf tree-widget wid-edit bookmark
text-property-search pp marginalia use-package-ensure company-prescient
company-posframe use-package-diminish company-quickhelp pos-tip
company-oddmuse company-keywords company-etags etags fileloop generator
xref project company-gtags company-dabbrev-code company-dabbrev
company-files company-clang company-capf company-cmake company-semantic
company-template company-bbdb company edmacro kmacro
use-package-bind-key bind-key savehist orderless vertico pcase prescient
delsel cua-base modus-vivendi-theme modus-operandi-theme modus-themes
use-package-core wdired dired dired-loaddefs mozc-cursor-color
mozc-cand-posframe s posframe mozc-im mozc cl-extra help-mode org ob
ob-tangle ob-ref ob-lob ob-table ob-exp org-macro org-footnote org-src
ob-comint org-pcomplete pcomplete comint ansi-color ring org-list
org-faces org-entities noutline outline easy-mmode org-version
ob-emacs-lisp ob-core ob-eval org-table oc-basic bibtex iso8601
time-date ol rx org-keys oc org-compat advice org-macs org-loaddefs
format-spec find-func cal-menu calendar cal-loaddefs kinsoku info
package browse-url url url-proxy url-privacy url-expand url-methods
url-history url-cookie url-domsuf url-util mailcap url-handlers
url-parse auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs
password-cache json map url-vars seq gv subr-x byte-opt bytecomp
byte-compile cconv cl-loaddefs cl-lib japan-util iso-transl tooltip
eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type
elisp-mode mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd
fontset image regexp-opt fringe tabulated-list replace newcomment
text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow
isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax
font-core term/tty-colors frame minibuffer cl-generic cham georgian
utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean
japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray
cl-preloaded nadvice button loaddefs faces cus-face macroexp files
window text-properties overlay sha1 md5 base64 format env code-pages
mule custom widget hashtable-print-readable backquote threads dbusbind
inotify lcms2 dynamic-setting system-font-setting font-render-setting
cairo move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)

Memory information:
((conses 16 882104 88540)
 (symbols 48 45055 44)
 (strings 32 174875 23928)
 (string-bytes 1 6218550)
 (vectors 16 127440)
 (vector-slots 8 1966522 97186)
 (floats 8 1011 1235)
 (intervals 56 119926 2243)
 (buffers 992 62))