net::ERR_ABORTED during e2e tests visiting .well-known/jwks.json

I’m working on a small startup and we are using cypress to run our tests. We have plans in the near future to factor our actually logging into our application for the majority of our e2e tests and only keep it to make sure that our account integration is working properly, but right now it’s logging in on every test.

When the e2e tests run they’re running in Chromium 65 with the Cypress extension inside of a Docker in Ubuntu 16.04 on my local machine. The problem that I run into, and this happens on a Jenkins instance running on AWS as well, is that the request for https://<ouraccount> will fail with net::ERR_ABORTED. I don’t understand why this is happening and there’s no more information on the failure than that. I have a HAR for the failed request included below, and a larger HAR with all the requests in it if that would be helpful.

These failures are inconsistent and happen maybe 10% of the time. If you rerun the system will pass fine. I’m trying to understand if I’m somehow getting shut out from Auth0 system? We have a free account at the moment, but these e2e tests are not blazing fast and we aren’t logging in more than once every 30 seconds or so.

Looking at the timings block from the HAR it looks like the request never even made it out onto the network. Is it much more likely that this is a problem with Cypress and the browser than from Auth0’s end?

        "startedDateTime": "2018-04-30T10:35:58.764Z",
        "time": 0.21383899997454137,
        "request": {
          "method": "GET",
          "url": "",
          "httpVersion": "",
          "headers": [
              "name": "Referer",
              "value": "http://localhost:8080/jobs"
              "name": "User-Agent",
              "value": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/65.0.3325.181 Chrome/65.0.3325.181 Safari/537.36"
          "queryString": [],
          "cookies": [],
          "headersSize": -1,
          "bodySize": 0
        "response": {
          "status": 0,
          "statusText": "",
          "httpVersion": "",
          "headers": [],
          "cookies": [],
          "content": {
            "size": 0,
            "mimeType": "x-unknown"
          "redirectURL": "",
          "headersSize": -1,
          "bodySize": -1,
          "_transferSize": 0,
          "_error": "net::ERR_ABORTED"
        "cache": {},
        "timings": {
          "blocked": 0.21383899997454137,
          "dns": -1,
          "ssl": -1,
          "connect": -1,
          "send": 0,
          "wait": 0,
          "receive": 0,
          "_blocked_queueing": -1
        "serverIPAddress": ""

Yeah if it’s never making it out of the network, referencing net:: would lead me to believe it’s something to do with Cypress, Docker, or a combination of both. The fact that most of the time it works is a bit odd though

We fixed the issue by removing the authentication flow from our e2e tests (we circumvent it by faking out the login) which make it a lot faster, and don’t put load on Auth0 servers. I have a hard time imagining that the browser or Cypress was breaking the request. It really felt like Auth0 throttling incoming requests.

That said I did run a bash script in a loop with a 100 millisecond timeout curling the jwks endpoint and could not replicate the failure I was seeing in the browser.

1 Like

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