TryQuiet / quiet

A private, p2p alternative to Slack and Discord built on Tor & IPFS
https://www.tryquiet.org
GNU General Public License v3.0
1.94k stars 86 forks source link

JS error when joining community on desktop #1712

Open holmesworcester opened 1 year ago

holmesworcester commented 1 year ago

A user joined a small community with some existing data on an M1 Mac. Version 1.4.0

Here's roughly what happened:

  1. User attempted to join
  2. I could see the name they had attempted to register in the community.
  3. From their point of view they were stuck on "registering user"
  4. They restarted to see if it would work
  5. They got a javascript error.

I pasted the full logs as they sent them to our internal chat. Here's the error:

2023-08-15T23:41:45.374Z [ERROR] exchange-heads: Error: Not Found
    at Module.notFoundError (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:435443:16)
    at MemoryDatastore.get (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:435511:64)
    at runNextTicks (node:internal/process/task_queues:60:5)
    at listOnTimeout (node:internal/timers:533:9)
    at process.processTimers (node:internal/timers:507:7)
    at async PersistentStore.load (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:454276:21)
    at async PersistentPeerStore.get (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:454607:20)
    at async findPeer (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:278645:14)
    at async id (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:278607:18)
    at async get_peer_id (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:483449:20) {
  code: 'ERR_NOT_FOUND'
}
TypeError: Cannot read properties of undefined (reading 'connect')
    at exchange_heads (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:483590:17)
    at runNextTicks (node:internal/process/task_queues:60:5)
    at listOnTimeout (node:internal/timers:533:9)
    at process.processTimers (node:internal/timers:507:7)
    at async OrbitDB._onPeerConnected (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:484051:5)
/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:251772
            throw new Error();
            ^

Error
    at process.<anonymous> (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:251772:19)
    at process.emit (node:events:513:28)
    at process.processEmit [as emit] (/Applications/Quiet.app/Contents/Resources/app.asar/node_modules/backend-bundle/bundle.cjs:247059:34)
    at emit (node:internal/process/promises:149:20)
    at processPromiseRejections (node:internal/process/promises:283:27)
    at processTicksAndRejections (node:internal/process/task_queues:96:32)
    at runNextTicks (node:internal/process/task_queues:64:3)
    at listOnTimeout (node:internal/timers:533:9)
    at process.processTimers (node:internal/timers:507:7)
kingalg commented 9 months ago

We are currently on 1.9.7 official version, 2.0.3 alpha and with new release will change joining process. I would suggest closing this issue unless someone encounter it on our alpha versions. Alpha 1.4.0 in which the user encounter an issue is from July and may have significantly more issues that we will not see in current versions, especially when we are talking about joining process. @holmesworcester ?