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

Favourite Color bug manifest #498

Closed
badonyt opened this issue Sep 2, 2022 · 11 comments
Closed

Favourite Color bug manifest #498

badonyt opened this issue Sep 2, 2022 · 11 comments

Comments

@badonyt
Copy link

badonyt commented Sep 2, 2022

Hello, in the example FAVOURITE-COLOUR, i keep getting a bug which says "Uncaught (in promise) Error: Managed storage manifest not found".

image

Its about the storage manifest, even doe its there.

Note:
Im using the addon in debug mode.

Thanks!

@rebloor
Copy link
Collaborator

rebloor commented Sep 2, 2022

@badonyt did you copy the content for the favourite-colour-examples@mozilla.org.json file from Provisioning managed storage rather than the readme for the example? The example for the file in Provisioning managed storage uses American English rather than British English. Using this copy I found the same error but changing to the version in the example readme fix the issue, and it worked as expected.

@Rob--W
Copy link
Member

Rob--W commented Sep 2, 2022

The (unexpected?) error was encountered before in https://bugzilla.mozilla.org/show_bug.cgi?id=1784446

The discussion there may help with identifying and resolving the problem.

@rebloor
I think that we can improve the documentation; I'll talk with my team next week to determine the desired course of action, and add dev-doc-needed if needed.

@badonyt
Copy link
Author

badonyt commented Sep 2, 2022

What do you mean @rebloor

@rebloor
Copy link
Collaborator

rebloor commented Sep 2, 2022

@badonyt I got the same error as you when I created the manage storage file based on Provisioning managed storage that is:

{
  "name": "favorite-color-examples@mozilla.org",
  "description": "ignored",
  "type": "storage",
  "data":
  {
    "color": "management thinks it should be blue!"
  }
}

However, using the file content in the example's readme description, that is:

{
  "name":  "favourite-colour-examples@mozilla.org",
  "description": "ignored",
  "type": "storage",
  "data": {
    "colour": "management thinks it should be blue!"
  }
}

The extension worked as expected.

@badonyt
Copy link
Author

badonyt commented Sep 2, 2022

i still havent understood how to use the storage permission

@rebloor
Copy link
Collaborator

rebloor commented Sep 2, 2022

@badonyt do you mean the "storage permission" or "storage manifest"? Your reported problem appears to be with the storage manifest. If you still can't get the example to run, could you add screenshots showing the location you stored the favourite-colour-examples@mozilla.org.json file in and a copy of its content? If, however, you need more advice on using "storage permission" try posting a question on the Add-ons forum.

@badonyt
Copy link
Author

badonyt commented Sep 2, 2022

i dont know where to put this: { "name": "favourite-colour-examples@mozilla.org", "description": "ignored", "type": "storage", "data": { "colour": "management thinks it should be blue!" } }

@rebloor
Copy link
Collaborator

rebloor commented Sep 3, 2022

Are you on Mac, Linux, or PC?

@badonyt
Copy link
Author

badonyt commented Sep 3, 2022

PC, WINDOWS 10, sorry for late response

@rebloor
Copy link
Collaborator

rebloor commented Sep 5, 2022

I don't have a Windows 10 machine to check but according to the documentation you should create a registry key with the following name:

HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\ManagedStorage\<name> – with as favourite-colour-examples@mozilla.org.

The key should have a single default value, which is the path to the manifest.

See https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/Native_manifests#windows

@rebloor
Copy link
Collaborator

rebloor commented Sep 7, 2022

Closing, as this doesn't appear to be an issue with the extension example

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

No branches or pull requests

3 participants