RocketChat / Rocket.Chat.Cordova

Rocket.Chat Cross-Platform Mobile Application via Cordova (DEPRECATED)
MIT License
104 stars 109 forks source link

CorHttpd plugin not available/ready #188

Closed PhilThal closed 7 years ago

PhilThal commented 7 years ago

Hi,

I got a problem when i want to build Rocket.Chat.Cordova for android with my own API Keys for push notifications. Its all good untill i start the app in my emulator and add my server. It is downloading all files and want to load com.myserver.com. Then in the chrome://inspect i can see "CorHttpd plugin is not ready". Can you guys please help me out here ?

Thanks in advance.

See screenshots for mor informations chromeinspect emulator

Oliver84 commented 7 years ago

I'm having the same exact issue. Following...

teamsoo commented 7 years ago

Same here

ERROR: CorHttpd plugin not available/ready.

from Xcode output.

and the app stoped at LOADING ...[SERVER NAME]...

teamsoo commented 7 years ago

@Snom @Oliver84 I was able to fix this problem.

According to this issue https://issues.apache.org/jira/browse/CB-12680, cordova will now install plugins using some fetch command which will require package.js in the plugins.

As I noticed, both com.meteor.cordova-update and com.verso.cordova.clipboard don't have package.json in their repo. So, installing them will fail and httpd is used in www/coffee/servers.coffee like this

httpd = cordova?.plugins?.CordovaUpdate

So, httpd won't be available or ready when you can't install com.meteor.cordova-update plugins

My temporary fix is to change to my forked repo

"com.meteor.cordova-update": "https://github.com/teamsoo/com.meteor.cordova-update", "com.verso.cordova.clipboard": "https://github.com/teamsoo/CordovaClipboard",

I've added package.json to both repo.

You can try and hope this will fix your problem as it fixed mine.

Oliver84 commented 7 years ago

Awesome, thanks! Yes, your fork worked. Thank you so much for your help. I spent a ton of time and knew it had something to do with Cordova Update but I wasn't aware of that issue. Appreciate you help!

PhilThal commented 7 years ago

I fixed the issue by adding the plugin like this cordova plugin add https://github.com/RocketChat/com.meteor.cordova-update.git --nofetch. Thanks for the answers !