Skip to content

Commit

Permalink
Merge PR # (Allow upcase logfile name in download_data.py)
Browse files Browse the repository at this point in the history
This merge brings PR # (Bug fix: allow uppercase log filename
in download_data.py, by @ihough) into the GEOS-Chem
"no-diff-to-benchmark" development stream.

This PR adds a fix so that dry-run log file names that are
fed to the download_data.py script can have mixed case.
Merge conflicts in CHANGELOG.md have also been resolved.

Signed-off-by: Bob Yantosca <[email protected]>
  • Loading branch information
yantosca committed Nov 19, 2024
2 parents f149b46 + 08e1512 commit af83cf8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- Updated `HEMCO_Config.rc` for carbon simulation to read data based on carbon species used
- Fixed entries for CO2 emissions in `ExtData.rc.carbon`
- Fixed metals simulation name in config file template comments
- Fixed bug in `download_data.py` which caused script to fail if log filename contained uppercase characters.

## [14.5.0] - 2024-11-07
### Added
Expand Down
6 changes: 4 additions & 2 deletions run/shared/download_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -726,14 +726,16 @@ def parse_args():

# Parse command-line arguments (argument 0 is the program name)
for i in range(1, len(sys.argv)):
arg = sys.argv[i].lower()
arg = arg.lstrip('-')
arg = sys.argv[i]

if not dryrun_found:
dryrun_log = arg
dryrun_found = True
continue

# Normalize arguments other than dryrun_log
arg = arg.lower().lstrip('-')

if not portal_found:
for mir in portal_list:
portal = mir.lower()
Expand Down

0 comments on commit af83cf8

Please sign in to comment.