Skip to content

Block unlocker marking all blocks as orphaned #48

@CaptainMeatloaf

Description

@CaptainMeatloaf

I'm attempting to set up a pool for turtlecoin (https://github.com/turtlecoin/turtlecoin), at http://turtlepool.space, and appear to be having issues with getting the pool to unlock the blocks correctly.

UPDATE: For those using TurtleCoin, this was fixed, this bug still may apply to other cryptonote currencies.

I have set up the daemon and wallet (using simplewallet), and the pool appears to connect to them and read ok.

image
I then set up my miner to mine to the pool. It has managed to find several successful blocks, however when a block is discovered, the block becomes orphaned after the maturity depth has passed.

There are no obvious errors in any of the logs.

Upon further inspection, it appears that there is an off-by-one error in blockUnlocker.js.

This can be temporarily fixed by changing line 48 of blockUnlocker.js from
apiInterfaces.rpcDaemon('getblockheaderbyheight', {height: block.height}, function(error, result){
to
apiInterfaces.rpcDaemon('getblockheaderbyheight', {height: block.height + 1}, function(error, result){

However this feels like somewhat of a hack.

Please let me know if you need any more info.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions