Skip to content

Commit

Permalink
Merge branch 'develop' of https://github.com/dtcenter/METcalcpy into …
Browse files Browse the repository at this point in the history
…develop
  • Loading branch information
bikegeek committed Jul 10, 2024
2 parents 8f77496 + e695758 commit 1c931da
Show file tree
Hide file tree
Showing 86 changed files with 3,737 additions and 210 deletions.
5 changes: 5 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[run]
relative_files = True
omit =
config.py
config-3.py
17 changes: 9 additions & 8 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,15 @@ Describe the steps to reproduce the behavior:
- [ ] Select **scientist(s)** or **no scientist** required

### Labels ###
- [ ] Review default **alert** labels
- [ ] Select **component(s)**
- [ ] Select **priority**
- [ ] Select **requestor(s)**

### Projects and Milestone ###
- [ ] Select **Organization** level **Project** for support of the current coordinated release
- [ ] Select **Repository** level **Project** for development toward the next official release or add **alert: NEED CYCLE ASSIGNMENT** label
### Milestone and Projects ###
- [ ] Select **Milestone** as the next bugfix version
- [ ] Select **Coordinated METplus-X.Y Support** project for support of the current coordinated release
- [ ] Select **METcalcpy-X.Y.Z Development** project for development toward the next official release

## Define Related Issue(s) ##
Consider the impact to the other METplus components.
Expand All @@ -65,20 +66,20 @@ Branch name: `bugfix_<Issue Number>_main_<Version>_<Description>`
- [ ] Add/update log messages for easier debugging.
- [ ] Add/update unit tests.
- [ ] Add/update documentation.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/overview.html#metplus-components-python-requirements) table.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/appendixA.html#metplus-components-python-packages) table.
- [ ] Push local changes to GitHub.
- [ ] Submit a pull request to merge into **main_\<Version>**.
Pull request: `bugfix <Issue Number> main_<Version> <Description>`
- [ ] Define the pull request metadata, as permissions allow.
Select: **Reviewer(s)** and **Development** issues
Select: **Organization** level software support **Project** for the current coordinated release
Select: **Reviewer(s)** and **Development** issue
Select: **Milestone** as the next bugfix version
Select: Coordinated METplus-X.Y Support project for support of the current coordinated release
- [ ] Iterate until the reviewer(s) accept and merge your changes.
- [ ] Delete your fork or branch.
- [ ] Complete the steps above to fix the bug on the **develop** branch.
Branch name: `bugfix_<Issue Number>_develop_<Description>`
Pull request: `bugfix <Issue Number> develop <Description>`
Select: **Reviewer(s)** and **Development** issues
Select: **Repository** level development cycle **Project** for the next official release
Select: **Reviewer(s)** and **Development** issue
Select: **Milestone** as the next official version
Select: **METcalcpy-X.Y.Z Development** project for development toward the next official release
- [ ] Close this issue.
13 changes: 7 additions & 6 deletions .github/ISSUE_TEMPLATE/enhancement_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,14 @@ Consider breaking the enhancement down into sub-issues.
- [ ] Select **scientist(s)** or **no scientist** required

### Labels ###
- [ ] Review default **alert** labels
- [ ] Select **component(s)**
- [ ] Select **priority**
- [ ] Select **requestor(s)**

### Projects and Milestone ###
- [ ] Select **Repository** and/or **Organization** level **Project(s)** or add **alert: NEED CYCLE ASSIGNMENT** label
- [ ] Select **Milestone** as the next official version or **Future Versions**
### Milestone and Projects ###
- [ ] Select **Milestone** as a **METcalcpy-X.Y.Z** version, **Consider for Next Release**, or **Backlog of Development Ideas**
- [ ] For a **METcalcpy-X.Y.Z** version, select the **METcalcpy-X.Y.Z Development** project

## Define Related Issue(s) ##
Consider the impact to the other METplus components.
Expand All @@ -54,14 +55,14 @@ Branch name: `feature_<Issue Number>_<Description>`
- [ ] Add/update log messages for easier debugging.
- [ ] Add/update unit tests.
- [ ] Add/update documentation.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/overview.html#metplus-components-python-requirements) table.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/appendixA.html#metplus-components-python-packages) table.
- [ ] Push local changes to GitHub.
- [ ] Submit a pull request to merge into **develop**.
Pull request: `feature <Issue Number> <Description>`
- [ ] Define the pull request metadata, as permissions allow.
Select: **Reviewer(s)** and **Development** issues
Select: **Repository** level development cycle **Project** for the next official release
Select: **Reviewer(s)** and **Development** issue
Select: **Milestone** as the next official version
Select: **METcalcpy-X.Y.Z Development** project for development toward the next official release
- [ ] Iterate until the reviewer(s) accept and merge your changes.
- [ ] Delete your fork or branch.
- [ ] Close this issue.
13 changes: 7 additions & 6 deletions .github/ISSUE_TEMPLATE/new_feature_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,14 @@ Consider breaking the new feature down into sub-issues.
- [ ] Select **scientist(s)** or **no scientist** required

### Labels ###
- [ ] Review default **alert** labels
- [ ] Select **component(s)**
- [ ] Select **priority**
- [ ] Select **requestor(s)**

### Projects and Milestone ###
- [ ] Select **Repository** and/or **Organization** level **Project(s)** or add **alert: NEED CYCLE ASSIGNMENT** label
- [ ] Select **Milestone** as the next official version or **Future Versions**
### Milestone and Projects ###
- [ ] Select **Milestone** as a **METcalcpy-X.Y.Z** version, **Consider for Next Release**, or **Backlog of Development Ideas**
- [ ] For a **METcalcpy-X.Y.Z** version, select the **METcalcpy-X.Y.Z Development** project

## Define Related Issue(s) ##
Consider the impact to the other METplus components.
Expand All @@ -58,14 +59,14 @@ Branch name: `feature_<Issue Number>_<Description>`
- [ ] Add/update log messages for easier debugging.
- [ ] Add/update unit tests.
- [ ] Add/update documentation.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/overview.html#metplus-components-python-requirements) table.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/appendixA.html#metplus-components-python-packages) table.
- [ ] Push local changes to GitHub.
- [ ] Submit a pull request to merge into **develop**.
Pull request: `feature <Issue Number> <Description>`
- [ ] Define the pull request metadata, as permissions allow.
Select: **Reviewer(s)** and **Development** issues
Select: **Repository** level development cycle **Project** for the next official release
Select: **Reviewer(s)** and **Development** issue
Select: **Milestone** as the next official version
Select: **METcalcpy-X.Y.Z Development** project for development toward the next official release
- [ ] Iterate until the reviewer(s) accept and merge your changes.
- [ ] Delete your fork or branch.
- [ ] Close this issue.
9 changes: 6 additions & 3 deletions .github/ISSUE_TEMPLATE/sub-issue.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,13 @@ This is a sub-issue of #*List the parent issue number here*.
- [ ] Select **scientist(s)** or **no scientist** required

### Labels ###
- [ ] Review default **alert** labels
- [ ] Select **component(s)**
- [ ] Select **priority**
- [ ] Select **requestor(s)**

### Projects and Milestone ###
- [ ] Select **Repository** and/or **Organization** level **Project(s)** or add **alert: NEED CYCLE ASSIGNMENT** label
- [ ] Select **Milestone** as the next official version or **Future Versions**
### Milestone and Projects ###
- [ ] Select **Milestone** as a **METcalcpy-X.Y.Z** version, **Consider for Next Release**, or **Backlog of Development Ideas**
- [ ] For a **METcalcpy-X.Y.Z** version, select the **METcalcpy-X.Y.Z Development** project


13 changes: 7 additions & 6 deletions .github/ISSUE_TEMPLATE/task.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,14 @@ Consider breaking the task down into sub-issues.
- [ ] Select **scientist(s)** or **no scientist** required

### Labels ###
- [ ] Review default **alert** labels
- [ ] Select **component(s)**
- [ ] Select **priority**
- [ ] Select **requestor(s)**

### Projects and Milestone ###
- [ ] Select **Repository** and/or **Organization** level **Project(s)** or add **alert: NEED CYCLE ASSIGNMENT** label
- [ ] Select **Milestone** as the next official version or **Future Versions**
### Milestone and Projects ###
- [ ] Select **Milestone** as a **METcalcpy-X.Y.Z** version, **Consider for Next Release**, or **Backlog of Development Ideas**
- [ ] For a **METcalcpy-X.Y.Z** version, select the **METcalcpy-X.Y.Z Development** project

## Define Related Issue(s) ##
Consider the impact to the other METplus components.
Expand All @@ -54,14 +55,14 @@ Branch name: `feature_<Issue Number>_<Description>`
- [ ] Add/update log messages for easier debugging.
- [ ] Add/update unit tests.
- [ ] Add/update documentation.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/overview.html#metplus-components-python-requirements) table.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/appendixA.html#metplus-components-python-packages) table.
- [ ] Push local changes to GitHub.
- [ ] Submit a pull request to merge into **develop**.
Pull request: `feature <Issue Number> <Description>`
- [ ] Define the pull request metadata, as permissions allow.
Select: **Reviewer(s)** and **Development** issues
Select: **Repository** level development cycle **Project** for the next official release
Select: **Reviewer(s)** and **Development** issue
Select: **Milestone** as the next official version
Select: **METcalcpy-X.Y.Z Development** project for development toward the next official release
- [ ] Iterate until the reviewer(s) accept and merge your changes.
- [ ] Delete your fork or branch.
- [ ] Close this issue.
4 changes: 1 addition & 3 deletions .github/jobs/configure_sonarqube.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,7 @@ fi

# Configure the sonar-project.properties
[ -e $SONAR_PROPERTIES ] && rm $SONAR_PROPERTIES
sed -e "s|SONAR_PROJECT_KEY|METcalcpy-GHA|" \
-e "s|SONAR_PROJECT_NAME|METcalcpy GHA|" \
-e "s|SONAR_PROJECT_VERSION|$SONAR_PROJECT_VERSION|" \
sed -e "s|SONAR_PROJECT_VERSION|$SONAR_PROJECT_VERSION|" \
-e "s|SONAR_HOST_URL|$SONAR_HOST_URL|" \
-e "s|SONAR_TOKEN|$SONAR_TOKEN|" \
-e "s|SONAR_BRANCH_NAME|$SOURCE_BRANCH|" \
Expand Down
6 changes: 3 additions & 3 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@ If **yes**, please describe:

## Pull Request Checklist ##
See the [METplus Workflow](https://metplus.readthedocs.io/en/latest/Contributors_Guide/github_workflow.html) for details.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/overview.html#metplus-components-python-requirements) table.
- [ ] Add any new Python packages to the [METplus Components Python Requirements](https://metplus.readthedocs.io/en/develop/Users_Guide/appendixA.html#metplus-components-python-packages) table.
- [ ] Review the source issue metadata (required labels, projects, and milestone).
- [ ] Complete the PR definition above.
- [ ] Ensure the PR title matches the feature or bugfix branch name.
- [ ] Define the PR metadata, as permissions allow.
Select: **Reviewer(s)**
Select: **Organization** level software support **Project** or **Repository** level development cycle **Project**
Select: **Reviewer(s)** and **Development** issue
Select: **Milestone** as the version that will include these changes
Select: **Coordinated METplus-X.Y Support** project for bugfix releases or **METcalcpy-X.Y.Z Development** project for official releases
- [ ] After submitting the PR, select the :gear: icon in the **Development** section of the right hand sidebar. Search for the issue that this PR will close and select it, if it is not already selected.
- [ ] After the PR is approved, merge your changes. If permissions do not allow this, request that the reviewer do the merge.
- [ ] Close the linked issue and delete your feature or bugfix branch from GitHub.
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.8'
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade python-dateutil requests sphinx \
sphinx-gallery Pillow sphinx_rtd_theme
sphinx-gallery Pillow sphinx_rtd_theme pandas xarray
python -m pip install -r docs/requirements.txt
- name: Build docs
run: ./.github/jobs/build_documentation.sh
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,25 @@ jobs:
# Disable shallow clones for better analysis
fetch-depth: 0

- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
# try installing scikit-image explicitly. Using requirements.txt versions doesn't seem to build correctly
python -m pip install -U scikit-image
# install the coverage.py code coverage tool
python3 -m pip install pytest-cov
- name: Test with pytest
# these are tests that don't have external dependencies (i.e. need to run on Linux test hosts where large datasets reside or require exact machine type for
# image comparisons to work, etc.)
run: |
coverage run -m pytest
coverage report -m
coverage xml
- name: Get branch name
id: get_branch_name
run: echo branch_name=${GITHUB_REF#refs/heads/} >> $GITHUB_OUTPUT
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -41,37 +41,21 @@ jobs:
- name: Install dependencies
run: |
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
# try installing scikit-image explicitly. Using requirements.txt versions doesn't seem to build correctly
# try installing scikit-image explicitly. Using requirements.txt versions doesn't seem to build correctly
python -m pip install -U scikit-image
# install the coverage.py code coverage tool
python3 -m pip install coverage
python3 -m pip install pytest-cov
- name: Test with pytest
# these are tests that don't have external dependencies (i.e. need to run on Linux test hosts where large datasets reside or require exact machine type for
# image comparisons to work, etc.)
run: |
cd test
pytest test_agg_eclv.py
pytest test_agg_stats_and_boot.py
pytest test_agg_stats_with_groups.py
pytest test_calc_difficulty_index.py
pytest test_convert_lon_indices.py
pytest test_ctc_statistics.py
pytest test_event_equalize.py
pytest test_event_equalize_against_values.py
pytest test_lon_360_to_180.py
pytest test_statistics.py
pytest test_tost_paired.py
pytest test_utils.py
pytest test_validate_mv_python.py
pytest test_future_warnings.py
pytest test_sl1l2.py
pytest test_reformatted_for_agg.py
coverage run -m pytest test_agg_eclv.py test_agg_stats_and_boot.py test_agg_stats_with_groups.py test_calc_difficulty_index.py test_convert_lon_indices.py test_event_equalize.py test_event_equalize_against_values.py test_lon_360_to_180.py test_statistics.py test_tost_paired.py test_utils.py test_future_warnings.py test_reformatted_for_agg.py
coverage run -m pytest
coverage report -m
coverage html
- name: Archive code coverage results
uses: actions/upload-artifact@v4
with:
name: code-coverage-report
path: test/htmlcov/index.html
path: htmlcov/index.html

8 changes: 7 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,15 @@
# temp files surrounded by #
*#*#

__pycache__/

# sphinx output
docs/_build

docs/diag_ref/generated
docs/sg_execution_times.rst
docs/auto_examples

/metcalcpy.egg-info/

.coverage
coverage.xml
9 changes: 9 additions & 0 deletions .idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 15 additions & 0 deletions .idea/METcalcpy.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 19 additions & 0 deletions .idea/inspectionProfiles/Project_Default.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/inspectionProfiles/profiles_settings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,4 @@ python:
sphinx:
builder: html
configuration: docs/conf.py
fail_on_warning: true
Loading

0 comments on commit 1c931da

Please sign in to comment.