Write doxygen XML outside the published tree, re-enable doxystat - #36
Open
meshinspector-agent[bot] wants to merge 1 commit into
Open
Write doxygen XML outside the published tree, re-enable doxystat#36meshinspector-agent[bot] wants to merge 1 commit into
meshinspector-agent[bot] wants to merge 1 commit into
Conversation
Doxygen's XML output is consumed only by the doxystat metrics, but XML_OUTPUT was a relative path, so it resolved against OUTPUT_DIRECTORY and the deploy step's `git add -A` committed ~940 MB of it into the published site. Point it at a git-ignored directory instead, and re-enable show_statistics() so the metrics land in doxystat-metrics.txt for CI to upload as an artifact.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
XML_OUTPUTwas a relative path, so Doxygen resolved it againstOUTPUT_DIRECTORY— the published directory — and the deploy step'sgit add -Acommitted the XML. Nothing reads it except the doxystat metrics, which are themselves disabled.Changed
update_doc.sh:XML_OUTPUT→ an absolute, git-ignoreddoxystat-xml/at the repo root (both ingenerate_documentation_simple()and the currently-unusedgenerate_documentation()).show_statistics(), reading that dir andtee-ing todoxystat-metrics.txtso CI can upload it as an artifact..gitignore: addeddoxystat-xml/,doxystat-metrics.txt,/stats.txt; widenedMeshLib/xml/→MeshLib/xml*/(same underdev/) so a regressed path can't leak in.Surfaced by re-enabling doxystat — dead code until now, so neither was ever hit:
doxystat/{index,compound}.py(generateDS output) needsix, and their namespace handling only works withlxml; thexml.etreefallback they import raisesAttributeError: … has no attribute 'nsmap'. Hence the newscripts/doxystat/requirements.txtplus a guarded install.metrics.pywritesstats.txtinto the cwd — i.e. the repo root, a new published junk file. It now runs from inside the XML dir, so each module'sstats.txtlands beside its XML.Metrics can never fail the docs run: missing XML or uninstallable dependencies warn and return 0.
Deleting the already-committed
xml_*anddev/test/is a separate change that must land after this one, or the next docs run re-commits the XML.Verification
No doxygen 1.14 or bindings artifacts available locally, so I drove the real
update_doc.shin a sandbox against a stubdoxygenimplementing the documented rule ("if a relative path is entered the value ofOUTPUT_DIRECTORYwill be put in front of it")..gitignore):git add -AstagesMeshLib/dev/xml_Cpp/*andMeshLib/dev/xml_Py/*— bug reproduced.XML_OUTPUT=[/…/doxystat-xml/xml_Cpp]; the published tree has noxml*directory;git add -Astages onlyMeshLib/dev/html/**.git check-ignore -vconfirms coverage ofdoxystat-xml/,doxystat-metrics.txt,MeshLib/xml_*/,MeshLib/dev/xml_*/and the oldMeshLib/xml/.metrics.pyreally parses the out-of-tree XML —doxystat-metrics.txtgets aClasses: 1 (1 documented)table per module.[WARN] no doxygen XML for Py, skipping its metrics, rc=0; dependencies unavailable →[WARN] could not install doxystat dependencies, skipping metrics, rc=0.bash -nclean.Not tested: a real doxygen 1.14 run. HTML generation is untouched, but the first CI docs run is the real check — worth confirming there that
doxystat-metrics.txtis non-empty and/dev/pages still render.No CI labels: this repo has no workflows.