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

When behind corporate proxy - cannot connect to API server in 'Runs' of test runner #1470

Closed
jennifer-shehane opened this issue Mar 16, 2018 · 5 comments
Assignees

Comments

@jennifer-shehane
Copy link
Member

@jennifer-shehane jennifer-shehane commented Mar 16, 2018

User got this error behind corporate proxy - confirmed error did not occur when they connected to their hotspot:
00000003

Original thread: https://gitter.im/cypress-io/cypress?at=5aa96043a60157d62fe8c9b6

@callmeaponte
Copy link

@callmeaponte callmeaponte commented Aug 31, 2018

+1 for this. I'm stuck behind a corporate proxy at work and I'm seeing the exact same issue.

@lukeapage
Copy link
Contributor

@lukeapage lukeapage commented Jan 3, 2019

For us, I worked around it by editing server/lib/gui/events

case "ping:api:server":
apiUrl = konfig("api_url");
return connect.ensureUrl(apiUrl).then(send)["catch"](function (err) {
  var subErr;
  if (err.length) {
    subErr = err[0];
    err.name = subErr.name || (subErr.code + " " + subErr.address + ":" + subErr.port);
    err.message = subErr.message || (subErr.code + " " + subErr.address + ":" + subErr.port);
  }
  err.apiUrl = apiUrl;
  return sendErr(err);
});

==>

case "ping:api:server":
apiUrl = konfig("api_url");
return connect.ensureUrl(apiUrl).catch(function () { return ''; }).then(send)["catch"](function (err) {
  var subErr;
  if (err.length) {
    subErr = err[0];
    err.name = subErr.name || (subErr.code + " " + subErr.address + ":" + subErr.port);
    err.message = subErr.message || (subErr.code + " " + subErr.address + ":" + subErr.port);
  }
  err.apiUrl = apiUrl;
  return sendErr(err);
});

e.g. you are blocking people behind a corporate proxy in the code that detects whether you are blocked - but if you edit out the ping api server check like this, then I can login completely okay!!

@krishvv
Copy link

@krishvv krishvv commented Mar 15, 2019

Where is server/lib/gui/events located . I am also facing the same issue . Not able to locate server/lib/gui/events

@cypress-bot
Copy link

@cypress-bot cypress-bot bot commented Apr 1, 2019

The code for this is done in cypress-io/cypress#3531, but has yet to be released.
We'll update this issue and reference the changelog when it's released.

@cypress-bot
Copy link

@cypress-bot cypress-bot bot commented May 17, 2019

Released in 3.3.0.

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

Successfully merging a pull request may close this issue.

5 participants