Skip to content
This repository was archived by the owner on Mar 19, 2026. It is now read-only.

Add ability to provide changelog for add-ons#52

Merged
seanbudd merged 75 commits into
nvaccess:mainfrom
nvdaes:changelog
Nov 12, 2025
Merged

Add ability to provide changelog for add-ons#52
seanbudd merged 75 commits into
nvaccess:mainfrom
nvdaes:changelog

Conversation

@nvdaes

@nvdaes nvdaes commented Oct 13, 2025

Copy link
Copy Markdown
Contributor

This pull request adds support for a new changelog field to the add-on manifest and submission JSON schema, enabling tracking and validation of changes between add-on versions. The changes ensure that both the manifest and all related processing, validation, and test code can handle the new changelog field, including its translation in localized manifests.

Schema and Manifest Updates:

  • Added a changelog field to the AddonManifest class in _validate/addonManifest.py, and updated the manifest parsing logic to support reading and translating this field. [1] [2]
  • Updated the JSON schema in _validate/addonVersion_schema.json to define the changelog field for both the base and translations, including examples and descriptions. [1] [2]
  • Updated test data and example manifests to include the new changelog field. [1] [2]

Data Model and Processing:

  • Updated the AddonData dataclass and related processing functions in _validate/createJson.py to include changelog and its translations, handling None values properly. [1] [2] [3]
  • Updated regeneration logic in _validate/regenerateTranslations.py to process the changelog field for both the main manifest and translations.

Validation Logic:

  • Added a new validation function checkChangelogMatches in _validate/validate.py to ensure the submission changelog matches the manifest, and integrated it into the submission validation pipeline. [1] [2]

Tests:

  • Added unit tests to verify validation of the changelog field, and updated existing tests and test data to include the new field and its expected values. [1] [2]

These changes collectively introduce the changelog field into the add-on manifest and submission workflow, ensuring proper handling, validation, and testing throughout the codebase.

@nvdaes

nvdaes commented Nov 9, 2025

Copy link
Copy Markdown
Contributor Author

Test with an add-on including a changelog not translated: pass. The generated json file includes translated summary and description, and the changelog, but the changelog is not included in translations:

https://github.com/nvdaes/addon-datastore/actions/runs/19206166951/job/54901672327

@nvdaes

nvdaes commented Nov 9, 2025

Copy link
Copy Markdown
Contributor Author

Test submitting an add-on with a translated changelog: pass. The generated json file contains the changelog and the translated changelog for es:

https://github.com/nvdaes/addon-datastore/actions/runs/19206387890/job/54902181767

@nvdaes

nvdaes commented Nov 9, 2025

Copy link
Copy Markdown
Contributor Author

Test submitting an add-on without a changelog (and without translations): Pass. The generated json file contains a line with the following contents, which doesn't produce errors:

"translations": []

https://github.com/nvdaes/addon-datastore/actions/runs/19206656030/job/54902812136#step:15:40

@nvdaes

nvdaes commented Nov 9, 2025

Copy link
Copy Markdown
Contributor Author

@seanbudd, I think this is ready for review and perhaps merging.

@seanbudd seanbudd self-requested a review November 11, 2025 02:48
Comment thread _validate/regenerateTranslations.py Outdated
@seanbudd seanbudd marked this pull request as draft November 11, 2025 05:30
@seanbudd

Copy link
Copy Markdown
Member

This looks good to me, just need the copilot suggestions implemented

@nvdaes

nvdaes commented Nov 11, 2025

Copy link
Copy Markdown
Contributor Author

Test with an add-on with a translated changelog: pass

https://github.com/nvdaes/addon-datastore/actions/runs/19277774486/job/55121659461

@nvdaes

nvdaes commented Nov 11, 2025

Copy link
Copy Markdown
Contributor Author

Sorry, unfortunately, the changelog, which should be translated into Spanish, is in English in the json file. Seems a regression introduced by the parseConfigValue function or its application. I'll look at this in the next days.

@nvdaes

nvdaes commented Nov 12, 2025

Copy link
Copy Markdown
Contributor Author

Test with an add-on with translated changelog: pass, and the changelog is translated in the json file:

https://github.com/nvdaes/addon-datastore/actions/runs/19287166274/job/55150234283#step:15:40

@seanbudd seanbudd marked this pull request as ready for review November 12, 2025 05:48

@seanbudd seanbudd 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.

Nice, thanks @nvdaes

@seanbudd seanbudd merged commit d3d933a into nvaccess:main Nov 12, 2025
2 checks passed
@CyrilleB79

Copy link
Copy Markdown

Thanks for this nice work!

Will the data be regenerated for existing add-ons of the store that already include a change log in their manifest?

@nvdaes

nvdaes commented Nov 12, 2025

Copy link
Copy Markdown
Contributor Author

Cyrille wrote:

Will the data be regenerated for existing add-ons of the store that already include a change log in their manifest?

As far as I know, just translations (including translated changelogs), will be regenerated, but not all add-on data, i.e., if an add-on includes a changelog, but it was submitted before this PR is merged, the original changelog won't be available when data is regenerated in the future.
Unless @seanbudd has a different feedback, this is what I know.

@seanbudd

Copy link
Copy Markdown
Member

@nvdaes - it might be worth updating the regenerateTranslations script to be a generic "regenerateFromManifest" script.
We don't really need the original function of it, and this new function will cover more generic future use cases.
Update it to:

  • download the add-on
  • check the SHA
  • regenerate the full JSON file from the add-on manifest, including changelogs and translations.
  • Use the old JSON file for the add-on store only fields not in the manifest.

@nvdaes

nvdaes commented Nov 13, 2025

Copy link
Copy Markdown
Contributor Author

@seanbudd and @CyrilleB79 , I'll try to create a PR to regenerate the full json file.

@CyrilleB79

Copy link
Copy Markdown

@nvdaes, no need to spend time on this regarding my add-ons. There will be new releases in any case when 2026.1 stable will be released.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants