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

Transition CI from Azure Pipelines to GitHub Actions #586

Merged
merged 8 commits into from
Nov 6, 2024

Conversation

altheaden
Copy link
Collaborator

In this PR, I've switched the CI workflows from azure pipelines to GH actions. There's a build workflow for testing code, and a docs workflow for deploying the documentation via the gh-pages branch. This change allows the CI for MPAS-Tools to be more in line with our CI procedures in other repos (e.g., Polaris, Mache, Compass).

@altheaden
Copy link
Collaborator Author

altheaden commented Nov 5, 2024

@xylar As we discussed earlier, there is an issue with building the docs during the docs workflow. If you don't get a chance to debug it by tomorrow, I'm happy to try to figure it out then as well. Here is the error:

 [autosummary] generating autosummary for: api.rst, authors.rst, building_docs.rst, index.rst, making_changes.rst, mesh_conversion.rst, mesh_creation.rst, testing_changes.rst, versions.rst
WARNING: [autosummary] failed to import mpas_tools.mesh.creation.build_mesh.build_mesh.
Possible hints:
* AttributeError: module 'mpas_tools.mesh.creation.build_mesh' has no attribute 'build_mesh'
* ModuleNotFoundError: No module named 'mpas_tools.mesh.creation.build_mesh.build_mesh'; 'mpas_tools.mesh.creation.build_mesh' is not a package
* ImportError: 
Extension error (sphinx.ext.autosummary):
Handler <function process_generate_options at 0x7f5ac53858a0> for event 'builder-inited' threw an exception (exception: no module named mpas_tools.mesh.creation.coastal_tools)
Traceback (most recent call last):
  File "/home/runner/miniconda3/envs/mpas_tools_dev/bin/sphinx-multiversion", line 10, in <module>
    sys.exit(main())
             ^^^^^^
  File "/home/runner/miniconda3/envs/mpas_tools_dev/lib/python3.12/site-packages/sphinx_multiversion/main.py", line 338, in main
    subprocess.check_call(cmd, cwd=current_cwd)
  File "/home/runner/miniconda3/envs/mpas_tools_dev/lib/python3.12/subprocess.py", line 413, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '('/home/runner/miniconda3/envs/mpas_tools_dev/bin/python3.12', '-R', '-m', 'sphinx', '-D', 'smv_metadata_path=/tmp/tmp2zol9kgu/versions.json', '-D', 'smv_current_version=0.0.11', '-c', '/home/runner/work/MPAS-Tools/MPAS-Tools/conda_package/docs', '/tmp/tmp2zol9kgu/a2231588d6471f816361c29d23933fe9983b9d32/conda_package/docs', '/home/runner/work/MPAS-Tools/MPAS-Tools/conda_package/docs/_build/html/0.0.11')' returned non-zero exit status 2.
Error: Process completed with exit code 1.

@xylar
Copy link
Collaborator

xylar commented Nov 6, 2024

@altheaden, I was able to reproduce the error you posted above. It seems to happen for an old version of MPAS-Tools, 0.0.10, so we need to skip that version, similar to what was done in MPAS-Analysis:
https://github.com/MPAS-Dev/MPAS-Analysis/blob/develop/docs/conf.py#L233

I'll push a fix to the branch.

@xylar
Copy link
Collaborator

xylar commented Nov 6, 2024

Okay, I think I have the docs config cleaned up. We just needed to skip two versions, 0.0.1 and 0.0.10 (not sure why), for the docs to build. I did a bunch of other clean up in that config file, too, similar to what we did on other repos.

@xylar xylar merged commit bce4c2f into MPAS-Dev:master Nov 6, 2024
4 checks passed
@xylar
Copy link
Collaborator

xylar commented Nov 6, 2024

Thanks @altheaden!

@altheaden altheaden deleted the transition-to-actions branch November 7, 2024 15:37
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.

2 participants