Community
Fusion API and Scripts
Got a new add-in to share? Need something specialized to be scripted? Ask questions or share what you’ve discovered with the community.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Printing infos to terminal with python

6 REPLIES 6
SOLVED
Reply
Message 1 of 7
luc.doppler
1271 Views, 6 Replies

Printing infos to terminal with python

Hello,

I started using Fusion's Python API but i'm not able to see where the content is shown when the "print" command is used. As I am launching the script from the "scripts & add-ins" window, nothing is shown in my VS Code terminal and I did not find a python terminal in Fusion.... And when I am trying to launch the script from VS Code (so that the print commands are shown in the terminal), it tells me the adsk module is missing....

 

For now I'm using the ui.MessageBox() as a print command but it's really not ideal...

 

Best regards

 

Luc

6 REPLIES 6
Message 2 of 7
PinRudolf
in reply to: luc.doppler

There is a nice article from Adam Nagy discussing some options: Mod the Machine: Log debug messages in Fusion 360 (typepad.com)

Message 3 of 7
goyals
in reply to: luc.doppler

@luc.doppler In next Fusion update, we are going to provide 'log' method which allow add-ins to print the message in Fusion text command window which can probably serve the purpose of print function. Thanks.



Shyam Goyal
Sr. Software Dev. Manager
Message 4 of 7
luc.doppler
in reply to: PinRudolf

thanks for the link ! it worked as expected !! 🙂

Message 5 of 7
luc.doppler
in reply to: goyals

okay thanks for the infos ! I'm looking forward to see it in the next version !

Message 6 of 7
therealsamchaney
in reply to: goyals

Thanks @goyals, is the log method you mentioned app.log()? If so, where can we find the log to read the results? Is it a flat file, or can we view it live in the Fusion GUI?

 

Thanks!

-Sam

Message 7 of 7

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report