Adobe-Runtime-Support icon indicating copy to clipboard operation
Adobe-Runtime-Support copied to clipboard

Can't connect AIR debugger with AIR 51.x

Open yvant opened this issue 1 year ago • 5 comments

Hi, I tried to connect my phone with usb using AIR 51.1.1.5 and ran my project in debug mode. The game launches and gets installed on the device, however it doesn't connect to FlashDevelop anymore like it used to. I tried to use other 51.x AIR versions, but they don't seem to work either. I work on Windows. Has something changed?

yvant avatar Oct 07 '24 23:10 yvant

Which option are you choosing in the FlashDevelop packager script? (And from that I can check which OS you're using ..) - presumably though, seeing as FlashDevelop is able to install the app package onto the phone, then there's nothing wrong in the actual connection.

Plus - is this the case even for a basic test case app? Are you using Workers in your own app, I know we had some issues with those at one point.

Did any of the versions you've tried recently work in the past? The debug connection might be an incoming socket into the computer (depending on which option you chose) and firewalls sometimes block that.. if you do have a firewall log you can check, it might be worth seeing if it's denying anything on port 7936 (or are you changing the port?)

ajwfrost avatar Oct 08 '24 06:10 ajwfrost

Here's my output, including the command line: mxmlc-cli -load-config="C:\Users\Yvan\AppData\Local\FlashDevelop\Apps\flexairsdk\4.6.0+51.1.1.5/frameworks/airmobile-config.xml" -load-config+=obj\dominationNAPE-AIR-DEBUGConfig.xml -debug=true +configname=airmobile -default-script-limits 1000 5 -swf-version=51 -o obj\dominationNAPE-AIR-DEBUG638639972191251305 Running java as: C:\Program Files\Eclipse Adoptium\jdk-17.0.11.9-hotspot\bin\java

I'm using Windows11.

I tried to go back to AIR 50.2.5.1, and the debugging works, so it seems related to 51.1.x

yvant avatar Oct 08 '24 13:10 yvant

I don't use workers.

yvant avatar Oct 08 '24 13:10 yvant

Is there a solution to debug with the latest AIR SDK? It's quite an hassle to switch from one SDK to the other one since the swf version / namespace is not the same.

yvant avatar Oct 10 '24 23:10 yvant

Ah so are you just debugging on Windows directly i.e. hitting F5 or Ctrl-Enter?

It's working for us when we try running it manually:

  • Open a new command prompt, go into the Flex+AIR folder, "bin" directory, and run "fdb.exe"
  • Type "run" to put FDB into listening mode
  • Run the application up (either from FlashDevelop - which should then give you a debugger failure - or via ADL directly) The FDB process should tell you it's connected and wait for you to send in breakpoints or enter 'c' to continue.

First time I set up Flex 4.6 + AIR 51.1 in FlashDevelop, it didn't hit the breakpoints automatically. Switching over to Flex 4.6 + AIR 50.2 and it still didn't hit them! But then I've just tried again and it's working now with Flex 4.6 + AIR 51.1. Really not sure what the difference is here..

The "fdb.jar" file hasn't changed in our AIR SDK releases - but that shouldn't be used anyway, it's not in the Flex-specific versions of the SDK. So then, you presumably are using the same fdb.exe and fdb.jar files in both of those environments as this comes from the same Adobe Flex SDK..?

In which case the only difference is in the use of 51.1.. but the compiler would be the same in all cases so the SWFs shouldn't be much different, just the namespace.

It seems a bit dependent on other factors (like what else you may have run..) - I've got FlashDevelop set up with Flex 4.6 + AIR 51.1.1.5 currently but it's managing to run a debugger that's not there (I just removed all the fdb / fdb.exe / fdb.jar from that SDK!). And according to my Windows task manager, despite the fact I'm sat in a breakpoint, this is not happening from any fdb.exe process, or java.exe either.

I do have "fcsh.jar" running though. This is launched by FlashDevelop when I compile. It doesn't seem to mind the lack of fdb.jar, it's still hitting a break point (I've just restarted FlashDevelop too..). Plus of course, FlashDevelop has its own version of fdb.jar in the installation...

Are you able to check if it works when you manually run it? Or alternatively: if you can launch the app via ADL directly, what happens if you use FlashDevelop to compile but then use Debug -> Start Remote Session, and once that says "Starting debug session with FDB" you can then run it via ADL on the command line - it should then connect?

thanks

ajwfrost avatar Oct 11 '24 14:10 ajwfrost