-
Notifications
You must be signed in to change notification settings - Fork 87
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: approve session proposal, receive session disconnect #1331
Conversation
…nV2 into fix/bunch_of_reported_issues
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also curious about why you switched the toast code in the sample
@@ -358,6 +368,6 @@ internal class SignEngine( | |||
} | |||
|
|||
companion object { | |||
private const val WATCHER_INTERVAL = 3000L | |||
private const val WATCHER_INTERVAL = 5000L |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what do you think about bumping this value to something like 10 or even 30 sec? I think to save on resources, we could check less frequently. We also have other checks to validate expiry so I think we would be ok having something longer
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah I agree. I think that checking every 30s is fine
try { | ||
val pairingTopics = pairingRepository.getListOfPairings().filter { pairing -> pairing.isNotExpired() }.map { pairing -> pairing.topic.value } | ||
val pairingTopics = runBlocking { pairingRepository.getListOfPairings().filter { pairing -> pairing.isNotExpired() }.map { pairing -> pairing.topic.value } } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why does this need to be blocking? I think we should think about going the other way and launch a coroutine in the init block and make this function a suspend function to run async. We're already launching coroutines inside of this function
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, good point. Made this function a suspend function.
It was causing session request and proposal dialogs to disappear in some corner cases |
No description provided.