Open rht opened 4 years ago
How do we prevent mirroring loops without the _zulip
suffix?
How do we prevent mirroring loops without the
_zulip
suffix?
! I forgot about that. I suppose I can just exactly match the bot nickname.
@timabbott added the fix in the 3rd commit.
My testing worked because I was coincidentally using a nick that ends with "_zulip". Now it is no longer the case and still works.
@timabbott comment addressed.
Great; can you clean up the commit history?
(And I guess we'll want to document this, maybe as a first/preferred option above the Matrix version? Maybe just add a commit to your Slack docs PR and I can process them together)
Commits squashed.
I looked at https://github.com/zulip/zulip/blob/master/templates/zerver/integrations/irc.md. It looks fine and doesn't recommend Matrix at all. Even the sentence at https://github.com/zulip/zulip/blob/master/templates/zerver/integrations/matrix.md recommends the direct IRC mirror.
IMO, we should instead advice people to use Matterbridge, if they only want to mirror only to 1 topic in Zulip. I have seen the Matterbridge in action in julialang.zulipchat.com, and it mirrors multiple protocol with only 1 configuration file. The IRC bridge works, but with unavoidable error messages, that makes the script looks bad.
@timabbott ping
Heads up @rht, we just merged some commits that conflict with the changes your made in this pull request! You can review this repository's recent commits to see where the conflicts occur. Please rebase your feature branch against the upstream/main
branch and resolve your pull request's merge conflicts accordingly.
Rebased.
The current behavior is to automatically append "_zulip" to user-specified nick prefix, hence forcing the bridge nick to end with "_zulip". This current behavior is confusing the user, especially if the user is using a password to connect to an IRC server. Additionally, if nickname is already in use, simply raise an error instead of silently adding more underscores to the nick.
Testing plan: I have tested this PR on my own laptop.