Skip to content

FMS2: open_ASCII_file and open_namelist_file#206

Merged
Hallberg-NOAA merged 1 commit into
NOAA-GFDL:dev/gfdlfrom
marshallward:read_ascii
Sep 22, 2022
Merged

FMS2: open_ASCII_file and open_namelist_file#206
Hallberg-NOAA merged 1 commit into
NOAA-GFDL:dev/gfdlfrom
marshallward:read_ascii

Conversation

@marshallward
Copy link
Copy Markdown
Member

This patch re-implements the FMS2 implementations of open_ASCII_file and open_namelist_file to remove their dependency on FMS1 functions which have been staged for deletion.

Note that if a file is opened with mpp_open but closed with close_file_unit, then it will raise an error in fms_io_exit. This will no longer be an issue after all references to mpp_open have been removed. But in the meantime, we will need to ensure that all unit-based close_file calls were not opened with mpp_open.

There is also a minor patch to .testing/Makefile which selects the framework ("infra") source dependency, rather than hard-set to FMS1.

@codecov
Copy link
Copy Markdown

codecov Bot commented Sep 16, 2022

Codecov Report

Merging #206 (49b2bb1) into dev/gfdl (d88c58a) will decrease coverage by 0.01%.
The diff coverage is n/a.

❗ Current head 49b2bb1 differs from pull request most recent head e8ec939. Consider uploading reports for the commit e8ec939 to get more accurate results

@@             Coverage Diff              @@
##           dev/gfdl     #206      +/-   ##
============================================
- Coverage     37.17%   37.15%   -0.02%     
============================================
  Files           261      262       +1     
  Lines         72357    72745     +388     
  Branches      13513    13597      +84     
============================================
+ Hits          26899    27032     +133     
- Misses        40477    40699     +222     
- Partials       4981     5014      +33     
Impacted Files Coverage Δ
src/parameterizations/vertical/MOM_opacity.F90 34.27% <0.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

This patch re-implements the FMS2 implementations of `open_ASCII_file`
and `open_namelist_file` to remove their dependency on FMS1 functions
which have been staged for deletion.

Note that if a file is opened with `mpp_open` but closed with
`close_file_unit`, then it will raise an error in `fms_io_exit`.
This will no longer be an issue after all references to `mpp_open` have
been removed.  But in the meantime, we will need to ensure that all
unit-based `close_file` calls were not opened with `mpp_open`.

There is also a minor patch to `.testing/Makefile` which selects the
framework ("infra") source dependency, rather than hard-set to FMS1.
Copy link
Copy Markdown
Member

@Hallberg-NOAA Hallberg-NOAA left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes seem like a sensible and useful step toward separating our FMS2 infrastructure code from any dependencies on the older FMS1 routines.

@Hallberg-NOAA
Copy link
Copy Markdown
Member

This PR has passed pipeline testing at https://gitlab.gfdl.noaa.gov/ogrp/MOM6/-/pipelines/16838.

@Hallberg-NOAA Hallberg-NOAA merged commit 6e91a74 into NOAA-GFDL:dev/gfdl Sep 22, 2022
chzhangudel pushed a commit to chzhangudel/MOM6 that referenced this pull request Sep 29, 2022
Merging main candidate from Dec 20, 2021
@marshallward marshallward deleted the read_ascii branch April 21, 2023 15:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants