When instantiating Experiment, the attribute use_localhost variable is not set within __init__ until after config_setup is called. However, in line 35 config_setup calls self.use_localhost which triggers this AttributeError:
Traceback (most recent call last):
File "run_project.py", line 24, in <module>
run_project(args)
File "run_project.py", line 7, in run_project
exp = Experiment(config_path=in_args.config_path, use_localhost=in_args.use_localhost)
File "/Users/mohammadharisshuaib/Software/mlops_test/mlops_env/lib/python3.7/site-packages/mlops-0.1-py3.7.egg/mlops/Experiment.py", line 19, in __init__
File "/Users/mohammadharisshuaib/Software/mlops_test/mlops_env/lib/python3.7/site-packages/mlops-0.1-py3.7.egg/mlops/Experiment.py", line 35, in config_setup
AttributeError: 'Experiment' object has no attribute 'use_localhost'
Moving self.use_localhost = use_localhost up in the __init__ method before the config_setup means it works.
When instantiating Experiment, the attribute use_localhost variable is not set within
__init__
until after config_setup is called. However, in line 35config_setup
callsself.use_localhost
which triggers thisAttributeError
:Moving
self.use_localhost = use_localhost
up in the__init__
method before the config_setup means it works.