turboflakes / crunch

Crunch is a command-line interface (CLI) and Matrix Bot to claim staking rewards every Era for Substrate-based chains
https://turboflakes.io
Apache License 2.0
64 stars 22 forks source link

System.d error and "Chain not supported" #52

Open overmarck opened 1 day ago

overmarck commented 1 day ago

I've tried to use system.d service, but when i start node i get (with sudo journalctl...)

[2024-11-26T00:13:14Z INFO crunch] crunch v0.18.3 * Crunch is a command-line interface (CLI) to claim staking rewards (f> thread 'async-std/runtime' panicked at src/runtimes/support.rs:78:18: not implemented: Chain not supported [2362303]: note: run with RUST_BACKTRACE=1 environment variable to display a backtrace

kusamacrunchbot.service: Main process exited, code=exited, status=101/n/a systemd[1]: kusamacrunchbot.service: Failed with result 'exit-code'.

overmarck commented 1 day ago

This is my system.d config file

[Unit] Description=Kusama Autopayout

[Service] ExecStart=/home/myusername/crunch-bot/crunch --config-path /home/myusername/crunch-bot/.env rewards era --seed-path /home/myusername/crunch-bot/.private.seed --disable-matrix Restart=always RestartSec=15

[Install] WantedBy=multi-user.target

paulormart commented 1 day ago

Hi there, did you set var with the kusama url endpoint CRUNCH_SUBSTRATE_WS_URL=___ANY_PUBLIC_OR_PRIVATE_KUSAMA_ENDPOINT___ here /home/myusername/crunch-bot/.env ?

overmarck commented 1 day ago

Hi there, did you set var with the kusama url endpoint CRUNCH_SUBSTRATE_WS_URL=___ANY_PUBLIC_OR_PRIVATE_KUSAMA_ENDPOINT___ here /home/myusername/crunch-bot/.env ?

Sure this is my env file:

[CRUNCH_SUBSTRATE_WS_URL] Substrate websocket endpoint for which 'crunch' will try to

connect. (e.g. wss://rpc.turboflakes.io:443/kusama) (NOTE: substrate_ws_url takes precedence

than argument)

CRUNCH_SUBSTRATE_WS_URL=wss://rpc.turboflakes.io:443/kusama

I get this error when i launch ./crunch: [2024-11-26T10:12:43Z INFO crunch] crunch v0.18.1 * Crunch is a command-line interface (CLI) to claim staking rewards (flakes) every X hours for Substrate-based chains thread 'async-std/runtime' panicked at src/runtimes/support.rs:79:18: not implemented: Chain not supported note: run with RUST_BACKTRACE=1 environment variable to display a backtrace

paulormart commented 1 day ago

Can you run this command in your terminal and does it work?

/home/myusername/crunch-bot/crunch --config-path /home/myusername/crunch-bot/.env view

If it raises an issue can you share your .env file? (Please make sure it does not contain any private information before you share it)

overmarck commented 1 day ago

Can you run this command in your terminal and does it work?

/home/myusername/crunch-bot/crunch --config-path /home/myusername/crunch-bot/.env view

If it raises an issue can you share your .env file? (Please make sure it does not contain any private information before you share it)

This is command result: [2024-11-26T10:56:25Z INFO crunch] crunch v0.18.1 * Crunch is a command-line interface (CLI) to claim staking rewards (flakes) every X hours for Substrate-based chains thread 'async-std/runtime' panicked at src/runtimes/support.rs:79:18: not implemented: Chain not supported note: run with RUST_BACKTRACE=1 environment variable to display a backtrace

I've attached env.txt

paulormart commented 1 day ago

Set this var to CRUNCH_LIGHT_CLIENT_ENABLED=false or just remove it or add as comment

overmarck commented 1 day ago

Set this var to CRUNCH_LIGHT_CLIENT_ENABLED=false or just remove it or add as comment

thanks, with this i've solved