The-OpenROAD-Project / OpenROAD

OpenROAD's unified application implementing an RTL-to-GDS Flow. Documentation at https://openroad.readthedocs.io/en/latest/
https://theopenroadproject.org/
BSD 3-Clause "New" or "Revised" License
1.41k stars 494 forks source link

gui: properly stop on exit in a script #5258

Closed openroad-robot closed 1 week ago

openroad-robot commented 1 week ago

Ugly solution to get TCL to stop executing a script containing "exit".

Fixes #5252

maliberty commented 1 week ago

@gadfort if you have any smarter ideas I'm open.

github-actions[bot] commented 1 week ago

clang-tidy review says "All clean, LGTM! :+1:"

gadfort commented 1 week ago

@maliberty would it be possible to add a boolean to the scriptwidget to indicate an exit is happening and then just toggle it from the tclwidget? That would atleast avoid the string comparing and setting the result in tcl.

maliberty commented 1 week ago

@gadfort I don't think so because we need to stop TclEval and the only way I can see is to return an error. Since I don't want to print the error I don't see a better way.