MUSE_OS icon indicating copy to clipboard operation
MUSE_OS copied to clipboard

Fix for models with no existing capacity (v2)

Open tsmbland opened this issue 1 year ago • 0 comments

Description

Models were previously raising a RuntimeError if the existing capacity for a technology was zero for all years (based on a check in the factory method of the Subsector class). I have removed this check, and modified subsequent steps so it can handle this case.

Fixes #286

Type of change

Please add a line in the relevant section of CHANGELOG.md to document the change (include PR #) - note reverse order of PR #s.

  • [ ] New feature (non-breaking change which adds functionality)
  • [ ] Optimization (non-breaking, back-end change that speeds up the code)
  • [x] Bug fix (non-breaking change which fixes an issue)
  • [ ] Breaking change (whatever its nature)

Key checklist

  • [ ] All tests pass: $ python -m pytest
  • [ ] The documentation builds and looks OK: $ python -m sphinx -b html docs docs/build

Further checks

  • [ ] Code is commented, particularly in hard-to-understand areas
  • [ ] Tests added that prove fix is effective or that feature works

tsmbland avatar May 09 '24 13:05 tsmbland