Skip to content

Add py-tools variant and set $ISSM_DIR Environment Variable#336

Merged
aidanheerdegen merged 10 commits intomainfrom
lb/issm-dev
Oct 24, 2025
Merged

Add py-tools variant and set $ISSM_DIR Environment Variable#336
aidanheerdegen merged 10 commits intomainfrom
lb/issm-dev

Conversation

@lawrenceabird
Copy link
Copy Markdown
Collaborator

This PR adds the following functionality:

  • New py-tools variant to install Python function files to <prexix>/python-tools/. These files are necessary to A) access the wrappers that are included in <prefix>/lib/ and B) to conduct various pre- and post-processing of ISSM models. Note: Python files are stored in various subdirectories (e.g. src/m/mesh, src/m/mask, src/m/solve) in the ISSM directory. Here, we flatten this structure to just save all Python files in one directory (<prefix>/python-tools/) as the subdirectory structure serves no functional purpose.

  • Export $ISSM_DIR environment variable. This is required by various Python wrappers to obtain information about the run environment.

This PR addresses Issue #333.

Functionality was tested in ACCESS-NRI/ACCESS-ISSM#25

Addressing Ruff failure -- removed "##" (replaced with "#") and added consistent comment to +examples option
@lawrenceabird lawrenceabird self-assigned this Oct 15, 2025
Comment thread packages/issm/package.py
Comment thread packages/issm/package.py Outdated
Comment thread packages/issm/package.py Outdated
Store python files as a *.zip archive to reduce inode usage; Add additional conflict to require +wrappers when +py-tools to ensure that python tools are fully-functional.
@harshula
Copy link
Copy Markdown
Collaborator

harshula commented Oct 16, 2025

@lawrenceabird
Copy link
Copy Markdown
Collaborator Author

Completed requested updates. Confirmed successful redeploy here and confirmed functionality by testing the WIP MISMIP example here.

This PR is now ready for re-review @aidanheerdegen and @harshula.

@lawrenceabird
Copy link
Copy Markdown
Collaborator Author

This new functionality was used in this PR to test a new deployment of an updated ISSM code base on Gadi. This deployed successfully.

aidanheerdegen
aidanheerdegen previously approved these changes Oct 16, 2025
Copy link
Copy Markdown
Member

@aidanheerdegen aidanheerdegen left a comment

Choose a reason for hiding this comment

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

Looks good.

Comment thread packages/issm/package.py Outdated
Comment thread packages/issm/package.py Outdated
Comment thread packages/issm/package.py Outdated
Prepare for new "access-release" branch to handle official releases.
@lawrenceabird
Copy link
Copy Markdown
Collaborator Author

@harshula and @aidanheerdegen -- I've addressed all comments and confirmed that these changes still work (here). I subsequently added an access-release version in preparation for a new "release" branch in our ISSM forked repo. This untested addition should have no impact on this PR.

Comment thread packages/issm/package.py Outdated
Refactor use of exclude_dirs
Copy link
Copy Markdown
Member

@aidanheerdegen aidanheerdegen left a comment

Choose a reason for hiding this comment

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

LGTM.

If you're happy to do so we generally do a squash merge unless there is a reason to keep separate commits, in which case a rebase to clean-up the commit history would be the way to go.

@aidanheerdegen aidanheerdegen merged commit 248caf3 into main Oct 24, 2025
3 checks passed
@aidanheerdegen aidanheerdegen deleted the lb/issm-dev branch October 24, 2025 03:47
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.

3 participants