New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable localisation when SOURCE_DATE_EPOCH
is set
#10949
Merged
AA-Turner
merged 30 commits into
sphinx-doc:master
from
jayaddison:issue-9778/reproducible-inventory-file-build
Apr 7, 2023
Merged
Changes from all commits
Commits
Show all changes
30 commits
Select commit
Hold shift + click to select a range
61ac761
Add test coverage to confirm that inventory file contents differ per-…
jayaddison 2592766
Use lazy-loading for all gettext-translated resource strings
jayaddison c1d2473
Add test coverage to confirm that inventory contents are identical (r…
jayaddison babbb27
Disable localization of objects.inv (inventory files) when the build …
jayaddison f17cf4a
Fixup: mypy: relocate type hint
jayaddison ed704c3
Fixup: mypy: remove unused type-ignore comment
jayaddison fae1b1a
Cleanup / readability: de-duplicate test code for localized inventory…
jayaddison 1cb30df
Make use of monkeypatch context management more explicit
jayaddison b300d8b
Permit custom directory prefix for test app during reproducible build…
jayaddison 3667842
During reproducible build inventory localization test case, verify th…
jayaddison 336ea1c
Use ISO-639-3 'undetermined' language code during reproducible builds…
jayaddison 9b0acb3
Add explanatory comment
jayaddison 873a350
Add test coverage for resource translation when language is empty and…
jayaddison 121fc1d
Add test coverage for resource translation during reproducible builds…
jayaddison 6585538
Retain support for pluralized resource translation by adding support …
jayaddison 04f7058
Typing: be a bit stricter about providing a str-type argument to the …
jayaddison b264cb2
Revert "Fixup: mypy: remove unused type-ignore comment"
jayaddison 8377534
Typing: only invoke str typecasting for localized items within writer…
jayaddison aa7e165
Typing: be a bit stricter about joining str-type values within domain…
jayaddison bb02c92
Remove support for ngettext (pluralized forms)
jayaddison 4587f76
Merge branch 'master' into issue-9778/reproducible-inventory-file-build
jayaddison 2fc96ec
Merge branch 'master' into issue-9778/reproducible-inventory-file-build
jayaddison 15edb4c
Merge branch 'master' into issue-9778/reproducible-inventory-file-build
AA-Turner 1fb6ccc
Merge branch 'master' into issue-9778/reproducible-inventory-file-build
jayaddison 6a880ad
Fixup: assert on sorted directory contents in test_util_inventory.tes…
jayaddison 52a7104
Merge branch 'master' into issue-9778/reproducible-inventory-file-build
jayaddison a73459b
Merge branch 'master' into issue-9778/reproducible-inventory-file-build
AA-Turner dd41420
CHANGES: Add bugfix entry
jayaddison 426e08e
Merge branch 'master' into issue-9778/reproducible-inventory-file-build
jayaddison a9c9100
Reword CHANGES entry to be more general
AA-Turner File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Binary file not shown.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
msgid "Hello world" | ||
msgstr "Tere maailm" |
This file contains 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
This file contains 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
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This may seem overly complicated compared to, for example:
...which would achieve similar results.
My thinking here is that the presence/absence of
SOURCE_DATE_EPOCH
should, ideally, minimize the effect on the control flow of the program and build.If the environment variable results in completely different control flows, then arguably the program being built is different.
My sense is that the ideal roadmap for
SOURCE_DATE_EPOCH
is to introduce it as-required to achieve reproducible builds, but also to keep in mind that it should be removed in future when no-longer-required.(and to be precise in the case of
sphinx
: a potential time for removal would be when it's possible to perform deterministic documentation builds in all-available-locales -- meaning that the software would be packaged for universal applicability and should build into an identical artefact regardless of the build host's locale)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it is realistic to achive this, I think it's a good goal -- would you be happy to open a new issue to track the 'locale independent' workstream?
A
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From searching around before doing that, I think that this would be approximately the same as #788 (although that is specific to HTML, currently).
I'll spend some more time reading before deciding whether to add more comments there or to open a separate ticket.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, I appreciate your help here!
A