OpenSeesPy icon indicating copy to clipboard operation
OpenSeesPy copied to clipboard

Debugging OpenSeesPy

Open siwalan opened this issue 3 years ago • 3 comments

Dear Dr. Zhu,

Is it possible to debug a code addition to OpenSeesPy? In Windows, for the TcL version, debugging seems straightforward. Visual Studio (VS) debugger will run a TcL interpreter that can be debugged directly. I am wondering if it possible to do the same with with the OpenSeesPy module in OpenSees.

siwalan avatar Jul 19 '22 03:07 siwalan

Try print statements (opserr). That might be easier :)

mhscott avatar Jul 19 '22 22:07 mhscott

I think you could. It'll be like debugging a dll library through VS debugger. Yes, sometimes, print is way easier.

zhuminjie avatar Jul 19 '22 22:07 zhuminjie

Thanks Dr. Zhu and Prof. Scott for the feedback, I would try to look a dll library debugger. I have googled some but I don't really think it would work because VS won't open a python prompt/interpreter.

I am also open other methods for debugging OpenSeesPy, either on Linux or other Windows IDE. I was wondering if other people has setup a debug workflow directly in their IDE.

print() is an alternative.. but sometimes line by line step is useful for me. Furthermore, compilation takes time @ my side...

siwalan avatar Jul 21 '22 09:07 siwalan