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

Enable checking for python norms and fix violating code #1168

Merged
24 changes: 24 additions & 0 deletions .github/workflows/pynorms.yaml
@@ -0,0 +1,24 @@
name: Check Norms
on: [push, pull_request]
WalterKolczynski-NOAA marked this conversation as resolved.
Show resolved Hide resolved

jobs:
check_norms:
runs-on: ubuntu-latest
name: Check Python coding norms with pycodestyle

steps:

- name: Install dependencies
run: |
pip install --upgrade pip
pip install pycodestyle

- name: Checkout
uses: actions/checkout@v3
with:
path: global-workflow

- name: Run pycodestyle
run: |
cd $GITHUB_WORKSPACE/global-workflow
pycodestyle -v --config ./.pycodestyle .
6 changes: 6 additions & 0 deletions .pycodestyle
@@ -0,0 +1,6 @@
[pycodestyle]
count = False
ignore = E226,E401,E402,W504
WalterKolczynski-NOAA marked this conversation as resolved.
Show resolved Hide resolved
max-line-length = 160
statistics = True
exclude = Experimental