Skip to content

fix: docs publication (multiversion)#435

Open
dgarcia360 wants to merge 3 commits intoscylladb:mainfrom
dgarcia360:fix-publication
Open

fix: docs publication (multiversion)#435
dgarcia360 wants to merge 3 commits intoscylladb:mainfrom
dgarcia360:fix-publication

Conversation

@dgarcia360
Copy link
Copy Markdown
Contributor

Closes #433

Motivation

The jsdoc-include extension was looking for JSDoc HTML in the wrong folder during multiversion builds, so API pages came out empty on the published site.

How to test

Run the following locally:

rm -rf ../public/docs && make multiversion

This should generate the API reference correctly, whereas previously it did not. Previously, it only worked if you ran make preview before.

After merging, verify that the docs are generated at nodejs-rs-driver.docs.scylladb.com/stable/api/Client.html

The jsdoc-include extension was looking for JSDoc HTML in the wrong folder during multiversion builds, so API pages came out empty on the published site.
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes multiversion docs publication by correcting how the jsdoc-include Sphinx extension resolves the JSDoc HTML output directory, so API reference pages aren’t rendered empty on the published site.

Changes:

  • Resolve jsdoc_html_dir relative to env.srcdir (instead of env.app.confdir) to match sphinx-multiversion build behavior.
  • Minor docstring formatting adjustment in _resolve_jsdoc_dir.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 60 to +61
rel = config.jsdoc_html_dir or "../../public/docs"
return Path(env.app.confdir, rel).resolve()
return Path(env.srcdir, rel).resolve()
Copy link

Copilot AI Apr 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Switching the base from env.app.confdir to env.srcdir changes what jsdoc_html_dir is relative to. Please update the function/doc comments (and any referenced docs) to reflect the new behavior so users don’t keep configuring it “relative to conf.py” while the code resolves it relative to the Sphinx source dir (which may differ under sphinx-multiversion / -c).

Copilot uses AI. Check for mistakes.
dgarcia360 and others added 2 commits April 14, 2026 14:58
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
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.

Api documentation has no content

2 participants