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.
This fixes #117 and should adress conda-forge/esmf-feedstock#91 and many issues on xESMF.
This adds a "guessing" snippet to
loadESMF.py
for cases when theESMFMKFILE
env var is not set.The new behaviour in 8.4 was to depend on the env variable. The
ESMpy
conda package was updated so that this env var is set upon environment activation. However, there are many cases in which a conda env is used without being activated:This new behaviour generated many issues in xESMF, raised by users who do not really know about the mechanics of ESMF/ESMpy. This PR is in part to help those users, who rely on the "out-of-the-box" aspect of conda.
The two paths I added to the guessing are the same that
ESMpy
already guesses in its conda recipe. See: https://github.com/conda-forge/esmpy-feedstock/blob/60527fe641e89da9e2ab0b3f93a5b6f67a0d20f8/recipe/scripts/activate.sh#L11-L15Thus I am suggesting replicating the "guessing" part from ESMpy's conda configuration directly in its code.
I also removed a few lines from the documentation. Unless I am mistaken, installing ESMpy from source does not require the
esmf.mk
file anymore, no?