Closed fletchapin closed 6 years ago
@ethan92429 Where should we be writing this code? Should it be added to play.py or somewhere else to make sure that the warning is triggered correctly?
@AguaClara/aide_design to warn when something is imported that shouldn't be, you need to put in a deprecation warning. Here's a little tutorial on it. Basically, just add this code whenever you want to push a warning:
import warnings
warnings.warn(This is the deprecation method",DeprecationWarning )
Now put this at the top of the expert_inputs.py, or whatever file you are deprecating.
We added the warning to expert_inputs with an explanation that constants.py and optional_inputs.py will be used instead. This was tested and when the aide_design.play package imports (or when just expert_inputs is imported), the error message is shown.
expert_inputs.py has become constants.py
added: optional_inputs.py
Need to write code that allows exp_inputs to be used if called (by making the current constants.py available to it, but send error messages to let the user know that the exp_inputs it is deprecated.