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

Add a version check to load script #739

Merged
merged 2 commits into from
Nov 30, 2023

Conversation

xylar
Copy link
Collaborator

@xylar xylar commented Nov 30, 2023

If the load script is for a different compass version, a developer is told to rerun the configure script.

Checklist

  • Developer's Guide has been updated
  • Documentation has been built locally and changes look as expected
  • Document (in a comment titled Testing in this PR) any testing that was used to verify the changes

@xylar xylar self-assigned this Nov 30, 2023
@xylar xylar added enhancement New feature or request dependencies and deployment Changes relate to creating conda and Spack environments, and creating a load script labels Nov 30, 2023
@xylar
Copy link
Collaborator Author

xylar commented Nov 30, 2023

Testing

If the version in compass/version.py matches the version in the load script, the everything proceeds as usual when the load script gets sourced. If the versions don't match, the output is something like:

$ source load_compass_test_morpheus_gnu_openmpi.sh 
This load script is for a different version of compass:
__version__ = '1.2.0-alpha.6'

Your code is version:
__version__ = '1.2.0-alpha.7'

You need to run ./conda/configure_compass_env.py to update your conda 
environment and load script.

If the load script is for a different compass version, a developer
is told to rerun the configure script.
@xylar xylar force-pushed the check-version-in-load-script branch from 5d9aafd to ce76cae Compare November 30, 2023 04:44
@xylar xylar merged commit a461f10 into MPAS-Dev:main Nov 30, 2023
4 checks passed
@xylar xylar deleted the check-version-in-load-script branch November 30, 2023 05:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies and deployment Changes relate to creating conda and Spack environments, and creating a load script enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant