3box / 3box-js

3Box JavaScript SDK: User identities, storage, messaging
MIT License
207 stars 65 forks source link

Box.create should not throw "denied permission" exception #890

Open dkent600 opened 3 years ago

dkent600 commented 3 years ago

During this:

    box = await Box.create(web3Provider);

an exception is thrown (and not caught):

generating 2048-bit RSA keypair... Uncaught (in promise) cause: undefined message: "The user denied permission to access the database." name: "OpenError" stack: "OpenError: The user denied permission to access the database.↵

spaceName is "DAOstack" Using 3box@1.21.0 The web3provider is pointing at rinkeby.

You can reproduce here: https://alchemy-add3boxcomments-jjgmo6.herokuapp.com/

STEPS:

  1. in the upper-right, login to an account (I'm using metamask)
  2. hover your mouse over the account address or name and in the dropdown, click "Full Profile"
  3. edit and submit the profile.

RESULT: The exception

dkent600 commented 3 years ago

I was able to get past the error by enabling third-party cookies. Is this new?

Would be great if you could pro-actively let users know via a UI prompt if this is going to be a requirement and third-party cookies are found to be blocked. Otherwise they have no clue.

oed commented 3 years ago

It's new yes, however we did add code to detect if there isn't support for third-party cookies and in that case not enable this feature. Might be a bug in that code.

cc @zachferland