Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Coastal Blue Carbon error with just one snapshot year #1534

Closed
emlys opened this issue Feb 23, 2024 · 1 comment · Fixed by #1565
Closed

Coastal Blue Carbon error with just one snapshot year #1534

emlys opened this issue Feb 23, 2024 · 1 comment · Fixed by #1565
Assignees
Labels
bug Something isn't working in progress This issue is actively being worked on
Milestone

Comments

@emlys
Copy link
Member

emlys commented Feb 23, 2024

A user reported an error in CBC:

File “natcap\invest\coastal_blue_carbon\coastal_blue_carbon.py”, line 956, in execute
KeyError: ‘soil’

The model is expecting there to be more than one snapshot year, ultimately causing this KeyError. A possible workaround is to set the Analysis Year to the snapshot year + 1, but that shouldn't be necessary. @phargogh confirmed over slack that CBC should work with just one snapshot year, though results will be very limited.

@emlys emlys added the bug Something isn't working label Feb 23, 2024
@emlys
Copy link
Member Author

emlys commented May 2, 2024

On the team call today, we agreed to disallow running the model with just one year. Without at least one year for carbon to accumulate, the model is pretty useless. A user trying to run with just one year probably misunderstands something.

emlys added a commit to emlys/invest that referenced this issue May 2, 2024
emlys added a commit to natcap/invest.users-guide that referenced this issue May 2, 2024
@emlys emlys added the in progress This issue is actively being worked on label May 6, 2024
@emlys emlys self-assigned this May 6, 2024
@emlys emlys added this to the 3.14.2 milestone May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working in progress This issue is actively being worked on
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant