# loginWithRedirect generates query params suggesting auth0 module can't be found

**URL:** <https://community.auth0.com/t/loginwithredirect-generates-query-params-suggesting-auth0-module-cant-be-found/43649>\
**Category:** Get Help\
**Created:** [May 26, 2020, 6:42pm UTC](https://community.auth0.com/t/loginwithredirect-generates-query-params-suggesting-auth0-module-cant-be-found/43649 "2020-05-26T18:42:07Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jgrim](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/jgrim/32/21531_2.png) [@jgrim](https://community.auth0.com/u/jgrim)\
**Post date:** [May 26, 2020, 6:42pm UTC](https://community.auth0.com/t/loginwithredirect-generates-query-params-suggesting-auth0-module-cant-be-found/43649/1 "2020-05-26T18:42:07Z")

</div>

Hi,

I am facing an issue that seems to have come out of nowhere. For reference, I am using the auth 0 spa SDK in a react application.

When `loginWithRedirect()` is called and redirects the user, the URL it generates includes query params that state: “access denied”, “cannot find module auth0”

Here are the raw query parameters:  
`error=access_denied&error_description=Cannot%20find%20module%20%27auth0%402.25.1%27&state=VUxvZTdaeE9uTW5BUF9SbEdYWEdPQWZ2TFJCU0JtaVNDYWNwdzNpSFAwTw%3D%3D`

This seemingly is not an error in my application code. And I do not see any network calls failing, though I did notice that the call to `/authorize` is returning a 302 redirect which seems strange (I can’t recall if this is what it always returned).

Any ideas? Is there a way to confirm if this issue is coming from my application? I have already tried deleting all of node\_modules and installing fresh packages.

As added context, here is the log event in our tenant’s application:

```auto
{
  "date": "2020-05-26T19:04:47.830Z",
  "type": "f",
  "description": "Cannot find module 'auth0@2.25.1'",
  "connection_id": "",
  "client_id": "y3udvjIkL1oIz4WDssC3FAF0cgEw7SRp",
  "client_name": "PD Auth Staging App",
  "ip": "64.94.4.36",
  "user_agent": "Chrome 83.0.4103 / Mac OS X 10.14.6",
  "details": {
    "body": {},
    "qs": {
      "client_id": "<client_ID>",
      "redirect_uri": "http://localhost:8080/calls",
      "scope": "openid profile email offline_access",
      "response_type": "code",
      "response_mode": "query",
      "state": "d1N0SUwuM3puRUtDc3ozR3VRRXFNQUVKMlJLWW9BLjVvWlFTb0VrdlBCMA==",
      "nonce": "clQ2bkZxaXFZajZFY0xKVUFGSVpydHBrYml3Z2hOaXROTGIyVm45ZU1HRw==",
      "code_challenge": "2jgPbbX0IZ_EKXlZ9RTFQX0JFc7ymmVeXchpgC2Xz7w",
      "code_challenge_method": "S256",
      "auth0Client": "eyJuYW1lIjoiYXV0aDAtc3BhLWpzIiwidmVyc2lvbiI6IjEuOC4xIn0="
    },
    "error": {
      "message": "Cannot find module 'auth0@2.25.1'",
      "oauthError": "access_denied",
      "type": "oauth-authorization"
    },
    "session_id": "wtlHCS2db2hnRrlBvsdWbnlaBrla2toi"
  },
  "hostname": "staging-pindrop.auth0.com",
  "user_id": "samlp|staging-okta|jgrim@pindrop.com",
  "user_name": "jgrim@pindrop.com",
  "audience": "https://staging-pindrop.auth0.com/userinfo",
  "scope": [
    "openid",
    "profile",
    "email",
    "offline_access"
  ],
  "auth0_client": {
    "name": "auth0-spa-js",
    "version": "1.8.1"
  },
  "log_id": "90020200526190451507000259912423784945849394065674600498",
  "_id": "90020200526190451507000259912423784945849394065674600498",
  "isMobile": false
}

```

---

<div class="post-metadata">

**Author:** ![jgrim](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/jgrim/32/21531_2.png) [@jgrim](https://community.auth0.com/u/jgrim)\
**Post date:** [May 26, 2020, 7:26pm UTC](https://community.auth0.com/t/loginwithredirect-generates-query-params-suggesting-auth0-module-cant-be-found/43649/2 "2020-05-26T19:26:24Z")

</div>

Discovered the issue. A teammate had turned on a rule that was not working correctly and that is what was generating the error. I found this by looking at the tenant’s logs and noticed all logins since a rule change had failed.

Not sure how to mark this as resolved or closed but we’ve fixed the issue.

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [May 27, 2020, 12:40pm UTC](https://community.auth0.com/t/loginwithredirect-generates-query-params-suggesting-auth0-module-cant-be-found/43649/3 "2020-05-27T12:40:09Z")

</div>

Thanks for letting us know and sharing it with the rest of community! Already marked as a solution.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [June 11, 2020, 12:40pm UTC](https://community.auth0.com/t/loginwithredirect-generates-query-params-suggesting-auth0-module-cant-be-found/43649/4 "2020-06-11T12:40:12Z")

</div>

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.
