Script editor does not activate when trying to edit a API script

Script editor does not activate when trying to edit a API script

neill2JECV
Observer Observer
593 Views
4 Replies
Message 1 of 5

Script editor does not activate when trying to edit a API script

neill2JECV
Observer
Observer

Hi. I am just starting to learn API Scripts in Fusion 360.

 

I am running 

Fusion 360 2.0.15293 x86_64
Active Plan: Personal
Windows 10 Home 22H2 (19045.2486)

 

when I go to edit a API Script, either one that I have created through the add-ins menu or a sample one, I press Edit and no editor is displayed or running in the back ground. Any ideas

 

I can load the sample Scripts outside of Fusion using VS Code running Python, with no issue. Is it possible to make this my default editor when editing Scripts through the Add-In menu options.

 

 

0 Likes
594 Views
4 Replies
Replies (4)
Message 2 of 5

aliobidi
Collaborator
Collaborator

Hi, 

reinstall python if not working reinstall Fusion 360 and in this case mean python can't looking to Fusion 360 for some reason  

0 Likes
Message 3 of 5

BrianEkins
Mentor
Mentor

Fusion uses its own installation of Python and does not rely on you having installed it. You can install Python if you're using it for other projects, but it will be completely independent of the Python Fusion is using.

 

For most people, activating VS Code from Fusion isn't a problem, but the problem you're describing has been occasionally reported. The problem is trying to understand why it's failing on your machine. To try and track down these issues some additional logging is done when you try to edit a script. If you look on your machine at the location below, where the 200809200298146 portion of the path will be a number specific to you.:

 

%localappdata%\Autodesk\Autodesk Fusion 360\200809200298146\logs

 

Inside the logs folder, you'll see several .log files. Try editing a script and then look for the most recent log file. At the bottom, there should be some lines related to VS Code. Here's the first line I see in my log file, and there are a few dozen lines after this with the "VSCode:" identifier. Hopefully, there's a clue about what's going wrong with your system. 

20230205T193910 I .41504 VSCode:Getting current tab
---------------------------------------------------------------
Brian Ekins
Inventor and Fusion 360 API Expert
Website/Blog: https://EkinsSolutions.com
Message 4 of 5

aliobidi
Collaborator
Collaborator

sorry I mean another version of python 

0 Likes
Message 5 of 5

neill2JECV
Observer
Observer

Hi Brian

I have reinstalled both Fusion 360 & Python ( as I am learning how to program in this, outside of Fusion 360).

When I create a script through the Utilises menu and then try to edit it, it does not show VSCode, but it does not show any errors. However you can carry on working in Fusion 360. I then went to look a the log file at

C:\Users\Neill's PC\AppData\Local\Autodesk\Autodesk Fusion 360\logs and there is not a Log file for today. I looked in the last Log file and there is no VSCode entry.

Any thoughts

Cheers Neill

0 Likes