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

Set fms_diag_accept_data #1610

Merged
merged 4 commits into from
Nov 14, 2024
Merged

Set fms_diag_accept_data #1610

merged 4 commits into from
Nov 14, 2024

Conversation

uramirez8707
Copy link
Contributor

@uramirez8707 uramirez8707 commented Oct 30, 2024

Description

  1. Ensure that fms_diag_accept_data is always set by removing return statements and setting it in the end. This is to prevent errors in debug mode in cases where fms_diag_accept_data is not set. fms_diag_accept_data is always set to .true., if there any errors in the subroutine it will crash with a FATAL.
  2. Fixes the calls to send_data for a static variable in the unit tests.

Fixes #1591

How Has This Been Tested?
CI

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules
  • New check tests, if applicable, are included
  • make distcheck passes

@uramirez8707 uramirez8707 changed the title Debug diag Set fms_diag_accept_data Oct 30, 2024
Copy link
Contributor

@rem1776 rem1776 left a comment

Choose a reason for hiding this comment

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

If this will always return true, should we just make this a subroutine instead? I think there's only like two calls to it.

Copy link
Contributor

@rem1776 rem1776 left a comment

Choose a reason for hiding this comment

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

thanks for making that change, looks good.

@rem1776 rem1776 merged commit 23df6d7 into NOAA-GFDL:main Nov 14, 2024
26 of 28 checks passed
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.

Modern Diag Manager crashes in debug mode because FMS_DIAG_ACCEPT_DATA is never set
2 participants