1

In Rodeo, if my script A imports a module B, and I make modifications to module B after running script A once, I have to restart the session in order for my script A to read the updated module B, in the process wiping my workspace and namespace clean. Is there a way to iterate quickly on importing B into A in a less disruptive way?

selwyth
  • 2,417
  • 16
  • 19

2 Answers2

2

I do this with exec.

exec(open("Path/To/Script/A.py").read())

Also, Rodeo is undergoing rapid development so it's helpful if you put your version number in the question. I recommend checking out the latest version, 1.4.9, downloadable from the Rodeo project page on github. But keep an eye out for updated versions as they're coming in almost daily at this point.

Ben
  • 20,038
  • 30
  • 112
  • 189
1

Try this:

import moduleB
reload (moduleB)

after new edits in ModuleB you can just use reload(moduleB)

Rajiv Sharma
  • 6,746
  • 1
  • 52
  • 54