Skip to content
This repository has been archived by the owner on Nov 7, 2023. It is now read-only.

When reading the qr code, it appears in the logs that the connection was closed. #705

Closed
joaroque opened this issue Jun 25, 2023 · 3 comments

Comments

@joaroque
Copy link

Im not able to read the QR code. When I try to do this the terminal show 'connection was close'

Help!

@joaroque
Copy link
Author

joaroque commented Jun 27, 2023

Hello! @salman0ansari

First, thank you for the project, thats help me so much. 2d ago I was found 'connection was close' error in the terminal, but when I change the maxretry in .envfile to 20 and comment the block 155:162 on src/api/class/instance.js file. The error appears when I try to read the code for the first time, but when I reload the page and try again it runs fine.
`js

if (qr) {
QRCode.toDataURL(qr).then((url) => {
this.instance.qr = url
this.instance.qrRetry++
// if (this.instance.qrRetry >= config.instance.maxRetryQr) {
// // close WebSocket connection
// this.instance.sock.ws.close()
// // remove all events
// this.instance.sock.ev.removeAllListeners()
// this.instance.qr = ' '
// logger.info('socket connection terminated')
// }
})
}
`

I think we've overloaded you so much. It seems that only you can do it and we can't, so I think we also have a lot to thank you for and help too. And on the other hand, it is noted that most of the issues here are not from devs, but from enthusiasts who do not take the time to review the code and be able to contribute to the project. Thanks again friend!

@salman0ansari
Copy link
Owner

tbh I don't have time to manage this repo anymore, maybe in July I will try to finish #486 PR this PR will fix all issues we are facing right now.

@joaroque
Copy link
Author

I want to apologize for the above error. I meant the error DISAPPEARED when I commented out the block of code.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants