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

Add: store the reason why db failed #550

Merged
merged 3 commits into from
Nov 11, 2018
Merged

Add: store the reason why db failed #550

merged 3 commits into from
Nov 11, 2018

Conversation

eight04
Copy link
Collaborator

@eight04 eight04 commented Nov 8, 2018

Fixes #546

It saves the validation error so we can inspect it with

chromeLocal.getValue('dbInChromeStorageReason')

However, I don't know how to test this branch. Is there a way to make indexed DB fail manually?

@Mottie
Copy link
Member

Mottie commented Nov 9, 2018

Should we also open a modal showing the error?

@eight04
Copy link
Collaborator Author

eight04 commented Nov 9, 2018

In the manager? I think it won't work if the user doesn't open the manager page.

@Mottie
Copy link
Member

Mottie commented Nov 9, 2018

What about an alert then?

@eight04
Copy link
Collaborator Author

eight04 commented Nov 9, 2018

You can't use alert in the background page in Firefox.

@Mottie
Copy link
Member

Mottie commented Nov 11, 2018

I'm not sure how to test this PR. What if we also store the URL (or just the domain; to ensure privacy) causing the error so we know the source? I thought I saw an error pop up when the Firefox add-ons manager page was open, but now I can't reproduce it.

@eight04
Copy link
Collaborator Author

eight04 commented Nov 11, 2018

The validation only happens when the DB is initializing i.e. when the extension startups, so there is no URL that could be recorded. I also don't think the error would relate to a specific page because db.js is used in the background page.

I'm not sure how to test this PR.

Then we just merge it?

@Mottie Mottie merged commit b622ebc into master Nov 11, 2018
@Mottie Mottie deleted the dev-fallback-reason branch November 11, 2018 13:09
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.

2 participants