~jeffrom

https://jeffrom.com

hullo


#131 multi-device support 11 days ago

Ticket created by ~jeffrom on ~emersion/soju

Afaict, soju doesn't have multi-device support -- ie i open a client on my phone and answer a message, and when i open my laptop at home, the messages exchanged while i was on my phone appear.

As for a possible UX, I am thinking a user can identify multiple devices using a string representing the unique device id following the character "#" (ie a "fragment") at the end of the sasl username. If any sasl users have the fragment, soju will track the last message id by device. An example sasl user would be:

user/irc.example.com/6697#myphone

maybe a less surprising format could be:

user@myphone/irc.example.com/6697

With this scheme an edge case would be logins without a fragment when the user has already defined one or more device ids. A solution to this could be to warn the user when they log in, and otherwise just treat an empty fragment as a single separate device. Could go more strict, but seems bad to block logins if there's no way to administrate devices.

CHATHISTORY could also provide a solution here, though afaict there's no way in the spec for a user to provide a device id on login.

Since I'd rely this feature, I'm up for taking a crack at it :) thanks for the great work on soju.