[BUG] Error when running model with no existing capacity profile
Describe the bug
I have a very simple model set up with only one sector with one technology. I seem to be getting the following error message: 'RuntimeError: Subsector with TRA_DMD_PCAR_PET_01 has no output commodities' This error seems to be appearing when the existing capacity file has only 0 values specified for all years of the simulation or 0 in the first year and an existing capacity specified from a later year onwards. If I specify a capacity in the first year or a retirement profile, I don't get any errors. Additionally I don't see the error If I set an arbitrarily small number in the first year. Also, I don't seem to be getting this error when I have a model set up with multiple sectors and technologies.
I am not quite sure what is causing the 'commodities' variable to be empty and have a length = 0 which leads to the error.
The full error message is:
Traceback (most recent call last):
File "/Users/sharwaridixit/anaconda3/envs/muse_env/lib/python3.9/runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/Users/sharwaridixit/anaconda3/envs/muse_env/lib/python3.9/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/Users/sharwaridixit/.vscode/extensions/ms-python.debugpy-2024.0.0-darwin-arm64/bundled/libs/debugpy/adapter/../../debugpy/launcher/../../debugpy/main.py", line 39, in
To Reproduce
I have attached the folder with the input files; the existing capacity file currently has a 0 capacity for all the years therefore running the model should show the error. Transport_trial_model_cars_e10.zip
Context
Please, complete the following to better understand the system you are using to run MUSE.
- Operative system (eg. Windows 10): MacOS
- MUSE version (eg. 1.0.1): Version 1.1.0
- Installation method (eg. pipx, pip, development mode): Virtual environment-based installation
- Python version (you can get this running
python --version): 3.9.19