* [BUG] With custom results keyword ([9.7-pre (release_9.6.24-1407-ga2514c)])
[not found] <565059008.-1716491868.1714382181258.JavaMail.root@zimbra71-e12.priv.proxad.net>
@ 2024-04-29 9:18 ` caroute
2024-04-30 12:53 ` Ihor Radchenko
0 siblings, 1 reply; 2+ messages in thread
From: caroute @ 2024-04-29 9:18 UTC (permalink / raw)
To: emacs-orgmode
Hi
With a custom results keyword the function
org-babel-where-is-src-block-result doesn't find the results block
when the src block is unnamed.
#+name: config
#+begin_src emacs-lisp
(setopt org-babel-results-keyword "RÉSULTATS")
#+end_src
#+RÉSULTATS: config
: RÉSULTATS
#+begin_src emacs-lisp
(+ 1 6)
#+end_src
#+RÉSULTATS:
: 7
#+RÉSULTATS:
: 7
#+RÉSULTATS:
: 7
A possible fix (in ob-core.el):
#+begin_src elisp
(defconst org-babel-result-regexp
(rx (seq bol
(zero-or-more (any "\t "))
(literal (format "#+%s" org-babel-results-keyword))
(opt "["
;; Time stamp part.
(opt "("
(= 4 digit) (= 2 "-" (= 2 digit))
" "
(= 2 digit) (= 2 ":" (= 2 digit))
") ")
;; SHA1 hash.
(group (one-or-more hex-digit))
"]")
":"
(zero-or-more (any "\t "))))
"Regular expression used to match result lines.
If the results are associated with a hash key then the hash will
be saved in match group 1.")
org-babel-result-regexp
#+end_src
#+RÉSULTATS:
: ^[ ]*#\+RÉSULTATS\(?:\[\(?:([[:digit:]]\{4\}\(?:-[[:digit:]]\{2\}\)\{2\} [[:digit:]]\{2\}\(?::[[:digit:]]\{2\}\)\{2\}) \)?\([[:xdigit:]]+\)]\)?:[ ]*
but it doesn't work a run time.
Best regards
Vincek
Emacs : GNU Emacs 29.3 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.24.33, cairo version 1.16.0)
of 2024-03-26
Package: Org mode version 9.7-pre (release_9.6.24-1407-ga2514c @ ~/.emacs30.d/straight/build/org/)
current state:
==============
(setq
org-link-elisp-confirm-function 'yes-or-no-p
org-roam-db-gc-threshold 800000
org-hide-emphasis-markers t
org-bibtex-headline-format-function 'org-bibtex-headline-format-default
org-babel-exp-inline-code-template "src_%lang[%switches%flags]{%body}"
org-roam-mode-hook '(org-roam-bibtex-mode)
org-pretty-table-mode-hook '(org-pretty-table-mode-set-explicitly)
org-roam-node-display-template #("${title:*} ${tags:20}" 11 21 (face org-tag))
org-persist-after-read-hook '(org-element--cache-persist-after-read)
org-format-latex-options '(:foreground default :background default :scale 2.0 :html-foreground
"Black" :html-background "Transparent" :html-scale 1.0 :matchers
("begin" "$1" "$" "$$" "\\(" "\\["))
org-export-before-parsing-hook '(org-attach-expand-links org-babel-jupyter-strip-ansi-escapes)
org-cycle-tab-first-hook '(org-babel-hide-result-toggle-maybe org-babel-header-arg-expand)
org-roam-find-file-hook '(org-roam-buffer--setup-redisplay-h
org-roam--register-completion-functions-h
org-roam--replace-roam-links-on-save-h
org-roam-db-autosync--setup-update-on-save-h)
org-archive-hook '(org-attach-archive-delete-maybe)
org-modern-list '((42 . "•") (43 . "‣"))
org-odt-format-inlinetask-function 'org-odt-format-inlinetask-default-function
org-ascii-format-drawer-function '(closure (t) (_name contents _width) contents)
org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-show-empty-lines
org-cycle-optimize-window-after-visibility-change org-cycle-display-inline-images)
org-persist-before-read-hook '(org-element--cache-persist-before-read)
org-yank-image-file-name-function 'org-yank-image-autogen-filename
org-mode-hook '((closure
(org--rds visual-fill-column-width org-clock-history org-with-time org-defdecode
org-def org-read-date-inactive org-ans2 org-ans1 org-columns-current-fmt-compiled
org-clock-current-task org-clock-effort org-end-time-was-given org-time-was-given
org-state org-agenda-headline-snapshot-before-repeat org-struct-menu
org-last-state org-clock-start-time remember-data-file align-mode-rules-list
org-inlinetask-min-level t)
nil (add-hook 'change-major-mode-hook 'org-fold-show-all 'append 'local))
#[0 "\301\211\x10\207" [imenu-create-index-function org-imenu-get-tree] 2]
flyspell-mode (lambda nil (flycheck-mode 1)) org-modern-mode
(lambda nil (org-bullets-mode 1)) jupyter-org-interaction-mode
(closure
(org--rds org-attach-method org--single-lines-list-is-paragraph
org-element-greater-elements org-agenda-restrict-end org-agenda-restrict-begin
org-agenda-restrict visual-fill-column-width org-clock-history
org-agenda-current-date org-with-time org-defdecode org-def
org-read-date-inactive org-ans2 org-ans1 org-columns-current-fmt-compiled
org-clock-current-task org-clock-effort org-agenda-skip-function
org-agenda-skip-comment-trees org-agenda-archives-mode org-end-time-was-given
org-time-was-given org-log-note-extra org-log-note-purpose org-log-post-message
org-last-inserted-timestamp org-last-changed-timestamp
org-entry-property-inherited-from org-state
org-agenda-headline-snapshot-before-repeat org-agenda-buffer-name
org-agenda-start-on-weekday org-agenda-buffer-tmp-name org-priority-regexp
org-mode-abbrev-table org-element-cache-persistent org-element-cache-version
buffer-face-mode-face org-tbl-menu org-org-menu org-struct-menu org-entities
org-last-state org-id-track-globally org-clock-start-time texmathp-why
remember-data-file org-agenda-tags-todo-honor-ignore-options
calc-embedded-open-mode calc-embedded-open-formula calc-embedded-close-formula
align-mode-rules-list org-emphasis-alist org-emphasis-regexp-components
org-export-registered-backends org-modules crm-separator org-babel-load-languages
org-id-overriding-file-name org-indent-indentation-per-level
org-element--timestamp-regexp org-element-cache-map-continue-from
org-element-paragraph-separate org-agenda-buffer-name org-inlinetask-min-level t)
nil (add-hook 'change-major-mode-hook 'org-fold-show-all 'append 'local))
#[0 "\300\301\302\303\304$\207"
[add-hook change-major-mode-hook org-babel-show-result-all append local] 5]
org-babel-result-hide-spec org-babel-hide-all-hashes org-cdlatex-mode
auto-fill-mode org-babel-jupyter-make-local-aliases org-modern-indent-mode)
org-babel-load-languages '((shell . t) (latex . t) (C . t) (jupyter . t) (maxima . t) (giac . t))
org-roam-ref-annotation-function 'org-roam-ref-read--annotation
org-modern-timestamp nil
org-roam-directory "~/Documents/Memo/roam/"
org-agenda-time-grid '((daily today require-timed) (800 1000 1200 1400 1600 1800 2000) "......"
"----------------")
org-latex-format-drawer-function '(closure
(engrave-faces-latex-mathescape
engrave-faces-current-preset-style
engrave-faces-latex-output-style t)
(_ contents) contents)
org-ellipsis "…"
org-roam-db-node-include-function '(closure (t) nil t)
org-latex-format-headline-function 'org-latex-format-headline-default-function
org-confirm-shell-link-function 'yes-or-no-p
org-html-format-drawer-function '(closure
(htmlize-buffer-places org-html-format-table-no-css
htmlize-css-name-prefix htmlize-output-type htmlize-output-type
htmlize-css-name-prefix t)
(_name contents) contents)
outline-isearch-open-invisible-function 'outline-isearch-open-invisible
org-src-lang-modes '(("jupyter-sage" . sage) ("jupyter-python" . python) ("jupyter-R" . r)
("jupyter-sage" . sage-shell) ("jupyter-python" . python-ts) ("C" . c)
("C++" . c++) ("asymptote" . asy) ("beamer" . latex) ("calc" . fundamental)
("cpp" . c++) ("ditaa" . artist) ("desktop" . conf-desktop)
("dot" . fundamental) ("elisp" . emacs-lisp) ("ocaml" . tuareg)
("screen" . shell-script) ("sqlite" . sql) ("toml" . conf-toml) ("shell" . sh)
("ash" . sh) ("sh" . sh) ("bash" . sh) ("jsh" . sh) ("bash2" . sh)
("dash" . sh) ("dtksh" . sh) ("ksh" . sh) ("es" . sh) ("rc" . sh)
("itcsh" . sh) ("tcsh" . sh) ("jcsh" . sh) ("csh" . sh) ("ksh88" . sh)
("oash" . sh) ("pdksh" . sh) ("mksh" . sh) ("posix" . sh) ("wksh" . sh)
("wsh" . sh) ("zsh" . sh) ("rpm" . sh))
org-babel-results-keyword "RÉSULTATS"
org-agenda-current-time-string "now - - - - - - - - - - - - - - - - - - - - - - - - -"
org-agenda-block-separator 61
org-roam-indirect-buffer-hook '(org-roam--register-completion-functions-h)
org-hugo-date-format "%d-%m-%Y"
)
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [BUG] With custom results keyword ([9.7-pre (release_9.6.24-1407-ga2514c)])
2024-04-29 9:18 ` [BUG] With custom results keyword ([9.7-pre (release_9.6.24-1407-ga2514c)]) caroute
@ 2024-04-30 12:53 ` Ihor Radchenko
0 siblings, 0 replies; 2+ messages in thread
From: Ihor Radchenko @ 2024-04-30 12:53 UTC (permalink / raw)
To: caroute; +Cc: emacs-orgmode
caroute@free.fr writes:
> With a custom results keyword the function
> org-babel-where-is-src-block-result doesn't find the results block
> when the src block is unnamed.
>
>
>
> #+name: config
> #+begin_src emacs-lisp
> (setopt org-babel-results-keyword "RÉSULTATS")
> #+end_src
This is not allowed, as per docstring:
(defcustom org-babel-results-keyword "RESULTS"
"Keyword used to name results generated by code blocks.
It should be \"RESULTS\". However any capitalization may be
^^^^^^^^^^^^^^^^^^^^^
used."
Not a bug.
Canceled.
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-04-30 12:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <565059008.-1716491868.1714382181258.JavaMail.root@zimbra71-e12.priv.proxad.net>
2024-04-29 9:18 ` [BUG] With custom results keyword ([9.7-pre (release_9.6.24-1407-ga2514c)]) caroute
2024-04-30 12:53 ` Ihor Radchenko
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.