{"action":"created","issue":{"url":"https://api.github.com/repos/cypress-io/cypress/issues/1488","repository_url":"https://api.github.com/repos/cypress-io/cypress","labels_url":"https://api.github.com/repos/cypress-io/cypress/issues/1488/labels{/name}","comments_url":"https://api.github.com/repos/cypress-io/cypress/issues/1488/comments","events_url":"https://api.github.com/repos/cypress-io/cypress/issues/1488/events","html_url":"https://github.com/cypress-io/cypress/issues/1488","id":307665479,"number":1488,"title":"Using a subdomain with localhost will throw an error of unreachable on Mac","user":{"login":"OrganicCat","id":548061,"avatar_url":"https://avatars3.githubusercontent.com/u/548061?v=4","gravatar_id":"","url":"https://api.github.com/users/OrganicCat","html_url":"https://github.com/OrganicCat","followers_url":"https://api.github.com/users/OrganicCat/followers","following_url":"https://api.github.com/users/OrganicCat/following{/other_user}","gists_url":"https://api.github.com/users/OrganicCat/gists{/gist_id}","starred_url":"https://api.github.com/users/OrganicCat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OrganicCat/subscriptions","organizations_url":"https://api.github.com/users/OrganicCat/orgs","repos_url":"https://api.github.com/users/OrganicCat/repos","events_url":"https://api.github.com/users/OrganicCat/events{/privacy}","received_events_url":"https://api.github.com/users/OrganicCat/received_events","type":"User","site_admin":false},"labels":[{"id":393988405,"url":"https://api.github.com/repos/cypress-io/cypress/labels/stage:%20needs%20information","name":"stage: needs information","color":"ffdf7f","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-03-22T14:24:39Z","updated_at":"2018-04-20T08:12:43Z","closed_at":null,"author_association":"NONE","body":"<!-- **Tip** in order for us to reproduce the bug you can fork [cypress-io/cypress-test-tiny](https://github.com/cypress-io/cypress-test-tiny) repo and setup the failing test. Then just tells us the repo and branch to try! -->\r\n\r\n- Operating System: OSX\r\n- Cypress Version: 2.10\r\n- Browser Version: Chrome 64\r\n\r\n### Bug\r\n\r\n### Current behavior:\r\nIf you set up a visit call to go to something like **mysubdomain.localhost:4200** Cypress will not respond properly (and will not visit) because it uses the hosts file for some subdomain redirection on localhost.\r\n\r\n### Desired behavior:\r\nI shouldn't have to add 127.0.0.1 for EVERY subdomain I want to test on my localhost, especially if I generate these for tests. Cypress should not have to rely on the hosts file for this.\r\n\r\n### How to reproduce:\r\nCreate a server that runs on a subdomain and your local machine so the address is something like **mysubdomain.localhost:4200**. Attempt to run a test that goes there. It will fail unless you add\r\n\r\n`127.0.0.1      mysubdomain.localhost`\r\n\r\nto your hosts file on Mac\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/cypress-io/cypress/issues/comments/383019659","html_url":"https://github.com/cypress-io/cypress/issues/1488#issuecomment-383019659","issue_url":"https://api.github.com/repos/cypress-io/cypress/issues/1488","id":383019659,"user":{"login":"vedmant","id":5052406,"avatar_url":"https://avatars0.githubusercontent.com/u/5052406?v=4","gravatar_id":"","url":"https://api.github.com/users/vedmant","html_url":"https://github.com/vedmant","followers_url":"https://api.github.com/users/vedmant/followers","following_url":"https://api.github.com/users/vedmant/following{/other_user}","gists_url":"https://api.github.com/users/vedmant/gists{/gist_id}","starred_url":"https://api.github.com/users/vedmant/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vedmant/subscriptions","organizations_url":"https://api.github.com/users/vedmant/orgs","repos_url":"https://api.github.com/users/vedmant/repos","events_url":"https://api.github.com/users/vedmant/events{/privacy}","received_events_url":"https://api.github.com/users/vedmant/received_events","type":"User","site_admin":false},"created_at":"2018-04-20T08:12:43Z","updated_at":"2018-04-20T08:12:43Z","author_association":"NONE","body":"I have the same problem, trying to open http://booking.localhost:8080 results in:\r\n\r\nError: getaddrinfo ENOTFOUND booking.localhost booking.localhost:8080\r\nat errnoException (dns.js:50:10)\r\nat GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:92:26\r\n\r\nI can open this page in any browser with no problems.\r\n"}}
{"actor":{"display_login":"vedmant"}}