Stopping the server or reconnecting without killing Fusion

Stopping the server or reconnecting without killing Fusion

TRIALCAD2014
Enthusiast Enthusiast
1,015 Views
7 Replies
Message 1 of 8

Stopping the server or reconnecting without killing Fusion

TRIALCAD2014
Enthusiast
Enthusiast

every now and then, sometimes 10 times a day when I try to run a script in debug I get this message.

WHen I click Cancel the server stop button in VS is  not available. In Fusion I can still run the script but if If I try to re-launch in debug I get the same message.
Only stopping and restarting Fusion works ut there must be a less dramatic way to either reattach or stop it. 
I even tried to hunt down the pid but nothing worked.

 

TRIALCAD2014_0-1643329704376.png

 

 

 

TRIALCAD2014_1-1643329967972.png

 

 

Thank you,
Adrian

 

 

0 Likes
1,016 Views
7 Replies
Replies (7)
Message 2 of 8

kandennti
Mentor
Mentor

Hi @TRIALCAD2014 .

 

I would like to know how to do it too.
In the end, the only way I can figure out how to fix it is to restart Fusion360.

0 Likes
Message 3 of 8

j.han97
Advocate
Advocate

What happened before this error? 

 

From my experience there usually are two reasons:

1. The add-in is still running and I tried to run the add-in again.

2. There is another script/add-in in debug mode.

 

 I'm interested in experimenting with this if you can provide a way/description to reproduce your exact situation.

Message 4 of 8

TRIALCAD2014
Enthusiast
Enthusiast
I modified my setting to
{
"version": "0.2.0",
"configurations": [
        {
"name": "Python: Attach using Process Id",
"type": "python",
"request": "attach",
"processId": "${command:pickProcess}"
        },
        {
"name": "Python: Attach",
"type": "python",
"request": "attach",
"pathMappings": [
                {
"localRoot": "${workspaceRoot}",
"remoteRoot": "${workspaceRoot}"
                }
            ],
"osx": {
"filePath": "${file}"
            },
"windows": {
"filePath": "${file}"
            },
"port": 9000,
"host": "localhost"
        }
    ]
}

and then I tried to run that select the existing PID. That should work
but so far for me no luck.
0 Likes
Message 5 of 8

TRIALCAD2014
Enthusiast
Enthusiast
I do not recall a consistent scenario. It usually happens when I switch
back between the VS debug and Fusion interface while some code is still
executing.

I think VS thinks server is stopped when the Fusion server becomes
unresponsive. At that point SV abandons showing the disconnect double
link in the menu.

0 Likes
Message 6 of 8

j.han97
Advocate
Advocate

I see. I don't think my experience can relate to your matter unfortunately.  

 

Have you tried re-attaching from Fusion 360? Since you mentioned that you can run the script in F360, I assume that it is alive (responding). I would try debugging the script (click Edit instead of Run) from F360 again to re-attach them. 

 

Message 7 of 8

TRIALCAD2014
Enthusiast
Enthusiast

"I would try debugging the script (click Edit instead of Run) from F360 again to re-attach them. "

Well.. the second screen capture shows what you get when you try that.
As I mentioned, I can still 
normally run the script from Fusion .
Thank you for trying to look into it 🙂

0 Likes
Message 8 of 8

j.han97
Advocate
Advocate

I have never met this situation before... Seems like I have not spent enough time working with Fusion 360 (fortunately)