You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was able to connect and "Finished checking forked blocks!" using ./hyp-repair scan mymainnet. My hyperion indexer and api are running. But when I try to use the fix commands, I'm getting an invalid URL. The chain file is there (if I change the name or move the file, I get a ENOENT: no such file or directory).
khype@koyn-hyperion:~/hyperion$ git show
commit 32145b6 (HEAD -> main, origin/main, origin/HEAD)
Author: Igor Lins e Silva [email protected]
Date: Tue Oct 10 21:21:35 2023 -0300
khype@hyperion:~/hyperion$ ./hyp-repair fill-missing kmainnet .repair/mymainnet-4-33864607-missing-blocks.json
/home/khype/hyperion/node_modules/ws/lib/websocket.js:676
throw new SyntaxError(Invalid URL: ${address});
^
SyntaxError: Invalid URL: ws://localhost:undefined/local
at initAsClient (/home/khype/hyperion/node_modules/ws/lib/websocket.js:676:13)
at new WebSocket (/home/khype/hyperion/node_modules/ws/lib/websocket.js:85:7)
at fillMissingBlocksFromFile (/home/khype/hyperion/scripts/hyp-repair.js:633:24)
at Command.repairMissing (/home/khype/hyperion/scripts/hyp-repair.js:178:11)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
Node.js v18.16.0
The text was updated successfully, but these errors were encountered:
I noticed this issue has been open for a while, and I’d like to provide some clarification to help close it in case others encounter the same problem.
In the connections.json file, there is an optional parameter called control_port. While it’s not required for the normal operation of the indexer, it is necessary for the repair tool (hyp-repair) to successfully connect to the indexer.
Here’s an example configuration from example-connections.json for reference:
Default Value: The control_port defaults to 7002 and is automatically assigned by the indexer if not explicitly included in the configuration.
For Upgrades: Users installing a newer version of Hyperion likely won’t face this issue, but it may affect those upgrading from older versions where the control_port parameter was absent.
By ensuring that control_port is explicitly included in the configuration, the hyp-repair tool should work as expected.
Proposal for the Project Maintainers
Note for @igorls:
Since control_port is an optional parameter that may be omitted and the indexer assigns a default value automatically, a similar approach could be applied to the hyp-repair tool.
I was able to connect and "Finished checking forked blocks!" using ./hyp-repair scan mymainnet. My hyperion indexer and api are running. But when I try to use the fix commands, I'm getting an invalid URL. The chain file is there (if I change the name or move the file, I get a ENOENT: no such file or directory).
khype@koyn-hyperion:~/hyperion$ git show
commit 32145b6 (HEAD -> main, origin/main, origin/HEAD)
Author: Igor Lins e Silva [email protected]
Date: Tue Oct 10 21:21:35 2023 -0300
khype@hyperion:~/hyperion$ ./hyp-repair fill-missing kmainnet .repair/mymainnet-4-33864607-missing-blocks.json
/home/khype/hyperion/node_modules/ws/lib/websocket.js:676
throw new SyntaxError(
Invalid URL: ${address}
);^
SyntaxError: Invalid URL: ws://localhost:undefined/local
at initAsClient (/home/khype/hyperion/node_modules/ws/lib/websocket.js:676:13)
at new WebSocket (/home/khype/hyperion/node_modules/ws/lib/websocket.js:85:7)
at fillMissingBlocksFromFile (/home/khype/hyperion/scripts/hyp-repair.js:633:24)
at Command.repairMissing (/home/khype/hyperion/scripts/hyp-repair.js:178:11)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
Node.js v18.16.0
The text was updated successfully, but these errors were encountered: