Skip to content

Commit

Permalink
lmdb: print query data for reproducing binary read error.
Browse files Browse the repository at this point in the history
  • Loading branch information
fiatjaf committed Sep 17, 2024
1 parent b2dc864 commit 5c8e0df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lmdb/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ func (b *LMDBBackend) QueryEvents(ctx context.Context, filter nostr.Filter) (cha

evt := &nostr.Event{}
if err := bin.Unmarshal(val, evt); err != nil {
log.Printf("lmdb: value read error (id %x): %s\n", val[0:32], err)
log.Printf("lmdb: value read error (id %x) on query prefix %x sp %x dbi %d: %s\n", val[0:32], q.prefix, q.startingPoint, q.dbi, err)
return fmt.Errorf("error: %w", err)
}

Expand Down

0 comments on commit 5c8e0df

Please sign in to comment.