1 Reply Latest reply on Jun 24, 2010 7:53 AM by Anirudh Sasikumar

    Debugging AS3 under eclipse 3.4 / Flex builder 3.0.2

    flex-puzzler

      Hello

      I use Flex for a short time, use a bit pushed to my client for a solution-oriented monitoring.

      Background:

      Platform:

      • Windows XP
      • Eclipse 3.4 Ganymede
      • Flex Builder 3.0.2 Licenced
      • JDK 1.6_20
      • Firefox 3.6
      • Flash Player 9 (Debug version)
      • Server: OSGI (Eclipse equinox) an instance of jetty service allows HTTP requests


      Requirements:
      Make debugger in ActionScript by putting "BreakPoint" to assess the contents of variables.

      Problem:
      The code does not stop at breakpoint, worse, if a breakpoint is enabled, the module flex does not start.

      Actions:
      • Reinstall all the dev environment (Eclipse, Flex Builder, Flash Player): KO
      • Removing repo maven modules and complete rebuilds: KO
      • Restarting Windows: °) KO

      Logs:
      this is what the log contains just after launching the platform (modules) in debug mode.

      java.lang.NullPointerException
      Has com.adobe.flexbuilder.debug.breakpoints.FlexLineBreakpoint.findSourceFiles (FlexLineBreakpoint.java: 388)
      Has com.adobe.flexbuilder.debug.breakpoints.FlexLineBreakpoint.instantiate (FlexLineBreakpoint.java: 442)
      Has com.adobe.flexbuilder.debug.model.FlexDebugTarget.breakpointAdded (FlexDebugTarget.java: 981)
      Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ FdbThread.installDeferredBreakpoints (FlexDebugTarget.java: 631)
      Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ FdbThread.advanceStateMachine (FlexDebugTarget.java: 662)
      Has com.adobe.flexbuilder.debug.model.FlexDebugTarget FdbThread.access $ $ 6 (FlexDebugTarget.java: 636)
      Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ 1.run (FlexDebugTarget.java: 738)
      Has org.eclipse.core.runtime.SafeRunner.run (SafeRunner.java: 37)
      Has org.eclipse.core.runtime.Platform.run (Platform.java: 880)
      Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ FdbThread.eventLoop (FlexDebugTarget.java: 718)
      Has com.adobe.flexbuilder.debug.model.FlexDebugTarget $ FdbThread.run (FlexDebugTarget.java: 779)
      at java.lang.Thread.run (Thread.java: 619)

        • 1. Re: Debugging AS3 under eclipse 3.4 / Flex builder 3.0.2
          Anirudh Sasikumar Adobe Employee

          Can you ensure that the SWF your are debugging is a release SWF?

           

          I've recently fixed a bug (which is not publicly available) where the same stacktrace was visible:

           

          A release SWF loads a debug SWF via SWFLoader/ModuleLoader, etc.

           

          Making sure the main container SWF is a debug one. That should fix this problem.

           

          (You can check whether a SWF is debug or not by opening it in nemo440 (google for that) and looking for debugfile / debugline opcodes.)

           

          Let me know how it works out.

           

          Cheers,

          Anirudh

          1 person found this helpful