Generate Resources Fail - December 2017

Hi, I am encountering a problem where I keep failing at generating image resources lately.
It doesn’t happen few days before this, but all of sudden I can no longer add platform or generate image.
Basically, both the command:

ionic cordova resources ios --force
or
ionic cordova platform add ios

would fail.
They all fail while generating resources, for both IOS and Android.
Below are the details of the system I’m using, and the error I am encountering.

Way to reproduce it:
I tried uninstall both Node and Ionic, then reinstall them.
I even tried format my Mac, reinstall nodejs and ionic.
Then, I start creating a new project by using:

ionic start Test

Then, I add platform with:

ionic cordova platform add ios

Then it will hit the error while it is halfway generating resources.

May I know are there any other way around this issue?

Are your images really big? You seem to be hitting a timeout, which could indicate it just takes too long to upload the pictures in the first place. Or is your connection really slow?

I didn’t modify any images.
It’s a brand new project directly from “ionic start ProjectName”.

In resources folder:

  • icon, png = 61 KB
  • splash.png = 79 KB

They are all the default directly created form ionic cli.

I perform another full flow again, and the steps is as below:

  1. uninstall & reinstall both ionic, cordova, and node (just to be sure):
    install node js 8.9.3 (LTS) because the latest version (9.2.1) will cause issue while install ionic
sudo npm uninstall -g ionic cordova
sudo npm cache clean -f
sudo npm install -g n
sudo n 8.9.3

Then, the full flow is as below:

The resources folder is as this:

Resources Folder - 1

Will be glad if anyone can see anything weird or wrong, because I couldn’t see anything wrong in those resources folder or my steps.

There is nothing wrong with the files or local installation, but with your connection to the server 104.20.7.16:443 which is probably the IP of the host Ionic is using, routed through Cloudflare I think.

So again, do you have a very slow connection?

No, I have 10 Mbps internet speed, good enough to watch youtube in 1080p hd.
It is quite not possible that it is my local internet speed that causes it.

Let’s say that if it is not my local internet speed that is the problem, but the internet speed from my country to the ionic server that is affected…
Are they any way to extend the timeout, or to test if it is really that case that causes this issue?

Or are there any other way around this issue?

Good you ask, it seems --no-timeout exists:

I try run these command:

ionic cordova platform add ios --no-timeout
ionic cordova resources ios --force --no-timeout

But still hitting the same error.
Any other possible solution than these?
Or perhaps I run the command wrongly?

Thanks.

Issue solved, the network connection to host is stable today.

But I do really hope that there are ways to bypass such issue when the internet is not at its best condition in future, and that we do not have to rely on host that much just to build an app.

Create an issue for ionic-cli to inidicate your wish that the app install process is not as Internet dependent as it is right now.