Skip to content

docs: enable source links in API reference#1596

Merged
skrawcz merged 1 commit into
apache:mainfrom
RaghunandanKumar:docs/add-viewcode-source-links
May 28, 2026
Merged

docs: enable source links in API reference#1596
skrawcz merged 1 commit into
apache:mainfrom
RaghunandanKumar:docs/add-viewcode-source-links

Conversation

@RaghunandanKumar
Copy link
Copy Markdown
Contributor

Summary

Enable sphinx.ext.viewcode in the Sphinx docs config so generated API reference pages include links back to the source code.

Test Plan

  • Attempted local Sphinx build
  • Blocked locally by host packaging/env mismatch (pip on this machine does not support the repo's --group docs install flow)

@skrawcz
Copy link
Copy Markdown
Contributor

skrawcz commented May 24, 2026

@RaghunandanKumar this doesn't seem to work as intended? The docs built so I can merge, but the staged docs doesn't seem to have source code links?

@RaghunandanKumar
Copy link
Copy Markdown
Contributor Author

I re-verified locally with same build CI uses, and generated API reference does include links now.

For example, built contains links like:

check also passes on this PR, so I think current staged page is serving stale/pre-change artifact rather than output from this branch.

@RaghunandanKumar
Copy link
Copy Markdown
Contributor Author

I re-verified locally with same dirhtml build CI uses, and generated API reference does include [source] links now.

For example, built reference/drivers/Driver/index.html contains links like:
../../../_modules/hamilton/driver/#Builder

build-docs check also passes on this PR, so I think current staged page is serving stale/pre-change artifact rather than output from this branch.

@skrawcz skrawcz merged commit 78ec446 into apache:main May 28, 2026
1 check passed
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.

2 participants