Skip to content

Conversation

@nvdaes
Copy link
Contributor

@nvdaes nvdaes commented Oct 13, 2025

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
Copy link
Contributor Author

nvdaes commented Nov 9, 2025

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
Copy link
Contributor Author

nvdaes commented Nov 9, 2025

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
Copy link
Contributor Author

nvdaes commented Nov 9, 2025

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
Copy link
Contributor Author

nvdaes commented Nov 9, 2025

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

@seanbudd seanbudd self-requested a review November 11, 2025 02:48
@seanbudd seanbudd marked this pull request as draft November 11, 2025 05:30
@seanbudd
Copy link
Member

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

@nvdaes
Copy link
Contributor Author

nvdaes commented Nov 11, 2025

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

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

@nvdaes
Copy link
Contributor Author

nvdaes commented Nov 11, 2025

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
Copy link
Contributor Author

nvdaes commented Nov 12, 2025

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
Copy link
Member

@seanbudd seanbudd left a comment

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

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
Copy link
Contributor Author

nvdaes commented Nov 12, 2025

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.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants