Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tangling in code block with a noweb reference breaks polymode #53

Open
DeadEarnest opened this issue Mar 25, 2025 · 0 comments
Open

Tangling in code block with a noweb reference breaks polymode #53

DeadEarnest opened this issue Mar 25, 2025 · 0 comments

Comments

@DeadEarnest
Copy link

DeadEarnest commented Mar 25, 2025

Tangling when point is outside the code blocks works fine. Also, tangling works fine if there is no <<noweb refs>> inside any code blocks.

This is definitely related to noweb-ref expansion, when a <<ref>> is present but we have :noweb no, tangling works fine.

If you try to run org-babel-tangle when point is in either of the two code blocks, you will get an error message:

unwind-protect: Marker does not point anywhere


:PROPERTIES:
:header-args: :comments no :noweb yes
:END:

#+begin_src clojure :tangle ./test-pm-tangle.cljc
(+ 1 1 1)
<<noweb-ref>>
#+end_src

#+begin_src clojure :noweb-ref noweb-ref
(+ 1 1 1)
#+end_src

After the tangling comes Armageddon:

  1. polymode gets disabled
  2. font-locking resets to nil
  3. current non-hidden org buffer name (without spaces in front of it) vanishes
  4. current window scrolls up a bit, leaving point at the bottom of a screen
  5. if that's the first time I tangle, a mark is set at current point O_o
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant