Jitsi IRC needs some work


I use the IRC plugin for jitsi desktop and it works, but there are a few issues.

One is that it opens chats with chanserv/nickserv/spammscanner or whatever bots the servers have running, and these are all treated as a new message. They can not be blocked as contacts (and even if they could that doesn’t seem like the correct solution), and it makes it hard to see when real messages from people arrive. A lot of irc clients have this issue but in jitsi it is especially bad.

Most of the commands don’t work. Even the ones that are apparently implemented.I think /join partially works and /msg but I think that is it.

Nothing has changed with this and it seems a pity that the majority of the work should be let down by a few small issues.

My question is can someone who knows the code base point me to the parts that govern these features so I can have a look? I haven’t done java for a while but I should be able to at least estimate how easy it would be to solve my issues. I am not even sure if the plugins are part of the main codebase or are separate projects.

I tried poking around but I find the search function on github to be completely inadequate and I feel like it would save me a lot of time, potentially hours, if someone familiar with it could drop me a couple of filenames.

I really like jitsi desktop but I feel it is falling behind its competitors. Open communication systems are too important to let them get squeezed out by the likes of whatsapp and skype.

Thanks for reading if you got this far.


So Jitsi Desktop is OSGi based app, everything is bundles.
There are multiple protocol providers https://github.com/jitsi/jitsi/tree/master/src/net/java/sip/communicator/impl/protocol one of them is the IRC: https://github.com/jitsi/jitsi/tree/master/src/net/java/sip/communicator/impl/protocol/irc everything you can search for IRC is under that package. The library used is https://github.com/migzai/irc-api


Awesome, thanks a lot. Any chance you could link the code that deals with opening new chat windows too?

Edit: I should probably set up an IDE and have a poke around, rather than asking for further information. I imagine I can figure it out by putting breakpoints in the protocol code.


The implementation of the UI service is under https://github.com/jitsi/jitsi/tree/master/src/net/java/sip/communicator/impl/gui


Hmm it looks like you are going to have to explain this to me like I am 5. I tried to set up in intellij and was able to get the project to build and run. It appears that breakpoints don’t work but this seems to be normal in ant and I can survive without breakpoints (though they would help if there is a way).

I seem to be misunderstanding the build process though. I tried just changing random ui strings and then running it and none of my changes seemed to have any effect. I tried the rebuild option as well and nothing. I was replacing resources.getI18NString(“someStringID”) with “test” on UI elements I am confident of finding in the application. I changed about 20 before I gave up.

Is there something obvious I am doing wrong?


So basically, you change screen, do ant make or ant rebuild and then ant run? Doing this from the console should change the strings and run with your changes.
The build process is that it first compiles everything, then it splits it by bundles (different jar files), you can see that, every bundle has its own task in the build.xml and when you run it, the main calls OSGi loader passing the https://github.com/jitsi/jitsi/blob/master/lib/felix.client.run.properties where there is description of the startup order and bundles are beeing loaded and started by OSGi.


Alright I got it. The issue was that I was using the Intellij standard build action in ant as a before launch action, which is default. The correct way for anyone reading this with the same issue is to remove the build action and replace it with a ‘run ant target’ on the target called ‘rebuild’.


Any chance you could cast a brief glance over my solution?

I am not entirely sure it is the correct way to do this. I want to block notification of the message but not necessarily block the message from being received at all. But looking at the code I think I would have to modify the whole message event chain. It would require being able to specify in a message event that notification listeners should not be notified. I was hoping to get this change in without touching anything outside of the irc bundle. The current solution works but it will block everything with a bit more zeal than is necessary. It would be cool to still be able to open chat with chanserv and see the message history, or to message nickserv and see the reply.

Oh and while I am here. There is another issue I forgot in the OP, the irc client does not show special characters correctly. Characters like üäö and ß are examples that come up for me a lot and they are rendered by a pair of two other characters when I receive them in irc. I am not sure where to start with that, it is obviously an encoding issue but not one I am familiar with.


Hey, looks good, looking at it from my phone :slight_smile:
Just two small/cosmetic things, first you have mixed style of the braces, needs to be on new line. And add the license header on the new files. Take a look at https://desktop.jitsi.org/Documentation/CodeConvention make sure the code is as expected.
Than create a PR, but I will be able to look at it next week if Ingo doesn’t beat me on it :stuck_out_tongue:


Yeah that is kind of embarrassing. I used to relying on auto format in my ide and I had not set up intellij properly.

Do you have any tips about the character encoding issue? I tried outputting the message to the console at every stage where something was done with it and it rendered correctly every time in the console. Many of the irc commands dont work either. I just assumed that they werent implemented but it could be that there is an encoding issue there as well.

I was looking at line 61 of parseIrcMessage

but when I output builder.Done() to the console it looks fine


You mean characters received from irc server? You print those chars in impl.protocol.irc coming from the library? Maybe the problem is in the library then.


Maybe, I will look into that