Bitmessage/PyBitmessage

Strange log messages started to appear with recent code changes

g1itch opened this issue · 11 comments

Hello!

With recent code I see this log message when opening any 'inbox' folder in the bitmessageqt app

2021-08-27 15:49:00,688 - WARNING - Section or Option did not found: No section: 'BM-2cXrFSw75fT5FP7qWbM86jpMTSGFBD7uLU'
2021-08-27 15:49:00,691 - WARNING - sendBroadcast didn't work

UPD: it appears without any action, probably related to sending a pubkey

Introduced in 6dffb1e or earlier, I'm checking it with the appimage: https://github.com/g1itch/PyBitmessage/actions/runs/1174396926

Check your "Sent" folder, you may have a broadcast queued for an address that is now deleted. It's only improved logging that changed, before it would also try to send a broadcast but just silently fail.

Maybe check with sqlite command line tool even, I'm not sure it would show up in "Sent" if the address has been deleted in the meantime.

Good night! Found it:

sqlite> SELECT subject, message, status FROM sent WHERE fromaddress='BM-2cXrFSw75fT5FP7qWbM86jpMTSGFBD7uLU' and folder='sent';
subject|message|status
test_subject|test message|doingbroadcastpow

The error messages now also have improved accuracy, if it says sendBroadcast didn't work, it really means sendBroadcast didn't work, rather than a pubkey or some other object. Step by step things are getting better.

Shouldn't it also report an error for these 10 broadcasts?

sqlite> SELECT count(*) FROM sent WHERE status='broadcastqueued' and folder='sent';
10

Now I see many warnings about "Proof of Work exception" which are wrong, please see my comments on fc19c54

I always suggest writing tests to avoid exactly such cases. Before editing the code you need to understand and document what it does, I think.

You can also see it in the recent buildbot runs, e.g. https://buildbot.bitmessage.org/#/builders/25/builds/2180/steps/8/logs/stdio, line 852.

This is the effect of missing return: https://buildbot.bitmessage.org/#/builders/25/builds/2220/steps/8/logs/stdio, line 846

This one is also started to appear lately:

WARNING - (Within the processgetpubkey function) Someone requested one of my pubkeys but the requestedAddressVersionNumber doesn't match my actual address version number. Ignoring.

And the "Proof of Work exception" right after it.