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

[BUG] models/gmao.py:149 Undefined names dt, crs #673

Open
garlic-os opened this issue Jul 15, 2024 · 0 comments
Open

[BUG] models/gmao.py:149 Undefined names dt, crs #673

garlic-os opened this issue Jul 15, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@garlic-os
Copy link
Contributor

Describe the bug
Ruff reports that the variables dt and crs, used below, are not defined.

try:
# Note that lat/lon gets written twice for GMAO because they are the same as y/x
writeWeatherVarsXarray(lats, lons, h, q, p, t, dt, crs, outName=None, NoDataValue=None, chunk=(1, 91, 144))
except Exception:
logger.exception("Unable to save weathermodel to file")

RAiDER proceeds without any error because this line is wrapped in a bare try-except. I suspect this try-except was not meant to catch this error in particular, but since it didn't specify an exception it must have slipped through.

Desktop (please complete the following information):

  • RAiDER git tag:
    commit 2a34802 (HEAD -> dev, tag: v0.5.2, upstream/main, upstream/dev, upstream/HEAD)
    Merge: 223d862 2b7190c
    Author: Jeremy Maurer [email protected]
    Date: Mon Jul 15 11:54:29 2024 -0500

    Merge pull request v0.5.2 #670 from dbekaert/dev

    v0.5.2

  • OS: Arch Linux 5.15.153.1-microsoft-standard-WSL2 on Windows 10

@garlic-os garlic-os added the bug Something isn't working label Jul 15, 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
Projects
None yet
Development

No branches or pull requests

1 participant