{"action":"created","issue":{"url":"https://api.github.com/repos/sindresorhus/got/issues/689","repository_url":"https://api.github.com/repos/sindresorhus/got","labels_url":"https://api.github.com/repos/sindresorhus/got/issues/689/labels{/name}","comments_url":"https://api.github.com/repos/sindresorhus/got/issues/689/comments","events_url":"https://api.github.com/repos/sindresorhus/got/issues/689/events","html_url":"https://github.com/sindresorhus/got/issues/689","id":395461160,"node_id":"MDU6SXNzdWUzOTU0NjExNjA=","number":689,"title":"Timeout option not working with proxy (using tunnel as proxy)","user":{"login":"lounsbrough","id":8313853,"node_id":"MDQ6VXNlcjgzMTM4NTM=","avatar_url":"https://avatars1.githubusercontent.com/u/8313853?v=4","gravatar_id":"","url":"https://api.github.com/users/lounsbrough","html_url":"https://github.com/lounsbrough","followers_url":"https://api.github.com/users/lounsbrough/followers","following_url":"https://api.github.com/users/lounsbrough/following{/other_user}","gists_url":"https://api.github.com/users/lounsbrough/gists{/gist_id}","starred_url":"https://api.github.com/users/lounsbrough/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lounsbrough/subscriptions","organizations_url":"https://api.github.com/users/lounsbrough/orgs","repos_url":"https://api.github.com/users/lounsbrough/repos","events_url":"https://api.github.com/users/lounsbrough/events{/privacy}","received_events_url":"https://api.github.com/users/lounsbrough/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2019-01-03T05:33:12Z","updated_at":"2019-01-05T17:09:32Z","closed_at":null,"author_association":"NONE","body":"#### Describe the bug\r\n\r\n - Node.js version: 11.0.0\r\n - OS & version: Windows 10 Pro\r\n\r\nThe timeout option does not seem to work when using a proxy. I'm using tunnel per the examples in the README.\r\n\r\n#### Actual behavior\r\n\r\n`timeout` option set to 10000 milliseconds. Request via proxy takes > 30 seconds to timeout.\r\n\r\n#### Expected behavior\r\n\r\nRequest should timeout after the specified number of milliseconds.\r\n\r\n#### Code to reproduce\r\n\r\n```\r\nconst response = await got(url, {\r\n    agent: tunnel.httpsOverHttp({\r\n        proxy: {\r\n            host: proxy.host,\r\n            port: proxy.port,\r\n            proxyAuth: `${proxy.username}:${proxy.password}`,\r\n            headers: getRequestHeaders()\r\n        }\r\n    }),\r\n    headers: getRequestHeaders(),\r\n    timeout: 10000\r\n});\r\n```\r\n\r\n<!--\r\nWe encourage you to submit a pull request with a failing test:\r\n - This will make it more likely for us to prioritize your issue.\r\n - It's a good way to prove that the issue is related to Got and not your code. \r\n\r\nExample: https://github.com/avajs/ava/blob/master/docs/01-writing-tests.md#failing-tests\r\n-->\r\n\r\n#### Checklist\r\n\r\n- [x] I have read the documentation.\r\n- [x] I have tried my code with the latest version of Node.js and Got.\r\n"},"comment":{"url":"https://api.github.com/repos/sindresorhus/got/issues/comments/451672596","html_url":"https://github.com/sindresorhus/got/issues/689#issuecomment-451672596","issue_url":"https://api.github.com/repos/sindresorhus/got/issues/689","id":451672596,"node_id":"MDEyOklzc3VlQ29tbWVudDQ1MTY3MjU5Ng==","user":{"login":"lounsbrough","id":8313853,"node_id":"MDQ6VXNlcjgzMTM4NTM=","avatar_url":"https://avatars1.githubusercontent.com/u/8313853?v=4","gravatar_id":"","url":"https://api.github.com/users/lounsbrough","html_url":"https://github.com/lounsbrough","followers_url":"https://api.github.com/users/lounsbrough/followers","following_url":"https://api.github.com/users/lounsbrough/following{/other_user}","gists_url":"https://api.github.com/users/lounsbrough/gists{/gist_id}","starred_url":"https://api.github.com/users/lounsbrough/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lounsbrough/subscriptions","organizations_url":"https://api.github.com/users/lounsbrough/orgs","repos_url":"https://api.github.com/users/lounsbrough/repos","events_url":"https://api.github.com/users/lounsbrough/events{/privacy}","received_events_url":"https://api.github.com/users/lounsbrough/received_events","type":"User","site_admin":false},"created_at":"2019-01-05T17:09:32Z","updated_at":"2019-01-05T17:09:32Z","author_association":"NONE","body":"With retries set to 0, it also fails immediately."}}
{"actor":{"display_login":"lounsbrough"}}