Skip to content

RPC doesn't start if blocks are not being generated #9

Open
@jholdstock

Description

@jholdstock

Testnet had not seen a block for 5+ hours, and it caused some odd behaviour.

After unlocking the wallet, dcrlnd stopped listening on port 10009 and performed it's startup activities. It then logged the following:

2019-04-26 11:49:13.040 [INF] DCRW: Blockchain sync completed, wallet ready for general usage.

It seems like everything is ready, and at this point I would expect the RPC to be available on port 10009. However there is nothing listening on the port, and any usage of dcrlncli results in connection errors.

After speaking with @matheusd it seems that this is because dcrlnd only starts the RPC server after the wallet considers itself synced, and it won't consider itself synced if it hasn't seen a block for 2 hours. We should alter the logging so that instead of incorrectly saying the wallet is ready for usage, we inform the user that the wallet is not synced and thus the RPC is not available.

(Running commit 22a6961)

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