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

URL Reset and Authentication Failure: Reloading Page as Unauthenticated User Results in URL Clearing and 400 Error #611

Open
3 tasks done
Adebesin-Cell opened this issue Aug 23, 2023 · 1 comment

Comments

@Adebesin-Cell
Copy link

Adebesin-Cell commented Aug 23, 2023

โœ… Prerequisites

  • Did you perform a cursory search of open issues? Is this bug already reported elsewhere?
  • Are you running the latest SDK version?
  • Are you reporting to the correct repository (magic-sdk)?

๐Ÿ› Description

Upon attempting to reload the page with the URL baseURL/?category=nfts while not authenticated, an unexpected issue arises. Instead of maintaining the current URL, the page's URL inexplicably reverts back to the base baseURL. This anomaly is further exacerbated by the receipt of a 400 error from the https://auth.magic.link/v1/session/refresh URL, a component associated with user authentication.

๐Ÿงฉ Steps to Reproduce

  1. Visit https://codesandbox.io/p/github/Adebesin-Cell/Magic-Connector-Bug/main
  2. Click on the "Hi, Click Me" button.
  3. The page should change the URL to baseURL/?category=nfts
  4. The button also triggers a reload, after a while the URL clears and shows the log about refresh failing.
Screen Shot 2023-08-23 at 11 21 03 AM
  1. Once the request fails, the whole URL resets

๐Ÿค” Expected behavior

baseURL/?category=nfts is meant to be the URL, not a reset URL. Expected behavior can be gotten by logging in with meta mask wallet and the page URL doesn't clear.

๐Ÿ˜ฎ Actual behavior

An uncalled request clears the URL to the base URL.

Stack Trace

Screen Shot 2023-08-23 at 11 21 03 AM

๐Ÿ’ป Code Sample

Here's the code repo to test the issue. https://github.com/Adebesin-Cell/Magic-Connector-Bug

๐ŸŒŽ Environment

Software Version(s)
@magiclabs/wagmi-connector ^1.1.0
Browser Chrome
yarn v1.22.19
Operating System MacOS
@Adebesin-Cell
Copy link
Author

Hi, is there any update with this issue?

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

No branches or pull requests

1 participant