web-ext sign "Your add-on failed validation" in CI
web-ext sign uploaded the XPI to addons.mozilla.org, AMO ran its automated validator, and the validator returned errors. Signing is refused until those validation messages are cleared.
What this error means
web-ext sign prints "Your add-on failed validation" with a count of errors and a link to the validation results, then exits non-zero before producing a signed XPI.
Validation results: https://addons.mozilla.org/...
Your add-on failed validation with 0 errors and 0 warnings.
FAIL
WebExtError: Your add-on failed validation with 2 errors.Common causes
The manifest contains fields AMO rejects
A missing browser_specific_settings.gecko.id, an invalid permissions entry, or a disallowed key fails the validator before signing.
Bundled code trips a validation error
AMO flags issues such as remote-hosted code or disallowed APIs as hard errors, not warnings, so signing stops.
How to fix it
Open the validation report and fix each error
- Follow the "Validation results" URL printed by web-ext.
- Resolve every item marked as an error (warnings do not block signing).
- Re-run
web-ext signafter rebuilding the corrected source.
web-ext lint --source-dir dist
web-ext sign --source-dir dist --channel unlistedAdd the required gecko add-on id
Listed and self-distributed add-ons need a stable id so AMO can validate and sign them.
"browser_specific_settings": {
"gecko": { "id": "my-addon@example.com" }
}How to prevent it
- Run
web-ext lintin CI beforeweb-ext signso errors surface early. - Keep a stable gecko add-on id in the manifest.
- Avoid remote-hosted code, which AMO rejects on validation.