set_path: include python version in cache dir name #17
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.
If you use pykeops from two different Python versions, it crashes. For example:
The cache directory contains two
.so
s in this case, one with a full tag specific to the version (libKeOpsnumpy5ac3d464a2.cpython-37m-x86_64-linux-gnu.so
) but also one that isn't (libKeOpsnumpy5ac3d464a2.so
). There might be some proper way of allowing them to coexist in the same directory, which would be good e.g. also if the same home directory is used on different platforms. This PR just addssys.implementation.cache_tag
, egcpython-36
, to the default build folder name to work around this (as well as a bit of cleanup in the function overall).