Chia-Network / pool-reference

Reference python implementation of Chia pool operations for pool operators
Apache License 2.0
439 stars 197 forks source link

Can't start pool #286

Open rabbitii opened 1 year ago

rabbitii commented 1 year ago

(venv) root@chia-pool:~/pool-reference# CHIA_ROOT="/root/.chia/mainnet/" ./venv/bin/python -m pool Traceback (most recent call last): File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "/usr/lib/python3.10/runpy.py", line 86, in _run_code exec(code, run_globals) File "/root/pool-reference/pool/main.py", line 1, in from pool.pool_server import main File "/root/pool-reference/pool/pool_server.py", line 35, in from .pool import Pool File "/root/pool-reference/pool/pool.py", line 50, in from .singleton import create_absorb_transaction, get_singleton_state, get_coin_spend, get_farmed_height File "/root/pool-reference/pool/singleton.py", line 20, in from chia.types.blockchain_format.program import Program, SerializedProgram ImportError: cannot import name 'SerializedProgram' from 'chia.types.blockchain_format.program' (/root/pool-reference/venv/lib/python3.10/site-packages/chia/types/blockchain_format/program.py)

netcom-rs commented 1 year ago

This is caused by some changes. please change following line in /root/pool-reference/pool/singleton.py

from chia.types.blockchain_format.program import Program, SerializedProgram

to

from chia.types.blockchain_format.serialized_program import Program, SerializedProgram.

Cheers.

AmineKhaldi commented 1 year ago

I sent https://github.com/Chia-Network/pool-reference/pull/287 to address this. Thank you both!