Ionic-cli: Error when logging in from CLI over slower connection: Error: Response timeout of 5000ms exceeded

Created on 17 Jul 2017  路  5Comments  路  Source: ionic-team/ionic-cli

_From @newpointmedia on July 14, 2017 20:16_

Ionic version: (check one with "x")
[ ] 1.x (For Ionic 1.x issues, please use https://github.com/ionic-team/ionic-v1)
[ ] 2.x
[x ] 3.x

I'm submitting a ... (check one with "x")
[x ] bug report
[ ] feature request
[ ] support request => Please do not submit support requests here, use one of these channels: https://forum.ionicframework.com/ or http://ionicworldwide.herokuapp.com/

Current behavior:
When running ionic login and entering the correct username and password the following message is returned: Error: Response timeout of 5000ms exceeded

I am on satellite connection which can be a little slower at times and this should not prevent a successful login from occurring.

Expected behavior:
I can log in successfully even if it takes longer than 5000ms

_Copied from original issue: ionic-team/ionic#12370_

Most helpful comment

I get the same error.

All 5 comments

I'm just going to remove timeouts, I think.

I get the same error.

I get the same. Is it possible to solve by selve? I need it very fast.

Go to /usr/lib/node_modules/ionic/node_modules/@ionic/cli-utils/dist/lib/http.js
(in archlinux)
In class Client modify .tymeout({ response: 5000, deadline: 25000 }) to suit your needs (I set 50000/100000). Your connection may be ok, but DNS/Ionic response may have some delay

Timeouts will be completely removed in the next CLI release.

@coxmin's solution may help, but keep in mind there is a hard 30s server timeout on our API, which produces ugly errors in the CLI.

Was this page helpful?
0 / 5 - 0 ratings