Do not send initial message for "promoting the group"#16
Open
Do not send initial message for "promoting the group"#16
Conversation
This eliminates all the possibilities of this initial message sending failing and warnings like "WARNING: Only 0/1 receivers joined the group". It is ok for receivers to not get a number of messages at first, they will have the chat created as soon as they get a single message.
j4n
approved these changes
Mar 20, 2026
j4n
left a comment
There was a problem hiding this comment.
Looks good to me, makes the tool quite a bit more snappy too. I did implement your suggested direct mode as well, but this addresses the issue elegantly.
|
|
||
| # Wait for all receivers to join the group | ||
| wait_for_receivers_to_join(args, sender, receivers) | ||
| # Phase 2: Group creation |
There was a problem hiding this comment.
Very minor: This says Phase 2, which, referring to the timed phases (line 433), its no longer timed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This eliminates the possibility of the first message being lost. Pinger just starts sending messages, and receivers will get the group whenever some message arrives. The group is auto-accepted by setting the "bot" config, there is no need to accept "contact request" manually.
Closes #15, at least we will not get "WARNING: Only 0/1 receivers joined the group" and cmping does not get stuck completely.
Closes #13 which is another attempt to fix the same problem. This PR removes the code so there is no need to try to fix it.
I tested, it finished by itself after 3 pings and 60 second timeout when nothing is delivered:
The other way round there is reordering and no loss, also finishes: