nerdcash / Nerdbank.Cryptocurrencies

.NET libraries for processing Zcash and other cryptocurrencies.
MIT License
5 stars 3 forks source link

Optimized and rebirth heights should be -1 from the first notes #344

Closed AArnott closed 4 weeks ago

AArnott commented 1 month ago

A birthday height by definition is the height of a block that has already been mined when the account was created. Therefore a wallet would have the reasonable expectation that the birthday block itself need not be scanned for notes. But the optimized and rebirth heights returned by the library currently refer to the first block with a note. These should be -1 of that height.

AArnott commented 4 weeks ago

It turns out this is inconsistent with the policy elected by the zcash community to resolve the oddity. Birthday height is allowed to point to the first block to contain a transaction.