question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Do not overwrite image files with resource server error

See original GitHub issue

Description:

If you have the resources for your platform already and you reinstall your platform (for some reason), the ionic-cli will force a resources command, deleting the existing resources in the process. This is a problem because, if the Ionic servers aren’t working as expected (like right now), the resources won’t be generated and you can’t build your app because it doesn’t have the resources it needs. I can’t do anything right now until the Ionic servers go back to normal.

Steps to Reproduce:

Example repo:

  1. ionic cordova platform rm ios
  2. ionic cordova platform add ios

Output:

Saving ios@~4.5.4 into config.xml file ...

> ionic cordova resources ios --force
✔ Collecting resource configuration and source images - done!
✔ Filtering out image resources that do not need regeneration - done!
✔ Uploading source images to prepare for transformations - done!
✖ Generating platform resources: 8 / 32 complete - failed!
Error: encountered bad status code (503) for https://res.ionic.io/api/v1/transform
body: <!DOCTYPE html>
        <html>
          <head>
                <meta name="viewport" content="width=device-width, initial-scale=1">
                <meta charset="utf-8">
                <title>Application Error</title>
                <style media="screen">
                  html,body,iframe {
                        margin: 0;
                        padding: 0;
                  }
                  html,body {
                        height: 100%;
                        overflow: hidden;
                  }
                  iframe {
                        width: 100%;
                        height: 100%;
                        border: 0;
                  }
                </style>
          </head>
          <body>
                <iframe src="//www.herokucdn.com/error-pages/application-error.html"></iframe>
          </body>
        </html>
    at Response.res.on (/usr/local/lib/node_modules/ionic/node_modules/@ionic/cli-utils/lib/cordova/resources.js:150:32)
    at emitNone (events.js:105:13)
    at Response.emit (events.js:207:7)
    at emitNone (events.js:110:20)
    at IncomingMessage.emit (events.js:207:7)
    at endReadableNT (_stream_readable.js:1059:12)
    at _combinedTickCallback (internal/process/next_tick.js:138:11)
    at process._tickCallback (internal/process/next_tick.js:180:9)

My ionic info:

cli packages: (/usr/local/lib/node_modules)

    @ionic/cli-plugin-proxy : 1.5.7
    @ionic/cli-utils        : 1.19.1
    ionic (Ionic CLI)       : 3.19.1

global packages:

    cordova (Cordova CLI) : 7.1.0

local packages:

    @ionic/app-scripts : 3.1.7
    Cordova Platforms  : ios 4.5.4
    Ionic Framework    : ionic-angular 3.9.2

System:

    Android SDK Tools : 26.1.1
    ios-deploy        : 1.9.2
    ios-sim           : 5.1.0
    Node              : v8.4.0
    npm               : 5.7.1
    OS                : macOS High Sierra
    Xcode             : Xcode 9.2 Build version 9C40b

Other Information:

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
miniskulljobcommented, Mar 8, 2018

@dwieeb thank you very much, and I’m sorry I didn’t explain that before.

1reaction
imhoffdcommented, Mar 6, 2018

@miniskulljob I was able to reproduce this issue right away. I hope you don’t mind if I hijack your issue and change the title.

Read more comments on GitHub >

github_iconTop Results From Across the Web

[rstudio-server] Can't overwrite file via uploading #7015 - GitHub
Steps to reproduce the problem. Upload any file in RStudio Server via "Upload" button;; Try to upload the same file in the same...
Read more >
Cloudinary Upload 'overwrite' option not working on Node.js
When I set it to false, the files still upload all their data. This seems to be an error. cld.uploader.upload(filePath, function(result) { ...
Read more >
Fixing the Failed to Load Resource Error in WordPress
Go to the WordPress Dashboard > Media > Library. A list of images will appear. Look for the corrupted files or media. These...
Read more >
Moodle in English: overwriting resource files
Hi, I'm having a little issue with a resource. I uploaded a zip, unzipped it and then linked to the index file as...
Read more >
Overwrite a map image layer—ArcGIS Pro | Documentation
Overwrite existing map image layers to reflect changes to a GIS resource or its source data.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found