forked from ufs-community/ufs-weather-model
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from ufs-community/develop
update my fork
- Loading branch information
Showing
685 changed files
with
61,988 additions
and
302,902 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Dockerfile | ||
.git | ||
.gitignore | ||
tests/*.log | ||
tests/log_ut_linux.gnu |
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# This is a comment. | ||
# Each line is a file pattern followed by one or more owners. | ||
# Order is important; the last matching pattern takes the most | ||
# precedence. | ||
|
||
# Everything in ufs-weather-model should be also be owned by the UFS Weather Model Gatekeepers | ||
* @ufs-community/ufs-wm-gatekeepers | ||
|
||
# The components are owned by their respective teams | ||
/FV3/ @noaa-emc/fv3atm-team | ||
/NEMS/ @noaa-emc/nems-team | ||
#/FMS/ @noaa-emc/fms-team | ||
#/FMS/ @noaa-gfdl/fms-team |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us improve | ||
title: '' | ||
labels: bug | ||
assignees: '' | ||
|
||
--- | ||
|
||
## Description | ||
Provide a clear and concise description of what the bug is. | ||
Also give a description of what behavior you expected to happen. | ||
|
||
|
||
### To Reproduce: | ||
What compilers/machines are you seeing this with? | ||
Give explicit steps to reproduce the behavior. | ||
1. do this | ||
2. then that | ||
3. then, oops, look at the bug | ||
|
||
|
||
## Additional context | ||
Add any other context about the problem here. | ||
Directly reference any issues or PRs in this or other repositories that this is related to, and describe how they are related. Example: | ||
- needs to be fixed also in noaa-emc/nems/issues/<issue_number> | ||
- needed for noaa-emc/fv3atm/pull/<pr_number> | ||
|
||
|
||
## Output | ||
|
||
**Screenshots** | ||
If applicable, drag and drop screenshots to help explain your problem. | ||
|
||
**output logs** | ||
If applicable, include relevant output logs. | ||
Either drag and drop the entire log file here (if a long log) or | ||
|
||
``` | ||
paste the code here (if a short section of log) | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea for this project | ||
title: '' | ||
labels: enhancement | ||
assignees: '' | ||
|
||
--- | ||
|
||
## Description | ||
Provide a clear and concise description of what the problem is. Ex. I'm always frustrated when [...] | ||
|
||
## Solution | ||
Add a clear and concise description of what you want to happen. | ||
|
||
## Alternatives | ||
If applicable, add a description of any alternative solutions or features you've considered. | ||
|
||
## Related to | ||
Directly reference any issues or PRs in this or other repositories that this is related to, and describe how they are related. Example: | ||
- required to support noaa-emc/nems/issues/<issue_number> | ||
- needed by noaa-emc/fv3atm/pull/<pr_number> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
## Description | ||
|
||
(Instructions: this, and all subsequent sections of text should be removed and filled in as appropriate.) | ||
Provide a detailed description of what this PR does. | ||
What bug does it fix, or what feature does it add? | ||
Is a change of answers expected from this PR? | ||
Are any library updates included in this PR (modulefiles etc.)? | ||
|
||
### Issue(s) addressed | ||
|
||
Link the issues to be closed with this PR, whether in this repository, or in another repository. | ||
(Remember, issues should always be created before starting work on a PR branch!) | ||
- fixes #<issue_number> | ||
- fixes noaa-emc/fv3atm/issues/<issue_number> | ||
|
||
## Testing | ||
|
||
How were these changes tested? | ||
What compilers / HPCs was it tested with? | ||
Are the changes covered by regression tests? (If not, why? Do new tests need to be added?) | ||
Have regression tests and unit tests (utests) been run? On which platforms and with which compilers? (Note that unit tests can only be run on tier-1 platforms) | ||
|
||
## Dependencies | ||
|
||
If testing this branch requires non-default branches in other repositories, list them. | ||
Those branches should have matching names (ideally) | ||
|
||
Do PRs in upstream repositories need to be merged first? | ||
If so add the "waiting for other repos" label and list the upstream PRs | ||
- waiting on noaa-emc/nems/pull/<pr_number> | ||
- waiting on noaa-emc/fv3atm/pull/<pr_number> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,121 @@ | ||
name: Pull Request Tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- develop | ||
pull_request: | ||
branches: | ||
- develop | ||
|
||
jobs: | ||
setup: | ||
name: Set up | ||
runs-on: ubuntu-latest | ||
|
||
outputs: | ||
tn: ${{ steps.parse.outputs.tn }} | ||
bld: ${{ steps.parse.outputs.bld }} | ||
test: ${{ steps.parse.outputs.test }} | ||
img: ${{ steps.parse.outputs.img }} | ||
|
||
steps: | ||
- name: Checkout codes | ||
uses: actions/checkout@v2 | ||
|
||
- name: Parse cases | ||
id: parse | ||
run: | | ||
cd ${GITHUB_WORKSPACE}/tests/ci | ||
parsed_output=( $(./parse.sh) ) | ||
name_=${parsed_output[0]} | ||
bld_=${parsed_output[1]} | ||
test_=${parsed_output[2]} | ||
img_=${parsed_output[3]} | ||
echo "::set-output name=tn::$name_" | ||
echo "::set-output name=bld::$bld_" | ||
echo "::set-output name=test::$test_" | ||
echo "::set-output name=img::$img_" | ||
echo "test name : $name_" | ||
echo "build set : $bld_" | ||
echo "test set : $test_" | ||
echo "image name: $img_" | ||
build: | ||
name: Build (${{ matrix.bld_set }}) | ||
needs: setup | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: ${{ fromJson(needs.setup.outputs.bld) }} | ||
|
||
steps: | ||
- name: Checkout codes | ||
uses: actions/checkout@v2 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Build | ||
run: | | ||
printf '{\n "experimental": true\n}' | sudo tee /etc/docker/daemon.json >/dev/null | ||
sudo systemctl restart docker | ||
sleep 10 | ||
cd tests/ci && ./ci.sh -n ${{ needs.setup.outputs.tn }} -b ${{ matrix.bld_set }} | ||
- name: Free up disk space | ||
run: | | ||
sudo docker rmi $(sudo docker image ls | grep -E -m1 '<none>' | awk '{ print $3 }') | ||
sudo docker rmi $(sudo docker image ls | awk '/ubuntu-hpc/ { print $3 }') | ||
- name: Prepare artifacts | ||
run: | | ||
cd tests/ci | ||
sudo docker save ${{ needs.setup.outputs.img }} | gzip >${{ needs.setup.outputs.img }}.tar.gz | ||
tar cvjf artifact.tar.bz2 ${{ needs.setup.outputs.img }}.tar.gz ci.sh ci.test | ||
- name: Upload artifacts | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: ${{ matrix.bld_set }}.artifact.tar.bz2 | ||
path: tests/ci/artifact.tar.bz2 | ||
|
||
utest: | ||
name: Unit test (${{ needs.setup.outputs.tn }}, ${{ matrix.test_set }}) | ||
needs: [setup,build] | ||
runs-on: ubuntu-latest | ||
#runs-on: self-hosted | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: ${{ fromJson(needs.setup.outputs.test) }} | ||
|
||
steps: | ||
- name: Download artifacts | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: ${{ matrix.artifact }}.artifact.tar.bz2 | ||
|
||
- name: Prepare artifacts | ||
run: | | ||
tar xvjf artifact.tar.bz2 && rm -f artifact.tar.bz2 | ||
sudo docker load --input ${{ needs.setup.outputs.img }}.tar.gz && rm -f ${{ needs.setup.outputs.img }}.tar.gz | ||
- name: Run utest | ||
run: ./ci.sh -n ${{ needs.setup.outputs.tn }} -r ${{ matrix.test_set }} | ||
|
||
- name: Upload memory usage file | ||
if: ${{ always() }} | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: memory_stat_${{ matrix.test_set }} | ||
path: memory_stat | ||
|
||
- name: Clean up | ||
if: ${{ always() }} | ||
run: | | ||
rm -f ci.sh ci.test | ||
sudo docker rm my-container && sudo docker rmi ${{ needs.setup.outputs.img }}:latest | ||
sudo docker volume rm DataVolume |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
name: Manage workflows | ||
|
||
on: | ||
workflow_run: | ||
workflows: ["Pull Request Tests"] | ||
types: | ||
- requested | ||
|
||
jobs: | ||
job1: | ||
name: Job 1 | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout codes | ||
uses: actions/checkout@v2 | ||
|
||
- name: Check if skip-ci is requested | ||
run: | | ||
cd ${GITHUB_WORKSPACE}/tests/ci | ||
repo="${GITHUB_API_URL}/repos/${GITHUB_REPOSITORY}/actions/runs" | ||
tr_id=$(cat ${GITHUB_EVENT_PATH} | ./json_helper.py get_trigger_id) | ||
tr_br=$(cat ${GITHUB_EVENT_PATH} | ./json_helper.py get_trigger_br) | ||
check=$(cat ${GITHUB_EVENT_PATH} | ./json_helper.py check_skip) | ||
echo "TRIGGER_ID=${tr_id}" >> $GITHUB_ENV | ||
echo "TRIGGER_BR=${tr_br}" >> $GITHUB_ENV | ||
echo "skip-ci: ${check}" | ||
if [[ $check == yes ]]; then | ||
echo "skip-ci is requested" | ||
echo "CURR_JOB=cancelled" >> $GITHUB_ENV | ||
curl -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" -H "Accept: application/vnd.github.v3+json" ${repo}/$tr_id/cancel | ||
else | ||
echo "CURR_JOB=running" >> $GITHUB_ENV | ||
fi | ||
- name: Cancel redundant jobs | ||
run: | | ||
echo "CURR_JOB is $CURR_JOB" | ||
echo "TRIGGER_ID is $TRIGGER_ID" | ||
echo "TRIGGER_BR is $TRIGGER_BR" | ||
export GITHUB_ACTOR | ||
export GITHUB_RUN_ID | ||
export TRIGGER_ID | ||
export TRIGGER_BR | ||
cd ${GITHUB_WORKSPACE}/tests/ci | ||
repo="${GITHUB_API_URL}/repos/${GITHUB_REPOSITORY}/actions/runs" | ||
cancel_ids=$(curl -H "Accept: application/vnd.github.v3+json" ${repo} | ./json_helper.py cancel_workflow) | ||
echo "cancel ids: $cancel_ids" | ||
if [[ $cancel_ids != '' ]]; then | ||
for i in $cancel_ids; do | ||
curl -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" -H "Accept: application/vnd.github.v3+json" ${repo}/$i/cancel | ||
done | ||
fi | ||
if: ${{ env.CURR_JOB == 'running' }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
# Prerequisites | ||
*.d | ||
|
||
# Compiled Object files | ||
*.slo | ||
*.lo | ||
*.o | ||
*.obj | ||
|
||
# Precompiled Headers | ||
*.gch | ||
*.pch | ||
|
||
# Compiled Dynamic libraries | ||
*.so | ||
*.dylib | ||
*.dll | ||
|
||
# Fortran module files | ||
*.mod | ||
*.smod | ||
|
||
# Compiled Static libraries | ||
*.lai | ||
*.la | ||
*.a | ||
*.lib | ||
|
||
# Executables | ||
*.exe | ||
*.out | ||
*.app | ||
*.x | ||
|
||
# system files | ||
*.swp | ||
*~ | ||
.DS_Store | ||
|
||
# python files | ||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
|
||
# CMake files and directories | ||
build*/ | ||
install*/ | ||
CMakeLists.txt.user | ||
CMakeCache.txt | ||
CMakeFiles | ||
CMakeScripts | ||
cmake_install.cmake | ||
install_manifest.txt | ||
compile_commands.json | ||
CTestTestfile.cmake | ||
_deps | ||
|
||
# repo-specific ignorables | ||
coupled*.mk | ||
rt.conf.single | ||
ufs_model | ||
tests/modules.fv3_* | ||
tests/ecflow_run/ | ||
tests/log_*/ | ||
tests/lock/ | ||
tests/Compile_*.log | ||
tests/fail_test | ||
log* | ||
build*.log* |
Oops, something went wrong.