Skip to content
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

web-ext ignores manifest browser_specific_settings.gecko.id field #1901

Closed
andreasvirkus opened this issue May 5, 2020 · 1 comment · Fixed by #1974
Closed

web-ext ignores manifest browser_specific_settings.gecko.id field #1901

andreasvirkus opened this issue May 5, 2020 · 1 comment · Fixed by #1974

Comments

@andreasvirkus
Copy link

andreasvirkus commented May 5, 2020

Is this a feature request or a bug?

Bug

What is the current behavior?

I'm trying to sign a new version of an unlisted add-on, but running

web-ext sign --channel unlisted --source-dir dist --api-key $KEY --api-secret $SECRET

Results in

$ web-ext sign --channel unlisted --source-dir dist --api-key $KEY --api-secret $SECRET
Applying config file: ./package.json
Building web extension from /code/klaus/mono-ui/packages/extension/dist
No extension ID specified (it will be auto-generated)
Specifying a channel for a new add-on is unsupported. New add-ons are always in the unlisted channel.
Server response: Duplicate add-on ID found. (status: 400)
FAIL

o: The extension could not be signed
    at /code/klaus/mono-ui/node_modules/web-ext/dist/web-ext.js:1:66636
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
    at E.execute (/code/klaus/mono-ui/node_modules/web-ext/dist/web-ext.js:1:33162)

error Command failed with exit code 1.

Whereas I can successfully sign the new version, when I run the same command but append --id firefox-addon@klausapp.com to the end of web-ext sign.

My manifest.json file includes:

"browser_specific_settings": {
    "gecko": {
      "id": "firefox-addon@klausapp.com",
      "update_url": "https://extension.com/update-manifest.json"
    }
  }

What is the expected or desired behavior?

If the --id flag is not passed in, it should respect the browser_specific_settings.gecko.id field. Actually, the docs even mention that the --id flag should do nothing in this scenario and the identifier from the manifest would be used:

A custom identifier string for the extension. This has no effect if the extension already declares an identifier in its manifest.

Version information (for bug reports)

  • Firefox version: 76.0b8 (64-bit) (N/A?)
  • Your OS and version: MacOS Catalina 10.15.3
  • Paste the output of these commands:
$ node --version && npm --version && web-ext --version

v13.8.0
6.14.4
4.2.0
@rpl rpl changed the title web-ext sign ignores manifest gecko.id field web-ext sign ignores manifest browser_specific_settings.gecko.id field May 6, 2020
@rpl
Copy link
Member

rpl commented May 6, 2020

web-ext isn't currently using the browser_specific_settings property at all, and so this issue isn't actually specific to the web-ext sign command.

There is an open PR (#1791) that is meant to make web-ext to use browser_specific_settings as an alias for the applications manifest property, but it isn't completed yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants