Skip to content

[#12] Resolve Sphinx section label anchors when indexing#14

Open
joubu wants to merge 1 commit intoJacobCoffee:mainfrom
joubu:issue_12
Open

[#12] Resolve Sphinx section label anchors when indexing#14
joubu wants to merge 1 commit intoJacobCoffee:mainfrom
joubu:issue_12

Conversation

@joubu
Copy link

@joubu joubu commented Feb 3, 2026

Description

Extend anchor extraction to detect Sphinx section labels and parent

IDs. This fixes missing anchors for references such as :ref: targets where the ID is not on the heading itself but provided via a label span or section wrapper.

Related Issue

Fixes #12

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Code refactoring (no functional changes)
  • CI/CD changes
  • Dependencies update

Checklist

  • I have performed a self-review of my code
  • I have added/updated tests that prove my fix is effective or my feature works
  • I have updated the documentation accordingly
  • I have added a changelog entry (if applicable)
  • All CI checks pass
  • My changes generate no new warnings

Testing

Test Configuration:

  • Python version:
  • Sphinx version:
  • OS:

Test Steps:
1.
2.
3.

Screenshots


Extend anchor extraction to detect Sphinx section labels and parent
<section> IDs. This fixes missing anchors for references such as
:ref: targets where the ID is not on the heading itself but provided
via a label span or section wrapper.
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

Successfully merging this pull request may close these issues.

[Bug]: Anchors not set

1 participant