Describe the bug
This line of code throws error "Do not know how to serialize a BigInt" which originate from pg package. Turns out because the tip value is an object type {tip: 0n, feeExchange: undefined} instead of 0n
TypeError: Do not know how to serialize a BigInt
at JSON.stringify (<anonymous>)
at prepareObject (/Users/ken/relayer-services/node_modules/pg/lib/utils.js:85:19)
at prepareValue (/Users/ken/relayer-services/node_modules/pg/lib/utils.js:66:12)
at arrayString (/Users/ken/relayer-services/node_modules/pg/lib/utils.js:29:31)
at prepareValue (/Users/ken/relayer-services/node_modules/pg/lib/utils.js:63:12)
at prepareValueWrapper (/Users/ken/relayer-services/node_modules/pg/lib/utils.js:193:12)
at writeValues (/Users/ken/relayer-services/node_modules/pg-protocol/dist/serializer.js:67:41)
at Object.bind (/Users/ken/relayer-services/node_modules/pg-protocol/dist/serializer.js:98:5)
at Connection.bind (/Users/ken/relayer-services/node_modules/pg/lib/connection.js:160:26)
at Query.prepare (/Users/ken/relayer-services/node_modules/pg/lib/query.js:211:18
Describe the bug This line of code throws error "Do not know how to serialize a BigInt" which originate from
pg
package. Turns out because thetip
value is an object type{tip: 0n, feeExchange: undefined}
instead of0n
To Reproduce Steps to reproduce the behavior:
substrate-ingest
against our testnettry...catch
Expected behavior
tip
value is not in an expected type, but continue on rather getting stuckEnvironment (please complete the following information):
Applicable to decoding issues: