Debugging Flex

Hello,

When I want to launch a debug sometimes the code launched is not up to date, it's an older version. To resolve this I need to delete the folder and change the debug configuration to compile in a different directory.

I'm working on Intellij IDEA 12 and I launch the debug through a url.

Thx

9 comments

Can this be caused by a browser caching something?
How do you deploy output SWF and other auxiliary files to the server?
When you see the problem next time please find the output SWF on the disk using any file manager and check its timestamp. IntelliJ IDEA may skip compilation if no files were touched within the source roots since previous compilation, but if any was edited - SWF must be recompiled.

0

I don't think it's the browser cache because I get it on all browsers and it arrives after a while not immediatly.
My computer is the server. By the way it's a mac.
When I set a breakpoint in the new code the debug breaks in the older version.

0
it arrives after a while not immediatly

What do you mean?

When I set a breakpoint in the new code the debug breaks in the older version.

I want to be sure that I understood you correctly. What does 'breaks in older version' mean? Probably a couple of screenshots would explain better than words.

Are all you source files are located in the source folders? Do you compile SWF using IDE? Haven't you ocassionally removed 'Make before launch' task from run configuration (Run | Edit Configurations) or checked 'Skip compilation' for the build configuration (Project Structure dialog). I can check you project Structure if you attach all yor *.iml files and .idea folder contents zipped.

0

I mean it happens after some compilations.

for example :
     The new version :
Capture d’écran 2013-11-20 à 16.10.03.png

     The old version

Capture d’écran 2013-11-20 à 16.10.53.png
When I launch the debug it will always use the JPEGEncoder and not the PNGEncoder.

"Make before launch" is always set and "skip compilation" is disabled.



Attachment(s):
Archive.zip
0

Avoid overridding main class in the run configuration. This option is done for testing temporary apps for which you don not want to configure build configuration (BC). Since your BC already contains correct main class and output file name you shouldn't override it in the run configuration.

I don't see any other problems in project structure so if the updated file is in the source folder then its change must trigger recompilation on next Debug launch. Could it be the server implementation caching old SWF? When you see the problem again please see the timestamp of the output SWF file. I'm sure it will be bigger than the timestamp of the latest edited source file. Try to launch the app not via URL, but as a local file - if app behavior will be different from what you get via URL that would mean that your server is giving old cached SWF.

0

I will look if I have a cache system on my server.

0

You were right it was the server.

Thx

0

Please sign in to leave a comment.