attestate / kiwistand

kiwistand is a p2p node client for a web3 writer friendly Hacker News that nobody controls but everybody co-owns
https://news.kiwistand.com
GNU General Public License v3.0
63 stars 26 forks source link

stack underflow in trie #146

Closed TimDaub closed 2 months ago

TimDaub commented 2 months ago
[1] Stack Trace: Error: You must mint the Kiwi NFT to upvote and submit!
[1]     at _add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:396:11)
[1]     at asyncWrapper (/Users/timdaub/Projects/attestate/kiwistand/node_modules/fastq/queue.js:235:12)
[1]     at push (/Users/timdaub/Projects/attestate/kiwistand/node_modules/fastq/queue.js:131:14)
[1]     at /Users/timdaub/Projects/attestate/kiwistand/node_modules/fastq/queue.js:254:7
[1]     at new Promise (<anonymous>)
[1]     at Object.push (/Users/timdaub/Projects/attestate/kiwistand/node_modules/fastq/queue.js:253:13)
[1]     at Module.add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:360:22)
[1]     at put (file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:337:19)
[1]     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:458:7
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:389:18
[1] 2024-09-09T15:38:53.715Z @attestate/kiwistand Attempting to store message with index "66d065b901d62e385338b3bcf4e173f7a3ba9ea34bbd64cd2332bbbd51289c9350300b88" and message: "{"href":"https://longform.asmartbear.com/reputation/","signature":"0xd53711394867b8393a3c6c961ff8da2c4c88db97a047bce8c780f7436352d1e451aaa99c2af046f0f7878995ed04393937c215bac562def00879328bad26e2401c","timestamp":1724933561,"title":"Reputation isn’t as powerful as you imagine","type":"amplify"}"
[1] 2024-09-09T15:38:53.715Z @attestate/kiwistand trie.put failed with "Error: Stack underflow". Successfully rolled back constraint
[1] Message: put: Didn't add message to database
[1] Stack Trace: Error: trie.put failed with "Error: Stack underflow". Successfully rolled back constraint
[1]     at atomicPut (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:318:11)
[1]     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[1]     at async _add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:438:32)
TimDaub commented 2 months ago
[1] 2024-09-10T11:15:36.809Z @attestate/kiwistand Attempting to store message with index "66e01e4214a0a5d430ffe56026c8700b161a11a32bb14be262922996e94efa306a9efdc9" and message: "{"href":"https://www.dejobaan.com/blog/an-ai-that-raps-about-games","signature":"0x840cdc4e4e248800ca350e89e44508c7fb41ac4b2f979d6b0ca2f2d2bfb8fb875bf17d3b68f44eeb12b915eccf7f2149466f046d902ecc97866f39c72b387abf1c","timestamp":1725963842,"title":"Rapping About What’s On Steam","type":"amplify"}"
[1] 2024-09-10T11:15:36.809Z @attestate/kiwistand Message with marker "0xD01559BB03cc83d4661193b513e5A083Ad0cc8Cf|https://dejobaan.com/blog/an-ai-that-raps-about-games|amplify" doesn't pass legitimacy criteria (duplicate). It was probably submitted and accepted before.
[1] Message: put: Didn't add message to database
[1] Stack Trace: Error: Message with marker "0xD01559BB03cc83d4661193b513e5A083Ad0cc8Cf|https://dejobaan.com/blog/an-ai-that-raps-about-games|amplify" doesn't pass legitimacy criteria (duplicate). It was probably submitted and accepted before.
[1]     at atomicPut (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:280:13)
[1]     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[1]     at async _add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:471:32)
[1]     at async Module.add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:392:10)
[1]     at async put (file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:337:7)
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:458:7
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:389:18
[1] 2024-09-10T11:15:36.809Z @attestate/kiwistand Calling trie commit, and saving root: 8744dd06af45097295c556ab4a9526b0be21ca01c04f607c4f2b866b0049c843
[1] 2024-09-10T11:15:36.880Z @attestate/kiwistand Unsetting global peer
[1] 2024-09-10T11:15:37.443Z @attestate/kiwistand Setting global peer: "16Uiu2HAmFzqeeF18eXy4SRTN79Y6DkPgFjx8qJf2LmY4K35dR52K"
[1] 2024-09-10T11:15:37.443Z @attestate/kiwistand handleLeaves: Received leaves and storing them in db
[1] 2024-09-10T11:15:37.486Z @attestate/kiwistand Attempting to store message with index "643c442d5c608bd8d22bc947ed18f513d3c0e9df97861190fa556f1138511faddf14e782" and message: "{"href":"https://craigmod.com/essays/fast_software/","signature":"0x6a4861e03540a4ee0daf113c37a1d513ae3015657046438e3da9d14ac9bf46991efce10587d280f7996115e372cb73ecaa23fd694c5597c03a8a12041dfd3faa1c","timestamp":1681671213,"title":"Fast Software, the Best Software","type":"amplify"}"
[1] 2024-09-10T11:15:37.487Z @attestate/kiwistand trie.put failed with "Error: Stack underflow
[1]     at Trie._updateNode (/Users/timdaub/Projects/attestate/kiwistand/node_modules/@ethereumjs/trie/dist/trie/trie.js:325:19)
[1]     at Trie.put (/Users/timdaub/Projects/attestate/kiwistand/node_modules/@ethereumjs/trie/dist/trie/trie.js:158:24)
[1]     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[1]     at async atomicPut (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:288:5)
[1]     at async _add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:471:32)
[1]     at async Module.add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:392:10)
[1]     at async put (file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:337:7)
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:458:7
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:389:18". Successfully rolled back constraint
[1] Message: put: Didn't add message to database
[1] Stack Trace: Error: trie.put failed with "Error: Stack underflow
[1]     at Trie._updateNode (/Users/timdaub/Projects/attestate/kiwistand/node_modules/@ethereumjs/trie/dist/trie/trie.js:325:19)
[1]     at Trie.put (/Users/timdaub/Projects/attestate/kiwistand/node_modules/@ethereumjs/trie/dist/trie/trie.js:158:24)
[1]     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[1]     at async atomicPut (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:288:5)
[1]     at async _add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:471:32)
[1]     at async Module.add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:392:10)
[1]     at async put (file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:337:7)
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:458:7
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:389:18". Successfully rolled back constraint
[1]     at atomicPut (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:329:11)
[1]     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
[1]     at async _add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:471:32)
[1]     at async Module.add (file:///Users/timdaub/Projects/attestate/kiwistand/src/store.mjs:392:10)
[1]     at async put (file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:337:7)
[1]     at async file:///Users/timdaub/Projects/attestate/kiwistand/src/sync.mjs:458:7