Links to Headings Not Created Consistently

When linking to a specific heading in a note, Obsidian does not always create the link correctly. After typing “#” to link to a heading if you select the heading using the arrow keys the link is created correctly. However, if the link is created by typing the heading name until it is the active option the link is created incorrectly. Instead of the title of the note and the heading, it puts the full path to the note even though there is not a duplicate note in the vault.

Steps to reproduce

  1. Type [[ and then a note name to link to.
  2. Type # to link to a heading in the note.
  3. Continue to type the name of the subheading you want to link to until it is the active option,.
  4. Hit return (enter) to create the link.

Expected result

A link that shows the Note Title, #, and the Heading Name.

Actual result

A link that shows the full path to the note as a file name including the .md extension, #, and the heading name.

Environment

  • Operating system: Mac

  • Debug info: SYSTEM INFO:
    Obsidian version: v1.1.12
    Installer version: v1.1.9
    Operating system: Darwin Kernel Version 22.2.0: Fri Nov 11 02:03:51 PST 2022; root:xnu-8792.61.2~4/RELEASE_ARM64_T6000 22.2.0
    Login status: logged in
    Catalyst license: insider
    Insider build toggle: on
    Live preview: on
    Legacy editor: off
    Base theme: dark
    Community theme: none
    Snippets enabled: 0
    Restricted mode: on

RECOMMENDATIONS:
none


Additional information

Here is a screenshot that shows the correct link and then the incorrect link. The correct link is created when navigating headings using the arrow keys. The incorrect link is created by navigating using the keyboard and typing the heading name until it is selected.

1 Like

Related:

1 Like

This is known. Headers was fixed in 1.1.12 (I think) and block embeds will be fixed next build.

I’ll close this one for now.

Headings was fixed in that version, but that’s the version Spduck is using. They’re saying the problem only happens under certain conditions.

Oh yeah good catch.

If you don’t use the auto-complete, the bug is still there. I’ll pass that on to Discord too.

Yes - it only happens when you type the name of the header you want to link and then hit return. If you select the header with arrow keys and then hit return everything is ok.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.