Skip to content

[develop] Linting to the standard at pylint v2.16.#788

Merged
MichaelLueken merged 2 commits into
ufs-community:developfrom
christinaholtNOAA:fix_linter_version
May 15, 2023
Merged

[develop] Linting to the standard at pylint v2.16.#788
MichaelLueken merged 2 commits into
ufs-community:developfrom
christinaholtNOAA:fix_linter_version

Conversation

@christinaholtNOAA
Copy link
Copy Markdown
Collaborator

DESCRIPTION OF CHANGES:

Update the version of pylint in the GitHub Actions workflow to be consistent with the version installed on-prem. On Hera, that's v2.16. I am assuming that's consistent with the other platforms.

This required linting several files to get the test to pass with a 10/10 score.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

TESTS CONDUCTED:

Only pylint and unittests were run on Hera.

DEPENDENCIES:

n/a

DOCUMENTATION:

n/a

ISSUE:

Fixes issue #787.

CHECKLIST

  • My code follows the style guidelines in the Contributor's Guide
  • I have performed a self-review of my own code using the Code Reviewer's Guide
  • I have commented my code, particularly in hard-to-understand areas
  • My changes need updates to the documentation. I have made corresponding changes to the documentation
  • My changes do not require updates to the documentation (explain).
  • My changes generate no new warnings
  • New and existing tests pass with my changes
  • Any dependent changes have been merged and published

LABELS (optional):

A Code Manager needs to add the following labels to this PR:

  • Work In Progress
  • bug
  • enhancement
  • documentation
  • release
  • high priority
  • run_ci
  • run_we2e_fundamental_tests
  • run_we2e_comprehensive_tests
  • Needs Cheyenne test
  • Needs Jet test
  • Needs Hera test
  • Needs Orion test
  • help wanted

Copy link
Copy Markdown
Collaborator

@MichaelLueken MichaelLueken left a comment

Choose a reason for hiding this comment

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

@christinaholtNOAA Tested linting on Hera and Jet. Linting passed with rating of 10.00/10. The srw_unittest.sh script was also run on Jet and the tests successfully passed. Approving this PR now.

Copy link
Copy Markdown
Collaborator

@mkavulich mkavulich left a comment

Choose a reason for hiding this comment

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

Looks good to me, just had one question but not a hold-up to merge. Code now lints 10/10 on prem.

PARMdir = os.path.join(USHdir, "..", "parm")

# Create an temporary experiment directory
# pylint: disable=consider-using-with
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Was there a reason to not use "with" here for the temporary directory?

@MichaelLueken MichaelLueken merged commit f1b7f47 into ufs-community:develop May 15, 2023
@christinaholtNOAA christinaholtNOAA deleted the fix_linter_version branch July 2, 2024 16:48
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.

Pylint in GitHub Actions test isn't compatible with on-prem environments

3 participants