V5.2.0 : UpdateWitnessHeights : Assertion `nd.witnessHeight == -1' failed

Attempting to sync backup node, it seems to be borked after upgrade.

zcashd: wallet/wallet.cpp:2655: void UpdateWitnessHeights(NoteDataMap &, int, int64_t) [NoteDataMap = std::map<SaplingOutPoint, SaplingNoteData>]: Assertion `nd.witnessHeight == -1’ failed.

ACK. I have reproduced this also locally from a v5.1.0 to v5.2.0. There are some issues on github related to this:

What config are you using?

Specifically. are you using txindex insightexplorer or lwd flags in zcash.conf?

zcash.conf is pure vanilla :-

mainnet=1
addnode=mainnet.z.cash
rpcuser=deleted
rpcpassword=deleted
rpcport=8232

EDIT: Attempting to recover with ‘-reindex’