Skip to content

Fix: pin breathe to <5 due to potential name conflicts - #1615

Merged
mgovers merged 1 commit into
mainfrom
pgm/feature/pin-breathe-4
Sep 30, 2026
Merged

mgovers merged 1 commit into
mainfrom
pgm/feature/pin-breathe-4

Conversation

@mgovers

@mgovers mgovers commented Sep 30, 2026 •

Copy link
Copy Markdown
Member

The C API docs have been broken since v1.13.179 (#1612) because Breathe had a major version bump that seems to be incompatible with our setup.

The docs build will raise a warning (we don't have warnings-as-errors enabled yet in our readthedocs build) and the docs will have the following warning

image

This seems to be caused by the fact that breathe 5 uses the Doxygen-generated shortname, which is the shortest unique name that matches a file. For files with a unique name (e.g., basics.h), that is simply the file name.

However, this is not future compatible, as adding a new file with the same name in another directory will cause the Doxygen-generated shortname to change to a path, e.g. power_grid_model_c/basics.h ad foo/basics.h, effectively breaking the internal linkage if we depend purely on the short name basics.h. Therefore, the docs will not be stable under addition of new files, which is bound to happen.

  • This is probably not directly a problem for the C API (as they .h ending is most likely restricted to just the C API headers)
  • However, this is already an issue for locally generated docs for the C++ API, which may contain names that occur in both the C++ API and in the core (e.g., model.hpp).
  • For now, readthedocs builds are unaffected, as we do not formally expose the C++ API docs there yet, but if we decide to do so in the future, this will become a real problem.

Related

Underlying issue reported to Breathe in breathe-doc/breathe#1084

Signed-off-by: Martijn Govers <Martijn.Govers@Alliander.com>
@mgovers mgovers self-assigned this Sep 30, 2026
@mgovers mgovers added bug Something isn't working documentation Improvements or additions to documentation labels Sep 30, 2026
@sonarqubecloud

Copy link
Copy Markdown

@figueroa1395 figueroa1395 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Docs build successfully now.

@mgovers
mgovers enabled auto-merge September 30, 2026 11:01
@mgovers
mgovers added this pull request to the merge queue Sep 30, 2026
Merged via the queue into main with commit b240740 Sep 30, 2026
34 of 35 checks passed
@mgovers
mgovers deleted the pgm/feature/pin-breathe-4 branch September 30, 2026 12:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants