-
Notifications
You must be signed in to change notification settings - Fork 264
Description
Hi @klayoutmatthias,
This question is regarding handling try/except cases in python modules loaded in KLayout.
On MacOS (I haven't checked on Windows), when a module is within the KLayout python folder, e.g., urllib3 in ~/.klayout/python/urllib3, and when you run a macro that uses that module, with the Macro Development window open, each try/except creates exceptions which pop up a GUI:
Caught the following exception:
....
Press 'Ok' to continue and 'Cancel' to stop in the debugger
However, if that module is installed in the system, e.g., pip install urllib3, then the same exceptions don't trigger the GUI.
And with the Macro Development window closed, you don't see these message and everything works fine.
What this means is that for modules that I develop and put in the KLayout path, I need to minimize the use of try/except, otherwise it makes debugging difficult (if you have to click "OK" 20 times before you get to the actual error you want to debug).
Is there any way to selectively disable the try/except dialogs for specific modules, or perhaps placing them in folders (salt/...) so they don't have these messages?