Hi Ihor,
Ihor Radchenko <yanta...@posteo.net> writes: > > This is most likely something about my current system setup - I can > reproduce with other Org mode and Emacs versions. But I have no clue > what is the cause. I'm getting the same as you with your MWE. The tag, used by ob-comint async, is: "/tmp/babel-zqh04P/python-GL5N5d" but, in "/tmp/bug.org" it becomes: "babel-zqh04P/python-GL5N5d" (`org-babel-result-to-file' transformed it into a simpler relative path). The filter `org-babel-comint-async-filter' cannot spot it, because it's searching for the exact string "/tmp/babel-zqh04P/python-tXsdFw". Here is how to reproduce: #+begin_src elisp :results table (let* ((tag "/tmp/babel-zqh04P/python-tXsdFw") (repro (lambda (fn) (let ((lnk (with-temp-buffer (org-mode) (let* ((default-directory "/tmp") (buffer-file-name fn) (cbuf (clone-indirect-buffer "tmp" nil))) (with-current-buffer cbuf (org-babel-result-to-file tag)))))) (list fn (not (eq nil (string-match-p (regexp-quote tag) lnk))) lnk))))) (cons (list "Filename" "string-match-p" "Org link") (cons 'hline (mapcar repro (list "/tmp/bug.org" "/somewhere/else/bug.org"))))) #+end_src #+RESULTS: | Filename | match-p | Org link | |-------------------------+---------+-----------------------------------------------| | /tmp/bug.org | nil | [[file:babel-zqh04P/python-tXsdFw]] | | /somewhere/else/bug.org | t | [[file:../../tmp/babel-zqh04P/python-tXsdFw]] | I don't know what a proper fix would be though. Hoping this help, Bruno > > Emacs : GNU Emacs 30.0.50 (build 4, x86_64-pc-linux-gnu, GTK+ Version > 3.24.39, cairo version 1.18.0) > of 2024-01-30 > Package: Org mode version 9.7-pre (release_9.6.17-1131-gc9ed03.dirty @ > /home/yantar92/.emacs.d/straight/build/org/) > -- > 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>