Skip to content

Add Travis CI and skeleton COMPASS docs #472

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

Merged
merged 1 commit into from
May 27, 2020

Conversation

xylar
Copy link
Collaborator

@xylar xylar commented Mar 13, 2020

This merge adds support for Travis CI to run on MPAS-Model pull requests. Travis currently runs two tests:

  • docs: builds a skeleton of documentation using a ReadTheDocs template, similar to what is used for MPAS-Analysis, MPAS-Tools, geometric_features and pyremap. The documentation is currently almost entirely focused on COMPASS, because that is where the most pressing need for improved documentation seems to be.
  • compass: creates conda environment with the latest version of the compass metapackage, then tests to make sure the 4 basic COMPASS scripts exist and their help screens can be seen (requiring that all their dependencies are present in the conda environment.)

Stubs are in place for adding future CI for ocean, atmosphere, lancice and seaice if anyone would care to do this.

@xylar
Copy link
Collaborator Author

xylar commented Mar 13, 2020

@mark-petersen, @matthewhoffman, @mgduda, @akturner and @pwolfram, I want to make sure you are all okay with these changes, as they will propagate to other branches as develop gets merged to them. Please let me know if you have concerns.

@xylar
Copy link
Collaborator Author

xylar commented Mar 13, 2020

@mark-petersen, @matthewhoffman, @mgduda, @akturner and @pwolfram, first, I would like permission to create a gh-pages branch:

Thegh-pages branch would be an essentially empty branch for the documentation to get merged to. This will appear at http://mpas-dev.github.io/MPAS-Model by default, thought we could put it somewhere else if that is not the desired location. It will create folders under that URL corresponding to each of the supported branches(stable for master; latest for develop; latest_ocean , latest_coastal and latest_landice for for ocean/develop, ocean/coastal and landice/develop, respectively) and for each future release tag (7.1, etc.), where the latest associated documentation will be available.

Comment on lines +14 to +27
#- name: "atmosphere"
#- name: "landice"
#- name: "ocean"
#- name: "seaice"
Copy link
Collaborator Author

@xylar xylar Mar 13, 2020

Choose a reason for hiding this comment

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

To add more CI in the future, uncomment one of these or add a new one, then add travis_ci/install_ocean.bash, travis_ci/test_ocean.bash, etc. to set up and run whatever tests are desired. It may be possible to set, compile and run MPAS itself in Travis if we don't make the tests too big.

Comment on lines +19 to +37
env:
global:
secure: "Ckovv5psUv9pdBVaNjsgrk0hXGJbNTi5dzLSWsNQA3Ub4hUXvzgBvX1TgS+CZvq3fkJnxV6SYZIlOkrCqqxdlUzFewDiuzzYxEZObFZ8FceWiYs4K3LMS30MPLzIYaV9ORqXJ0/P/ii62KhGIraX7ryzZ5+IG5uDOd7gumD6GiCPURFQIGpWS7MasKmEQRnokrGO3B2JjGEB0vMTdMZGbj8XY+X4Q0zcdQnjrLtG7PiuED95CrfEI7HfJ/ifPRgI4EMey6YI89DUF6hdQ1N1QxyAnxlKBDkqCvy6uowej7xPwMMZsyykr6EoAcwk9kYluVRogKe1iBMq1P4WCOOUj3c3Q9Dp885TiXlsW1aDKT2RSkx/SV5cE73vrpUhmm2Nf/wWAZktOYJSGlmRqSnjkQhDJqQSOaIQbwBfUtuGMt0Go0Q/3/qlMc7I9AjG5yBuYcY8WN98qKABP3IKjSsIFUPyo1kXCHt++oV7z1p9oBdGS54e+9rEYWixvAwvw0GvrNrbQdiq2sq8BheI4ppzeSGoneHguNDn5QyVeMu4WZ0gsCwuVW0lXiuUSlYHG5ZctX1cQySCyL3IOcpYa1a1/DKINpkwr/Z7T8oOM+UHnXDK96UJfbaG5n5+JZOfWJ6N/Em7weKuwnRiobGQfDqlyEtc1hgcLfvMnkpikENKhss="
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This lets Travis log in as me to upload the documentation to the gh-pages branch (once we create it). This capability means that we need to be careful not to merge malicious code (e.g. "bug fixes" from an unknown contributor) that could use this ability to mess up the repo. Just want to make that risk known so we're vigilant, though I think it is very unlikely.

@xylar xylar force-pushed the add_compass_docs branch from fae71af to 7a01e2c Compare March 13, 2020 11:37
ISOMIP+
=======

Blah
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Obviously, just a placeholder for now.

Baroclinic Channel
==================

Blah
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Another placeholder

Global Ocean
============

Blah
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

And another

@xylar xylar force-pushed the add_compass_docs branch 2 times, most recently from 3b16101 to beb7906 Compare March 13, 2020 11:51
@xylar
Copy link
Collaborator Author

xylar commented May 8, 2020

@mgduda, do you have an answer to my question above about where the "official" MPAS version number can be found and parsed?

@xylar
Copy link
Collaborator Author

xylar commented May 8, 2020

@mark-petersen, @matthewhoffman, @mgduda, @akturner and @pwolfram, first, I would like permission to create a gh-pages branch

Most of us were on the telecon discussing this on Monday and seemed okay with this plan as long as you aren't affected. Are you okay with me making an empty branch gh-pages where documentation will start appearing under http://mpas-dev.github.io/MPAS-Model? For example, http://mpas-dev.github.io/MPAS-Model/latest would be the first, and would point to the stub documentation generated once this PR is merged to develop.

For now, there would be no links to this documentation anywhere, since it's just a stub. But I would eventually add more prominent links once there is meaningful content.

Copy link
Contributor

@mark-petersen mark-petersen left a comment

Choose a reason for hiding this comment

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

@xylar, thanks for being proactive with these modern tools. Automated PR testing and readTheDocs documentation has big advantages, so having this framework in place is very helpful.

This is a new capability that each core may take part in as they choose, so there is no downside here.

@mark-petersen
Copy link
Contributor

@mgduda @matthewhoffman @akturner @pwolfram
If you could review this pull request this week, that would be helpful.

@xylar
Copy link
Collaborator Author

xylar commented May 19, 2020

@mark-petersen, this should not be merged until the gh-pages branch has been created. I put back the "in progress" tag.

@matthewhoffman
Copy link
Member

@xylar , is making the gh_pages tag something I can do? Also, did you resolve your question about an "official" MPAS version number? Would git describe serve that purpose?

@xylar
Copy link
Collaborator Author

xylar commented May 19, 2020

gh-pages would be a nearly empty branch, rather than a tag.

Yes, I resolved the version number question. Thanks!

@xylar
Copy link
Collaborator Author

xylar commented May 19, 2020

@matthewhoffman, here is the gist of what needs to happen (see https://gist.github.com/ramnathv/2227408):

cd /path/to/repo-name
git symbolic-ref HEAD refs/heads/gh-pages
rm .git/index
git clean -fdx
echo "My GitHub Page" > index.html
git add .
git commit -a -m "First pages commit"
git push origin gh-pages

In other words, I need to create an empty (orphaned) branch that Travis CI will then populate with various versions of the documentation.

I am happy to to this (and I believe I have the necessary permission) but I just want to make sure no one will be unhappy about it.

@xylar
Copy link
Collaborator Author

xylar commented May 27, 2020

Okay, I have created the gh-pages branch. On the recent MPAS-Developers telecons I got the sense that @mgduda and @akturner are okay with this as long as it doesn't affect the seaice/develop branch. So I'm going to remove you as reviewers.

@mark-petersen, @matthewhoffman, and @pwolfram, could you take a look again and make sure you don't have objections. I realize it will be easier to tell once these changes propagate to ocean/develop, landice/develop and ocean/coastal, so for now I'm mainly wanting to make sure there aren't any major red flags.

@xylar xylar removed request for mgduda and akturner May 27, 2020 12:26
Copy link
Contributor

@pwolfram pwolfram left a comment

Choose a reason for hiding this comment

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

@xylar, took a really quick look. I'd recommend we get this published and revisit as we go. Having something, which we don't have, is much better for this than nothing and I appreciate you kicking this off so we have something to build on that can be used to increase clarity.

@mark-petersen
Copy link
Contributor

@matthewhoffman any comments, or can we merge?

@xylar
Copy link
Collaborator Author

xylar commented May 27, 2020

Thanks for the reviews!

@mark-petersen mark-petersen merged commit 51828a1 into MPAS-Dev:develop May 27, 2020
@xylar xylar deleted the add_compass_docs branch May 27, 2020 19:39
@xylar
Copy link
Collaborator Author

xylar commented May 27, 2020

Thanks, @mark-petersen for merging this and everyone else for your reviews.

@xylar
Copy link
Collaborator Author

xylar commented May 31, 2020

@mark-petersen, it there a good time for merging develop to ocean/develop to bring in these changes? It's not a big rush but I do plan to work on documentation as I have time once this goes in.

@mark-petersen
Copy link
Contributor

I was hoping to get in 562 and 449 into develop, and then merge in develop. But hopefully in the next week.

jonbob added a commit to E3SM-Project/E3SM that referenced this pull request Jul 27, 2020
#3737)

Update MPAS framework

This PR brings in a new mpas-source submodule with updates to the mpas framework
itself, plus changes to the cores supporting the framework update. Some changes
are made to the atmosphere core, even though it is not used by E3SM, in order to
maintain consistency with the framework. This update includes the following
individual branches and PRs, many of which are additions to the makefiles for
summit, or optional libraries:
* az/azamat/mpas-cmake/mpas-tool-dir  (MPAS-Dev/MPAS-Model#629)
* init_atmosphere/kd_tree_ties  (MPAS-Dev/MPAS-Model#630)
* mark-petersen/framework/add_FillValue  (MPAS-Dev/MPAS-Model#616)
* mark-petersen/framework/add_lapack_option  (MPAS-Dev/MPAS-Model#613)
* amametjanov/framework/nullify-field-pointers  (MPAS-Dev/MPAS-Model#578)
* framework/makefile_e3sm  (MPAS-Dev/MPAS-Model#603)
* xylar/framework/make_shell_bash  (MPAS-Dev/MPAS-Model#594)
* registry/missing_value  (MPAS-Dev/MPAS-Model#562)
* pwolfram/updates_make_intel_stack  (MPAS-Dev/MPAS-Model#592)
* azamat/framework/pgi-cpr-omp-workaround  (MPAS-Dev/MPAS-Model#449)
* az/framework/e3sm-cmake-qnosmp-typo  (MPAS-Dev/MPAS-Model#579)
* xylar/compass/add_prerequisite_tag
* atmosphere/fix_timekeeping_imports (MPAS-Dev/MPAS-Model#582)
* xylar/fix_docs_ci  (MPAS-Dev/MPAS-Model#575)
* xylar/add_compass_docs  (MPAS-Dev/MPAS-Model#472)
* philipwjones/framework/summitmake  (MPAS-Dev/MPAS-Model#536)
* atmosphere/atm_core_cleanup  (MPAS-Dev/MPAS-Model#548)
* init_atmosphere/parse_geoindex  (MPAS-Dev/MPAS-Model#459)
* xylar/compass/add_copy_file  (MPAS-Dev/MPAS-Model#467)
* init_atmosphere/kd_tree  (MPAS-Dev/MPAS-Model#438)
* init_atmosphere/mpas_stack  (MPAS-Dev/MPAS-Model#426)
* operators/add_mpas_in_cell  (MPAS-Dev/MPAS-Model#400)

Fixes #3396
Fixes #3236

[BFB]
jonbob added a commit to E3SM-Project/E3SM that referenced this pull request Jul 29, 2020
Update MPAS framework

This PR brings in a new mpas-source submodule with updates to the mpas framework
itself, plus changes to the cores supporting the framework update. Some changes
are made to the atmosphere core, even though it is not used by E3SM, in order to
maintain consistency with the framework. This update includes the following
individual branches and PRs, many of which are additions to the makefiles for
summit, or optional libraries:
* az/azamat/mpas-cmake/mpas-tool-dir  (MPAS-Dev/MPAS-Model#629)
* init_atmosphere/kd_tree_ties  (MPAS-Dev/MPAS-Model#630)
* mark-petersen/framework/add_FillValue  (MPAS-Dev/MPAS-Model#616)
* mark-petersen/framework/add_lapack_option  (MPAS-Dev/MPAS-Model#613)
* amametjanov/framework/nullify-field-pointers  (MPAS-Dev/MPAS-Model#578)
* framework/makefile_e3sm  (MPAS-Dev/MPAS-Model#603)
* xylar/framework/make_shell_bash  (MPAS-Dev/MPAS-Model#594)
* registry/missing_value  (MPAS-Dev/MPAS-Model#562)
* pwolfram/updates_make_intel_stack  (MPAS-Dev/MPAS-Model#592)
* azamat/framework/pgi-cpr-omp-workaround  (MPAS-Dev/MPAS-Model#449)
* az/framework/e3sm-cmake-qnosmp-typo  (MPAS-Dev/MPAS-Model#579)
* xylar/compass/add_prerequisite_tag
* atmosphere/fix_timekeeping_imports (MPAS-Dev/MPAS-Model#582)
* xylar/fix_docs_ci  (MPAS-Dev/MPAS-Model#575)
* xylar/add_compass_docs  (MPAS-Dev/MPAS-Model#472)
* philipwjones/framework/summitmake  (MPAS-Dev/MPAS-Model#536)
* atmosphere/atm_core_cleanup  (MPAS-Dev/MPAS-Model#548)
* init_atmosphere/parse_geoindex  (MPAS-Dev/MPAS-Model#459)
* xylar/compass/add_copy_file  (MPAS-Dev/MPAS-Model#467)
* init_atmosphere/kd_tree  (MPAS-Dev/MPAS-Model#438)
* init_atmosphere/mpas_stack  (MPAS-Dev/MPAS-Model#426)
* operators/add_mpas_in_cell  (MPAS-Dev/MPAS-Model#400)

Fixes #3396
Fixes #3236

[BFB]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants