phonegap / phonegap-app-developer

PhoneGap Developer App
app.phonegap.com
Apache License 2.0
2k stars 2.53k forks source link

PhoneGap Developer - App does not show latest changes #287

Open flyonthenet opened 9 years ago

flyonthenet commented 9 years ago

After last PhoneGap update, changes are not automatically transferred to Phonegap Developer App. We have to close and restart the App to changes take effect.

This is very annoying :-(

Server platform (Phonegap serve): Windows Server 2003 Client: Adroid 5.1 (Nexus 5)

timkim commented 9 years ago

It takes a little bit for the new changes to update the app now (we changed some things internally). Give it a few more seconds to see if it updates. Over time we should be able to get the speed of the updates back to what they were.

donovan-graham commented 9 years ago

I'm having same issue on MacOSX + Samsung Galaxy S4, using phonegap serve from command line. Changes never propagate onto phone, so I'm having to manually restart after each change.

Bushjumper commented 9 years ago

+1

flyonthenet commented 9 years ago

@timkim After some tests, if I run phonegap serve with no arguments, the App never updates. If I run phonegap serve --autoreload the App gets updated after a while (about 1 minute) If I open localhost:3000 in a standard browser, changes are immediate.

When loading, now seems that PhoneGap Developer downloads the entire app in a zip (takes more time to start)

There's some way to restore the previous behavior? It was so handy! :-) Thanks in advance

timkim commented 9 years ago

Hrm - well it looks like we have some kinks to work out. Ya, we changed the PhoneGap Developer App to download the entire app as a zip - it fixed issues concerning AJAX, certain api calls and such, but it seems like performance took a hit.

To restore the previous behaviour would require a downgrade of the app to 1.4.0.

itwseood commented 9 years ago

@timkim we have performed some tests with the following configurations:

I am sending some insights, hope those will help:

fs.js:568
  function strWrapper(err, written) {
                ^
Error: EMFILE, too many open files 'C:\Users\XXX\AppData\Roaming\npm\node_mod
ules\phonegap\node_modules\connect-phonegap\res\middleware\deploy.js'
    at Error (native)
    at Object.fs.openSync (fs.js:502:18)
    at Object.fs.readFileSync (fs.js:354:15)
    at injectScript (C:\Users\XXX\AppData\Roaming\npm\node_modules\phonegap\n
ode_modules\connect-phonegap\lib\middleware\zip.js:40:34)
    at InjectHTML._transform (C:\Users\XXX\AppData\Roaming\npm\node_modules\p
honegap\node_modules\connect-phonegap\lib\middleware\zip.js:62:68)
    at InjectHTML.Transform._read (_stream_transform.js:179:10)
    at InjectHTML.Transform._write (_stream_transform.js:167:12)
    at doWrite (_stream_writable.js:301:12)
    at writeOrBuffer (_stream_writable.js:288:5)
    at InjectHTML.Writable.write (_stream_writable.js:217:11)

Hope this helps! Let me know if we can help performing some additional tests if needed. Our team likes PhoneGap (and Cordova) we have active projects using it and indeed the Developer App saves huge amount of time. I'm sure these glitches with the the DevApp update will be solved and this toll will continue to be as fast and smooth as before and better in form of possibilities.

You've mentioned downgrade to 1.4.0 - is the previous version available somewhere to get as PG Dev App?

itwseood commented 9 years ago

Additional insight that might be helpful. Noticed that if using MAC and the app is open in BOTH the browser (localhost:3000) and via the iOS Phonegap Developer app, the extraction of the app never crashes and reloads the app preview appropriately.

Bushjumper commented 9 years ago

@timkim Any progress on this? If not, could you please provide a way to downgrade? Thanks

rodrigozr commented 9 years ago

+1 Also, I would like to add that "console.log" output also stopped working in the latest version. Do anybody have a link to the old APK?

mwbrooks commented 9 years ago

Hey @flyonthenet @donovan-graham @itwseood, thanks a lot for all of the details! Seriously, it's hard to recreate various environments using various devices, so this kind of testing and reporting helps a lot.

I've noticed that #292 is also having issues on an iPhone 5. Referencing it here so that the Github issues link to each other.

We'll need to dive into this issue more seriously, since it's not a trivial fix. I totally understand if you need to downgrade in order to get back into dev-mode. We archive all of our releases inside of the repository and you can find the Android releases here. You should be able to install the Android releases as long as third-party apps are enabled on the device. iOS obviously isn't as simple.

flyonthenet commented 9 years ago

Hi @mwbrooks @timkim

This is what I can report after some days of developing with the new PhoneGap.

1) Seems that some files are cached. The App gets auto-reloaded fine (I see HTML changes) but scripts (frequently) are old. So, when my App is not working as I expect, I don't know if it's a fault in my code or a cache related problem. I usually place a huge alert in JS code, and if not shown, I insist on reload.

2) When I save JS or CSS, changes are not propagated to the App. I have to save some HTML related file to get my App updated. Sometimes this is not sufficient, so I have to close and reopen PhoneGap Developer. May this can be related to same cache issue?

Do you think that <meta http-equiv="pragma" content="no-cache" /> will help to mitigate this? Or how I can tell PhoneGap to turn off any caching?

@rodrigozr Actually I'm using console.log with no problems. Have you tried to run phonegap serve --autoreload?

Have a nice day D.

sarvansri commented 8 years ago

Hi, i am new in phonegap, i am developing a simple app in cordova.

I have auto reload issue in phonegap developer app. If i change css, html or javascript files in project folder, its not updated in developer app, i don't have a line "200 /autoreload" in cmd windows. just i have file changed comments only in cmd windows.

please let me know the exact issue & what i should update ?

jdillon11 commented 8 years ago

I noticed this problem a few weeks ago when I updated to the newest version of PhoneGap, so I waited a few weeks, uninstalled PhoneGap, created a new project, updated the developer app on my phone, and everything still seems broken. This is really disappointing and frustrating as I can't really get the work done I need to. Is there a timeframe on when this will be fixed, or any other updates on the problem?

Thanks, Josh

mwbrooks commented 8 years ago

Hey @jdillon11,

Yea, this is a frustrating issue. We've got a patch waiting in the Apple submission queue and we'll release it once it's approved. The patch helps address some reload issues, where the previous content was cached. We're now trying to diagnose the connection (or download error) message that users are seeing.

timkim commented 8 years ago

Hi all,

Our update to fix the autoreload issue should now be up. Please update your app and see if the autoreload feature works for you.

lucifertran commented 8 years ago

Hi,

I still face problem with HTML not reload. I tried to fixed one issue by modifying the html, turn out it did not work out. So I switch back to the old one, and Phonegap app did not update at all.

Anyone facing the same problem?

vrathnam7 commented 8 years ago

I am also still facing this issue from both the CLI and the desktop application from my Mac. The three finger tap and four finger tap also do not work. I am using the most recent version of phonegap. Any updates on this?

tanasebutcaru commented 8 years ago

Same issue here! Using CLI on Linux with latest phonegap / cordova / nodejs versions. Tested on a Xperia Z3c.

owenconti commented 8 years ago

Having the same symptoms as @vrathnam7 - No automatic refresh, no 3/4 tap gestures working. Only way to reload the app is to force quit the Phonegap Developer App and reopen it. I have the most recent version of the Phonegap CLI and Phonegap Developer App as of today (Aug 15, 2015)

Xyclade commented 8 years ago

Same here using Mac OS Yosemite, the IOS and Android app (latest versions)

MilosRasic commented 8 years ago

Hi. I have a similar problem, except that it occurs one one machine only (work) and the app is working fine on another (home). Both computers are running Windows. The client is Android. Any news or workarounds for this problem?

seltzlab commented 8 years ago

Same here with Ubuntu + CLI, Phonegap 5.2.1 and latest Android app

indice commented 8 years ago

+1

imovertheinternet commented 8 years ago

+1

gecsafunk commented 8 years ago

+1

francescognarra commented 8 years ago

+1

crushcafeteria commented 8 years ago

+1

diogomachado commented 8 years ago

+1. I try with Moto X, Android Lollipop. When i change file, the Phonegap App not autoreload.

luco commented 8 years ago

+1

yorkshiretwist commented 8 years ago

I have a dirty workaround for seeing changes with CSS and JS files when using PhoneGap Desktop. Rather than link to the local file:

<link rel="stylesheet" type="text/css" href="css/index.css" />

Link to the one on the PhoneGap server:

<link rel="stylesheet" type="text/css" href="http://192.168.1.100:3000/css/index.css" />

You'll need to change the IP address and port with the one your server uses. This means you can refresh the app on your device (using four-finger tap) to load changes.

Before preparing your app for deployment you'll need to change the URLs back to the local ones.

crosma commented 8 years ago

+1 fresh install of the desktop and phone apps. Worked for about an hour of testing a brand new app. It still works perfect if I go to http://localhost:3000/ locally.

nakanaa commented 8 years ago

I had this problem (hence ending up in here), but I thought it was weird because it had been working just a couple days before.

For me it was simply an exception in one of the JavaScript files. Turns out, that exception somehow stopped the whole app from updating (even if it wasn't critical to the app itself and the server did notice the changes etc.). The exception was actually plugin related for me.

Anyway, if you're having the problem at least make sure there isn't any exceptions being produced by your code, try disabling/removing (custom) plugins and generally commenting out your app to very bare minimum to see if it starts working. If it does, then you know it's related to your code.

BrainSlugs83 commented 8 years ago

+1 -- I started out with latest phonegap, and it was working at first, but as my project got larger, it stopped working (I haven't even added all the NPM modules I want to add yet) -- downgrading to 1.4 seems to have fixed this -- on 1.4, within a couple of seconds of saving my changes, they show up on the phone.

EddieDemon commented 8 years ago

I've noticed the same issue after some hours of testing. I'm unsure if this has to do with any caching of the DevApp side. But I also noticed this error;

undefined exeption nativeEvalAndFetch : ReferenceError: Can't find variable: cordova
undefined exeption nativeEvalAndFetch : ReferenceError: Can't find variable: cordova

The rest of the DevApp log says near to nothing when something happens, sadly.

Probable another issue. Occurs when opening or closing the app (iOS)

lesliepound commented 8 years ago

Is the solution to downgrade to 1.4?
Same problem of app not refreshing in phonegap test tool (installed on windows,using iphone5);

enriquerene commented 8 years ago

Can someone tell me why "phonegap serve" doesn't work on linux but works on windows? The command works ok, and I can connect with my firefox browser. When I try to connect in my mobile through PhoneGap developer app, it keeps downloading and after cancel because of don't find anything... when I do the same in a windows 7 after few seconds the app says "extracting" and everything works fine. I tried in Ubuntu 15.04, 15.10, 14.04 LTS and now I'm in OpenSUSE Tumbleweed.

Thank you

fultonm commented 8 years ago

This is still an issue.. With phonegap serve --autoreload I still receive no updates to the app after 10 minutes. The CLI does register file changes. https://i.gyazo.com/ac669283b3e4882e686df1b9133891db.png

ibrennan commented 8 years ago

Facing the same problem still, running phonegap version 5.4.0 from command line:

phonegap serve

It live reloads in the browser the problem, but using the on device phonegap app we get no refreshes.

ETA for a fix?

enriquerene commented 8 years ago

I know this doesn't solve the issue, but I'm testing my apps through 'cordova run android' and plugging my device Am 13.01.2016 19:26 schrieb "Ian Brennan" notifications@github.com:

Facing the same problem still, running phonegap version 5.4.0 from command line:

phonegap serve

It live reloads in the browser the problem, but using the on device phonegap app we get no refreshes.

ETA for a fix?

— Reply to this email directly or view it on GitHub https://github.com/phonegap/phonegap-app-developer/issues/287#issuecomment-171439746 .

arslion commented 8 years ago

+1. same issue happening with me right now :/

gRegorLove commented 8 years ago

I was experiencing this until I (temporarily) removed the Content-Security-Policy meta tag.

Tuszy42 commented 8 years ago

I can confirm what @gRegorLove said, deleting that line in the index solves the issue.

lesliepound commented 8 years ago

Still getting error after "Content-Security-Policy" removed and file edited. Console log shows: "download error"

samanime commented 8 years ago

So, I noticed a change when I removed the Content-Security-Policy meta tag and that seemed to fix it, but I've been testing for a while again, with it gone all this time, and it's now slow again.

It's not that it doesn't work at all... it's just really slow. Like, on the order of a couple of minutes. Sending deviceready is also the same... taking several minutes to trigger.

It seems like if I do several changes in rapid-fire, it'll get way behind as it tries to do each change.

Running it in the browser, it works at expected speeds (a few seconds at most).

The CLI sees the changes pretty much instantly.

rahul-desai3 commented 8 years ago

+1

rodrigoclp commented 8 years ago

+1 Sometimes work, sometimes not.

phuongtailtranminh commented 8 years ago

+1 Sometimes work, sometimes not.

bodaso commented 8 years ago

Is there a solution to this problem? My course at uni got this assignment using phonegap, and because the mobile app on the tablet won't refresh itself and the 4 finger tap refresh won't work either, i had to manually go back to the menu and connect again everytime i want see a change! This is really troublesome, and i'm less likely to come back to phonegap afterward when I finish with this assignment.

rahul-desai3 commented 8 years ago

I don't mean to sound like a jerk but the Intel XDK works a lot better. I have moved on.

This issue is open since almost a year now.

omarwagih commented 7 years ago

+1