Fixes #1009#1010
Closed
VityaSchel wants to merge 1 commit intomautrix:masterfrom
Closed
Conversation
tulir
reviewed
May 30, 2025
| ) | ||
| else: | ||
| await invited_by.client( | ||
| EditAdminRequest(channel=self.peer, user_id=puppet.tgid, admin_rights=ChatAdminRights(), rank="Bridge") |
Member
There was a problem hiding this comment.
Users can invite anything, not only relaybots, so the admin title shouldn't be hardcoded
Author
There was a problem hiding this comment.
can they invite bots? cause this condition is for bots in channels only which can only be admins who manage channel on behalf of users in the bridged matrix room
I'm open to suggestions on what to rename this rank to, because I think it's required unless you suggest just passing empty string to rank argument. Perhaps "Relay" or "Matrix bot"?
Member
There was a problem hiding this comment.
The relay bot has no special status, it's just a random telegram bot that the user is inviting. Users can invite any other bot or user the exact same way
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.
Use EditAdminRequest instead of InviteToChannelRequest for puppet bot relays in channels
FYI this will probably be closed by @tulir so you can always apply this commit as patch when installing mautrix telegram or even easier just make these simple changes in lib/python[your-version]/site-packages/mautrix_telegram/portal.py file to apply them on your selfhosted bridge