12 Replies Latest reply on Oct 12, 2007 11:13 AM by mike_morearty

    FB3 Beta 2 Flash Player debug question

    Martin-R
      I saw the post concerning the "not a bug" in the new flash player. So, my question is, exactly how do I deploy Flex apps so I don't get the "Where is the debugger or host applicaton running" question?

      I get this annoying question everytime I run the app, on any computer, with both IE7 & IE6. I can't let my end users run the app this way. Does anyone have an answer to this?

        • 1. Re: FB3 Beta 2 Flash Player debug question
          Tanya Dimalsky (adobe) Level 1
          Hi Martin-R,
          Do you have the debug player plugin installed for IE and still seeing this error message? You can try to reinstall flash player, the installer can be found under
          [flexbuilder 3 install dir]\flex builder 3\player\

          After you reinstalled the player, you can visit this site to make sure the player installed correctly
          http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_15507
          version you should have is 9,0,60,235
          Thanks!
          -Tanya
          • 2. Re: FB3 Beta 2 Flash Player debug question
            ianils Level 1

            It would appear that by default Flex3 Beta2 now creates a 'debug' version , so even for 'testing' you are using a bloated , debug SWF . If the debug player is installed , it sees that its a swf that contains debug so therefore looks for the 'debug server' and you get that annoying pop up .

            To build a non-debug (ie. production ) SWF you need to do :

            Project -> Export Release Version

            To me this is a major pain the butt .. I dont always want to run a debug version ..
            but if I do I have to install the debug player , which then means I get the annoying pop-up when I just hit run
            . If I dont want to have to see that pop up I can go ahead and do a Project -> Export Release Version and run that one , but
            thats another hassle as the export release doesnt update automatically .

            hope this makes sense ..

            • 3. Re: FB3 Beta 2 Flash Player debug question
              edfrk
              I followed the "export release version" steps (hurrah for having to do more steps!) and deep linking doesn't seem to work in the swf it creates. Actually no BrowserManager commands work. I added this comment to the bug at http://bugs.adobe.com/jira/browse/FB-9464.
              • 4. Re: FB3 Beta 2 Flash Player debug question
                mike_morearty Level 1
                I wanted to clarify a couple of things about how this new model (creating a single debug swf, then exporting a release one later) works. Of course we do want to hear feedback, but it might help to understand the following points:

                1. If you install the (beta) Flash player that came with this Flex Builder beta, then you will NOT see the "Where is the debugger" dialog. The Flash Player and Flex Builder changes go hand-in-hand. Certainly I agree that with the Flash player's old behavior, having Flex Builder create only a debug swf would cause lots of problems; that's why we changed both. It is true that there will be a transition period during which some developers will have the old debugger-player installed, so they will see this message; that's unfortunate, but it won't last too long. But customers will never see it, because...

                2. Your customers will NOT need to upgrade their Flash player, because the "release" version of the Flash player -- the one that all your customers have -- never asks "Where is the debugger." The old version didn't, and neither will the next one.

                To summarize: The only scenario where this is a problem is if you run (not debug) a debug swf in an older version of the debug player. It is not a problem for people who have the release player (almost all customers); it is not a problem for machines on which Flex Builder was installed with the default options, which includes installing the new debug Flash player.

                As for the number of steps in the new way vs. the the old way, I feel that the new way does not demand more of you than the old way; let me explain why. What you really want is:

                1. few steps during the edit/compile/debug-or-run cycle; and
                2. few steps when you are ready to deploy your app.

                As for (1), I think the reason it appeared to you that the number of steps had increased was that you had the older player installed, so it appeared that exporting a release version was a necessary step during the edit/compile/debug-or-run cycle. In fact, though, you shouldn't need to make a release version during that cycle. This is similar to the Eclipse JDT for Java development, where, during the normal cycle, you are not creating a release JAR file -- you are just creating individual .class files (with debugging info in them).

                As for (2), the previous way to deploy was to first manually delete myapp-debug.html and myapp-debug.swf from the output directory, and then copy the rest of the files to their final destination. With the new process, you don't have to worry about manually deleting the debug files.

                I also wanted to offer some of the reasons we made this change:

                - Performance: It always helps to only have to link one swf instead of two during the edit/compile/debug cycle.

                - Filenames: There are several cases where the filename of the swf is important; with the new way, the filename of the swf is always the same. For example, if you are using modules, then you have to write this:
                <mx:ModuleLoader url="MyModule.swf" />
                But with the old model, you would have to write this during development:
                <mx:ModuleLoader url="MyModule-debug.swf" />
                ... and then change it before deployment. Yuck. So then people started using binding to work around this:
                <mx:ModuleLoader url="{mungeFilename('MyModule-debug.swf')}" />
                where mungeFilename() tries to figure out the correct filename. A little less horrible than having the modify the filename before deployment, but still not pretty.

                I hope this helps a little. I'm interested to hear what you think, and whether you think changes are still required even despite the above explanation. Thanks for trying the beta, we appreciate the feedback!
                • 5. Re: FB3 Beta 2 Flash Player debug question
                  ron_zoni
                  I have been struggling with flex builder and compiling for awhile. Sometimes it's just not clear what's going on. I moved everything to ant builds (not flex ant tasks, either. they didn't quite work the way I needed, although I tried (for hours)).

                  The only thing I didn't get around to doing was ant tasks to compile my runtime css into swfs, for that I just did project - clean.

                  So when I updated to flex builder 3 beta 2, this didn't work.
                  First, I point to a mapped drive under Flex Build Path - > output folder. Building a project would now result in this:
                  X:\myprojects\project\Documents and Settings\ferullog\my local drive\my local project\assets\css\myCss.swf.
                  Instead of this:
                  X:\myprojects\project\assets\css\myCss.swf

                  Second, my css swfs where 22 K instead of 6K. I assumed they had debug info in them, so eventually I found this blog. I published the export release version way (recieved an error because I don't have an mxml file with the same name as my project) it compiled, and I was left with a 15k css file.

                  After that I switched to ant, and made a task just to compile the css. Nice and easy. Although, I still have a 15K swf instead of 6K..maybe that's just how it is.
                  • 6. Re: FB3 Beta 2 Flash Player debug question
                    mike_morearty Level 1
                    Ron, where does the 6K number come from -- is that the size it had in an earlier version of Flex Builder?
                    • 7. FB3 Beta 2 Flash Player debug question
                      ron_zoni Level 1
                      Actually, it's an earlier SDK. When I compile with SDK 2.0.1 my css files are smaller than when I compile with SDK 3.0.0.
                      All I'm doing is this:
                      mxmlc style.css
                      • 8. Re: FB3 Beta 2 Flash Player debug question
                        mike_morearty Level 1
                        Okay, I logged a bug (https://bugs.adobe.com/jira/browse/SDK-13014) for someone to take a look at regarding the larger file size.

                        Regarding the problem with messed-up paths, I tried, but was unable to reproduce that problem...
                        • 9. Re: FB3 Beta 2 Flash Player debug question
                          Cholerae
                          Not installing the debugplayer is not an option for me, as I need a debug player to use the firefox flash tracer extension, which I need to debug flex and non-flex flash projects. So now I have to click that annoying dialog-box every time I build a flex 3 app.

                          It IS a bug, so please fix it.
                          • 10. FB3 Beta 2 Flash Player debug question
                            ron_zoni Level 1
                            Mike, just to verify, you can't reproduce the path problem with your "output path" set to a mapped drive?

                            I looked at the generated actionscript for the css files from both SDKs and they're the same, I'll check the bug forum for updates to this problem, but I wanted to ask if Adobe will ever provide a way to decompile a AS3 swf..?
                            I'm thinking about buying some 3rd party software (ASV or AVE Imperator) for this, but I'm not sure how well they work...
                            • 11. Re: FB3 Beta 2 Flash Player debug question
                              mike_morearty Level 1
                              quote:

                              Originally posted by: ron zoni
                              Mike, just to verify, you can't reproduce the path problem with your "output path" set to a mapped drive?


                              Right. Here is what I tried -- please tell me if this is the same as what you did:

                              1. Build Automatically is turned on
                              2. Map a server to drive X:
                              3. New Flex Project "xyz", in my default location, C:\Users\mmoreart\runtime-flexbuilder\xyz; click Next; change output directory to X:\m\mmoreart\bin
                              4. File > New > CSS file; mycss.css, in the "src" directory
                              5. Right-click on mycss.css > Compile CSS to SWF

                              At this point, the "bin" folder, which is a link to X:\m\mmoreart\bin, has mycss.swf. (It also has mycss.css, left over from when I first created the css file; if you clean the project, that file goes away, but mycss.swf is still regenerated in the right place.)

                              quote:

                              Originally posted by: ron zoni
                              I looked at the generated actionscript for the css files from both SDKs and they're the same, I'll check the bug forum for updates to this problem, but I wanted to ask if Adobe will ever provide a way to decompile a AS3 swf..?
                              I'm thinking about buying some 3rd party software (ASV or AVE Imperator) for this, but I'm not sure how well they work...


                              Good question -- as far as I know we don't have any plans to ship a tool to do that. I will pass on the request though.
                              • 12. Re: FB3 Beta 2 Flash Player debug question
                                mike_morearty Level 1
                                Cholerae: Please install the beta debug player that came with the Flex Builder 3 beta. It is in the "Player" directory. Once you do that, you will NOT need to click the dialog box every time you build a Flex 3 app.