You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
mkmf PR 75 makes mkmf a proper conda package, moving executables from bin/ → mkmf/bin/ within the repo and installing templates to $CONDA_PREFIX/share/mkmf/templates/. These changes ensure fre-cli works with both the old and new mkmf structures.
fre/make/make_helpers.py
get_mktemplate_path() now checks $CONDA_PREFIX/share/mkmf/templates/<name> as a fallback when a bare template filename isn't found in the submodule path (fre/mkmf/templates/)
# submodule path checked first (priority); conda package path is the fallbackifPath(submodule_path).exists():
template_path=submodule_pathelse:
conda_prefix=os.environ.get("CONDA_PREFIX")
ifconda_prefix:
conda_path=conda_prefix+"/share/mkmf/templates/"+mk_templateifPath(conda_path).exists():
template_path=conda_path
fre/make/gfdlfremake/buildDocker.py
mkmf clone-and-copy Dockerfile step now checks for new PR 75 structure (mkmf/mkmf/bin/) before falling back to old structure (mkmf/bin/)
meta.yaml
Build script loops over executables, trying fre/mkmf/mkmf/bin/ first, then fre/mkmf/bin/, with a warning if neither exists (mkmf may be a separate conda dependency)
Copies fre/mkmf/templates/* to $PREFIX/share/mkmf/templates/ during conda build, mirroring what mkmf PR 75 does in the standalone mkmf package and making fre-cli self-contained for template resolution
docs/setup.rst
Fixed incorrect PATH (${PWD}/mkmf/bin → ${PWD}/fre/mkmf/bin) and added the PR 75 path so both submodule structures work: ${PWD}/fre/mkmf/bin:${PWD}/fre/mkmf/mkmf/bin
fre/make/tests/test_make_helpers.py
Added test_mktemplate_name_conda_prefix: uses monkeypatch to verify the conda prefix fallback resolves templates correctly
Issue ticket number and link (if applicable)
Checklist before requesting a review
I ran my code
I tried to make my code readable
I tried to comment my code
I wrote a new test, if applicable
I wrote new instructions/documentation, if applicable
I ran pytest and inspected it's output
I ran pylint and attempted to implement some of it's feedback
No print statements; all user-facing info uses logging module
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.
❌ Patch coverage is 90.90909% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 84.11%. Comparing base (9a0d45f) to head (31c794a).
@copilot NOAA-GFDL/mkmf PR 75 was updated- iterate
Updated to align with the latest mkmf PR 75 (commit a8620434). The key new addition in PR 75 is that templates are now installed to $PREFIX/share/mkmf/templates/ in the mkmf conda package. I've updated fre-cli's meta.yaml to mirror this: fre/mkmf/templates/* is now copied to $PREFIX/share/mkmf/templates/ during fre-cli's conda build, making fre-cli self-contained (commit 31c794a). The make_helpers.py conda prefix fallback already handles this location correctly.
This file contains hidden or 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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe your changes
mkmf PR 75 makes mkmf a proper conda package, moving executables from
bin/→mkmf/bin/within the repo and installing templates to$CONDA_PREFIX/share/mkmf/templates/. These changes ensure fre-cli works with both the old and new mkmf structures.fre/make/make_helpers.pyget_mktemplate_path()now checks$CONDA_PREFIX/share/mkmf/templates/<name>as a fallback when a bare template filename isn't found in the submodule path (fre/mkmf/templates/)fre/make/gfdlfremake/buildDocker.pymkmf/mkmf/bin/) before falling back to old structure (mkmf/bin/)meta.yamlfre/mkmf/mkmf/bin/first, thenfre/mkmf/bin/, with a warning if neither exists (mkmf may be a separate conda dependency)fre/mkmf/templates/*to$PREFIX/share/mkmf/templates/during conda build, mirroring what mkmf PR 75 does in the standalone mkmf package and making fre-cli self-contained for template resolutiondocs/setup.rst${PWD}/mkmf/bin→${PWD}/fre/mkmf/bin) and added the PR 75 path so both submodule structures work:${PWD}/fre/mkmf/bin:${PWD}/fre/mkmf/mkmf/binfre/make/tests/test_make_helpers.pytest_mktemplate_name_conda_prefix: usesmonkeypatchto verify the conda prefix fallback resolves templates correctlyIssue ticket number and link (if applicable)
Checklist before requesting a review
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.