[24299] Add fallback branch for master links #1241
Open
emiliocuestaf wants to merge 10 commits intomasterfrom
Open
[24299] Add fallback branch for master links #1241emiliocuestaf wants to merge 10 commits intomasterfrom
emiliocuestaf wants to merge 10 commits intomasterfrom
Conversation
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
e8f5c5b to
8cbee1c
Compare
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
raulojeda22
reviewed
Apr 1, 2026
docs/conf.py
Outdated
| # Resolve GitHub link branches: env var → current docs branch → default. | ||
| # Computed here so they are available both in the ReadTheDocs clone block and in extlinks. | ||
| fastdds_fallback_branch = resolve_fallback_branch("FASTDDS_BRANCH", docs_branch, "master") | ||
| fastdds_docs_fallback_branch = docs_branch |
Contributor
There was a problem hiding this comment.
To avoid this being None
Suggested change
| fastdds_docs_fallback_branch = docs_branch | |
| fastdds_docs_fallback_branch = resolve_fallback_branch("FASTDDS_DOCS_BRANCH", docs_branch, "master") |
docs/conf.py
Outdated
| return None | ||
|
|
||
|
|
||
| def resolve_fallback_branch(env_var, docs_branch, default="main"): |
Contributor
There was a problem hiding this comment.
Maybe in this repo it makes more sense for the default to be "master"
Suggested change
| def resolve_fallback_branch(env_var, docs_branch, default="main"): | |
| def resolve_fallback_branch(env_var, docs_branch, default="master"): |
docs/conf.py
Outdated
Comment on lines
+523
to
+528
| print("Fallback branches for GitHub links:") | ||
| print(' Fast-DDS: "{}"'.format(fastdds_fallback_branch)) | ||
| print(' Fast-DDS-docs: "{}"'.format(fastdds_docs_fallback_branch)) | ||
| print(' Fast-DDS-Python: "{}"'.format(fastdds_python_fallback_branch)) | ||
| print(' Fast-DDS-Gen: "{}"'.format(fastdds_gen_fallback_branch)) | ||
|
|
Contributor
There was a problem hiding this comment.
This was already printed before
Signed-off-by: Emilio Cuesta <emiliocuesta@eprosima.com>
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.
Description
Fix GitHub links in the documentation to always point to the correct branch instead of defaulting master/main
get_git_branch() now reads READTHEDOCS_VERSION on RTD builds (for branch and tag builds) instead of relying on git name-rev, which returned weird names like "external-1234". There are 3 possible cases for RTD builds now:
@Mergifyio backport 3.5.x 3.4.x 3.2.x 2.14.x
Contributor Checklist
Proversion badge has been added if the documented feature is exclusive to Fast DDS Pro.Reviewer Checklist