Ionic DevApp Feedback Mega-thread

Are the docs up to date. Because nothing is working for me. And I’m on a blank template app.

Same issue: In ionic 4 on the latest versions of OS X and IOS, the DevApp does not show apps being served on the same network.

It worked great in ionic 3, but is now broken in ionic 4.

My app was not discovered. Connected fine using the “Enter address manually” function. would be great you could save the address.

2 Likes

I have an issue with the Ionic Devapp when in my application I make an HTTP request with the cordova advanced http plugin (the ionic native http library), in particular with the sendRequest method. From the adb logcat I get the following error

   Process: io.ionic.devapp, PID: 20077
    java.lang.NoSuchMethodError: No virtual method getHttpUrlChecked(Ljava/lang/String;)Lokhttp3/HttpUrl; in class Lokhttp3/internal/Internal; or its super classes (declaration of 'okhttp3.internal.Internal' appears in base.apk)
        at okhttp3.internal.huc.OkHttpURLConnection.buildCall(OkHttpURLConnection.java:373)
        at okhttp3.internal.huc.OkHttpURLConnection.getOutputStream(OkHttpURLConnection.java:260)
        at okhttp3.internal.huc.DelegatingHttpsURLConnection.getOutputStream(DelegatingHttpsURLConnection.java:229)
        at okhttp3.internal.huc.OkHttpsURLConnection.getOutputStream(OkHttpsURLConnection.java:26)
        at com.github.kevinsawicki.http.HttpRequest.openOutput(HttpRequest.java:2902)
        at com.github.kevinsawicki.http.HttpRequest.form(HttpRequest.java:3325)
        at com.github.kevinsawicki.http.HttpRequest.form(HttpRequest.java:3285)
        at com.github.kevinsawicki.http.HttpRequest.form(HttpRequest.java:3350)
        at com.github.kevinsawicki.http.HttpRequest.form(HttpRequest.java:3255)
        at com.synconset.cordovahttp.CordovaHttp.prepareRequestBody(CordovaHttp.java:239)
        at com.synconset.cordovahttp.CordovaHttpPost.run(CordovaHttpPost.java:30)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
        at java.lang.Thread.run(Thread.java:764)

I get that error with Samsung N950F and Android 9.0 and a Nexus 5 with Lineage 14.1 Application works perfectly when run with Android Studio or Xcode.

ionic serve --devapp
This doesn’t work anymore. I have the following error:

> ng run app:ionic-cordova-serve --host=0.0.0.0 --port=8100 --cordova-mock --consolelogs --consolelogs-port=53703
[ng] Unknown option: '--consolelogs'
[ng] Unknown option: '--consolelogs-port'

I tried to update ionic CLI, but same thing. Did anyone experience the same thing lately?

1 Like

Hi everyone!

I saw that i cannot open the gallery to pick some images, what im doing wrong?

Regards

I can’t use the ionic serve command as I get:

[ERROR] Cannot perform serve.
        
Since you're using the Vue project type, you must provide the ionic:serve npm script so the Ionic CLI can serve your project.

I’d love to ‘provide the ionic:serve npm script’ if I knew what that meant…!

1 Like

I dont know much of Vue but I think it means your project doesnt know what to do on “ionic serve”.
This probably means that in your package.json file you are missing this:

"ionic:serve": "gulp default && npm run lint && ionic-app-scripts serve --sourceMap source-map --iscordovaserve --wwwDir platforms/browser/www/ --buildDir platforms/browser/www/build"

in your scripts tag.
Here is a gist file of all ionic scripts:

So you have to add it in scripts like this:

"scripts": {
 //some of your scripts 
 "ionic:serve": "gulp default && npm run lint && ionic-app-scripts serve --sourceMap source-map --iscordovaserve --wwwDir platforms/browser/www/ --buildDir platforms/browser/www/build"
}

and now you can run it with ionic:serve in your cli
Did that solve your problem?

Thanks for the reply.
For me the command wasn’t quite right, so I edited it to:

"ionic:serve": "npm run build && npm run lint && ionic-app-scripts serve --sourceMap source-map --iscordovaserve --wwwDir dist --buildDir dist"

However, it now errors on [npm] sh: ionic-app-scripts: command not found

So the ionic-app-scripts command was missing. I installed them with npm install @ionic/app-scripts which got me to the next error:

[npm] [17:07:10]  ionic-app-script task: "serve" 
[npm] [17:07:10]  Error: tsconfig: Cannot read file '/<redacted>/vue-ionic/tsconfig.json': 
[npm]             ENOENT: no such file or directory, open

So there needs to be a tsconfig.json file, which sounds very typescript-y and angular-y.
Perhaps this just isn’t ready for Vue projects yet…!

I just discovered that cordova-httpd-plugin doesn’t work in DevApp. When you try to access any of its methods it will always report that the plugin is not installed no matter what you do.

You app will work in an emulator or on the actual device. I tried emulated Android and iOS devices and a physical Android device so far. Attempts to load @ionic-native/httpd on either Android or iOS with Devapp both failed.