How to Reload Modules in SageMath

reload() Method

reload() method reloads a previously imported module. It enables you to test a updated version of the module without leaving the sage command line.

sage: reload(module)

Reloading modules for Python 3.4 and above

Use importlib package.

sage: import importlib

sage: importlib.reload(module)

Leave a Reply

Your email address will not be published. Required fields are marked *