chia: patch deadlock
This commit is contained in:
parent
fff93b8065
commit
d1cca15796
@ -16,6 +16,11 @@ let chia = python3Packages.buildPythonApplication rec {
|
||||
hash = "sha256-OlaAnUy16QBff81XMoYQaZA0wKnsr+/3XEQLBP8IMug=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# chia tries to put lock files in the python modules directory
|
||||
./dont_lock_in_store.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace setup.py \
|
||||
--replace "==" ">="
|
||||
|
21
pkgs/applications/blockchains/chia/dont_lock_in_store.patch
Normal file
21
pkgs/applications/blockchains/chia/dont_lock_in_store.patch
Normal file
@ -0,0 +1,21 @@
|
||||
--- a/chia/wallet/puzzles/load_clvm.py
|
||||
+++ b/chia/wallet/puzzles/load_clvm.py
|
||||
@@ -82,18 +82,6 @@ def load_serialized_clvm(clvm_filename, package_or_requirement=__name__) -> Seri
|
||||
"""
|
||||
hex_filename = f"{clvm_filename}.hex"
|
||||
|
||||
- try:
|
||||
- if pkg_resources.resource_exists(package_or_requirement, clvm_filename):
|
||||
- # Establish whether the size is zero on entry
|
||||
- full_path = pathlib.Path(pkg_resources.resource_filename(package_or_requirement, clvm_filename))
|
||||
- output = full_path.parent / hex_filename
|
||||
- compile_clvm(full_path, output, search_paths=[full_path.parent])
|
||||
-
|
||||
- except NotImplementedError:
|
||||
- # pyinstaller doesn't support `pkg_resources.resource_exists`
|
||||
- # so we just fall through to loading the hex clvm
|
||||
- pass
|
||||
-
|
||||
clvm_hex = pkg_resources.resource_string(package_or_requirement, hex_filename).decode("utf8")
|
||||
assert len(clvm_hex.strip()) != 0
|
||||
clvm_blob = bytes.fromhex(clvm_hex)
|
Loading…
Reference in New Issue
Block a user