Software Archive
Read-only legacy content
17061 Discussions

js code files not refreshing in Debug tab

Claude_N_
Beginner
569 Views

This particular problem puts me at a stand still.

debug an App using the Debug Tab.

App loads, app runs, all is good EXCEPT the files are old. I have edited and fixed (yay) the major bug.

But, I cannot get the code on the device to reflect the changes.

Silly me, I would think that everything the XDK pushes code to the device it would somehow magically be the current code. It's not working that way.

I have exited XDK, cleared App Preview data and App Preview cache on the device, then restarted the XDK and still the old code is being pushed to the device. 

How do I get a current copy of my code on the device?

Is this a problem with retention of older code on the device?

Or, is there a local cache on my desktop from which the XDK is drawing an image to send to the device?

I have tried everything I could think of so far -- short of starting a brand new app each time I want to make an edit. I would have thought exiting and reentering the XDK would do the trick if nothing else.

Regards,

 

0 Kudos
10 Replies
Swati_S_Intel1
Employee
569 Views

Hi Claude,

Try clearing XDK cache :

On Mac : ~User/Library/Application Support/XDK/Cache

On Windows: ~User/App Data/Local/Intel/XDK/Cache

Swati

0 Kudos
Claude_N_
Beginner
569 Views

I have tried clearing cache.

Procedure:

Close XDK

Clear cache (~User/App Data/Local/XDK/Cache)  no Intel in tree for my system

Clear (App Preview) Data on device

Start XDK

Begin debug.

Has the same bad code.

 

0 Kudos
PaulF_IntelCorp
Employee
569 Views

What happens if you use the "Run My App" feature on the Develop tab? It uses the same mechanism to connect with your device over USB, but adds some features that will refresh and restart the app on file changes. Unfortunately, it does not include the remote CDT window, but it would be worth trying to see if that mechanism can updated your project files on the device. It might help in diagnosing the issue so we can come up with a solution.

0 Kudos
Claude_N_
Beginner
569 Views

Trying "Run My App" from develop tab

The "Run My App" pulled from the same source code. Meaning it still had the bug in it.

After trying that went to Debug tab so I could see the source code.

Still showed the bug in the source.

I then said screw it and renamed the file from xxaxxfn.js to xxaxxfnx.js

Changed reference in the index.html file.

This caused the load of the correct file and program ran without the bug.

Looked at the source in Debug and it was corrected source.

But, with further testing I noticed that a different file effects.js was also old.

I renamed this file to effectsx.js

Ran app. The program worked and the effect I needed worked. (navigator.app.exitApp() -- works like a champ).

After relaxing on whether or not my code fixes were fixes I renamed the files from effectsx.js to effects.js and xxaxxfnx.js to xxaxxfn.js

Ran app in Debug tab.

The old code returned.

Had the bug in xxaxxfn and the missing new effect code from effects.js

Don't know if this helps to debug.

Renaming files everything I make an edit is not my idea of a fun debug work cycle :) Reminds me too much of other systems I've worked with  in the past.

I did see this issue in the past. I think with the older XDK. But, at that time exiting the XDK fixed it -- or seemed to fix it.

I haven't tried rebooting the computer as yet. Do you think a reboot would make a difference?

 

0 Kudos
PaulF_IntelCorp
Employee
569 Views

Not so sure a reboot will make any difference. There is a new version coming out very shortly. If you can wait for that to see if it fixes the issue... Otherwise, if you can bundle up a sample that illustrates the problem, that would be useful to help debug the issue. We won't be able to address it until sometime during the week. By that time the new version will probably already be available. If you choose to provide a sample that causes the problem, please ZIP your entire project directory and attach it to a private message (click this Send Author A Message link) and attach the ZIP to that private message. If your project contains a plugins directory you can remove that from the ZIP to keep the file size down. Please provide some detailed instructions explaining how to reproduce the problem, in the private message.

0 Kudos
Claude_N_
Beginner
569 Views

Let's take the optimistic view that the new version will fix the problem.

So I'll wait for the new version.

Thanks

p.s. if that doesn't fix it, I'll be happy to provide a zip

0 Kudos
PaulF_IntelCorp
Employee
569 Views

Sounds good. That next version should be available very soon. It fixes a lot of issues (I'm running a pre-release copy).

0 Kudos
Igor_F_1
Beginner
569 Views

Bug still not fixed?

As of today bug is still present since I started using XDK. My version is 2893.

I wonder what is exactly the reason for not fixing this?

 

0 Kudos
Antonio_Za
Beginner
569 Views

I came around to solve my issue similar to this one and I read this post. Any news on the debug-refresh-gate?
My only solution, at the moment, is to delete the debug module and recharge it but it took many minutes and it's a boring task.

0 Kudos
PaulF_IntelCorp
Employee
569 Views

I haven't been seeing any reports of this issue for quite some time, and I haven't been experiencing it myself. Perhaps it is a function of the version of Crosswalk that has been selected in your Project settings? The custom debug module that the Debug tab builds is a function of that Crosswalk version. I recommend you use 16 or 17.

Another thing to try is selecting the "shared" crosswalk option (which will require a download of the Crosswalk shared library from the Google Play store), at least for the purpose of debug to see if that makes a difference. The shared library is currently version 17.

0 Kudos
Reply