aroberge / reeborg

Enhanced Karel-the-robot clone
http://reeborg.ca/reeborg.html
Other
47 stars 36 forks source link

Catch mistakes due to misusing "from library import *" #420

Closed aroberge closed 6 years ago

aroberge commented 6 years ago

There should be a secret/hidden variable in library (RUR._import_all_from_library=True )that could be looked for and, when specified in the pre/post code, raise an error saying that this should not be used. Perhaps a function like RUR.prevent_import_star() could be used in the Post editor. This variable would have to be reset to False each time a world is reloaded

aroberge commented 6 years ago

Closing this issue until I have an actual case reported where this could be useful.