jdev - 2021-02-01

  1. paul

    jonas’: I've heard that you wrote xep 0392 and implemented it in poezio, isn't it?

  2. jonas’

    paul, both correct!

  3. paul

    I have a color issue, following the xep I have different color from poezio, and reading the poezio code I see that when computing the hue_angle the sha output is / 65535 instead of 65536 in the xep

  4. jonas’

    that is a typo in the poezio source then

  5. jonas’

    the XEP has the correct value

  6. paul

    ok thanks :)

  7. jonas’

    (logic behind it: as the result is supposed to be an angle, 0 == 360. Hence, we don’t want to be able to generate *both* 0 and 360. Hence, we must divide by 2^16 instead of 2^16-1 in order to get the full possible range of distinct values out of the 16 bits of hash)

  8. jonas’

    paul, thanks for the hint, I shall patch it

  9. paul

    make sense, you are welcome for the hint

  10. lovetox

    a few days ago i asked if there is a client that stores notifications in a way they survive a restart

  11. lovetox

    does someone know such a client? is there any one that thinks this is important for a client?

  12. lovetox

    or can we live with seeing 0 notifications after restart

  13. Kev

    Psi will store unread message counts, if that's what you mean.

  14. lovetox

    yes its a subset of what i mean, but yes thats probably the most important notification

  15. lovetox

    i wonder what i should store, simply a dict like thing like "contact: 10 notifications"

  16. lovetox

    or does the user need to know exactly which 10 messages are unread

  17. lovetox

    i could probably store the stanza or message id

  18. Kev

    Psi stored the messages.

  19. lovetox

    but then it gets much for mucs ect, if i have to store 350 unread messages with message id etc in a public muc

  20. Kev

    Of course, I've not looked at the Psi code for coming up to a decade and a half, so I may be a *smidge* out of date.

  21. lovetox

    yeah maybe i take a look myself

  22. Sam Whited

    Gajim shows me a little unread marker when I start it if that's what you mean? Or do you want it to pop up notifications again for each message?

  23. jonas’

    actually this sounds like "inbox"

  24. lovetox

    yes Sam Whited , i mean exactly that, right now Gajim saves one db row for every unread message but only 1:1

  25. lovetox

    and yes jonas’ its probably that if we talk about syncing this state across clients

  26. lovetox

    but i rather try to think how i can solve this locally

  27. lovetox

    i just wonder if and how this saving of unread messages scales in public mucs

  28. Zash

    lovetox, one row per message? as opposed to one row per chat, with a pointer to the latest message?

  29. Stefan

    Some clients have notification setups. None, mentioned, always. In big public mucs I have just mentioned. I would recommend to do this based on the notification setup.

  30. Stefan


  31. Sam Whited

    What Zash said. Although I still don't get what you're asking or what you're trying to do I think.

  32. lovetox

    Sam Whited, you have 1134 messages unread in jdev, your computer does a restart

  33. lovetox

    what do you expect to see when you start it again

  34. jonas’

    lovetox, I think I don’t expect a notification for those, but the unread counter in the UI should be correct.

  35. Sam Whited

    lovetox: the chat marked however you mark unread (maybe it's bold, maybe it has a little icon, an unread number, whatever) and when I open it there's a line dividing the read from the unread and it's at the top of the unread list.

  36. jonas’

    but I *do* expect a notification for messages which arrived between the last focus to gajim and the restart, I think.

  37. Stefan

    1134 unread messages + new as counter. I think conversations does.

  38. Sam Whited

    I wouldn't expect any notifications after restart (assuming you mean some sort of pop up) personally.

  39. lovetox

    ok so i need to save the counter, and the last message-id, and if you open the chat again, i scroll to that message-id and thats it

  40. jonas’

    Sam Whited, torn on that one, I think no notifications is OK

  41. lovetox

    sorry with notification i mean a bubble with the counter

  42. lovetox

    not a desktop notification

  43. jonas’

    yeah, those need to be correct

  44. Sam Whited

    oh gotcha, yah, I'd show an icon or a counter or something

  45. lovetox

    ok and when you focus the chat, and i scroll to that message, should the counter go to 0?

  46. jonas’

    I personally think there’s no good solution to that. All solutions are terrible / wrong.

  47. jonas’

    I personally think there’s no good solution to *that* specifically. All solutions are terrible / wrong.

  48. lovetox

    i mean i can color all messages in a way so you know they are unread

  49. lovetox

    but when i the point where i mark them read

  50. Sam Whited

    On a desktop client at least I'd expect it to go to zero once I've scrolled to the bottom. That's what Slack does and it seems to work pretty well.

  51. jonas’

    but IME the solutions which allow me to mark as read as easily and painlessly as possible are the least worst

  52. Sam Whited

    Or once I click the "Clear notification" or "Jump to recent messages" or whatever if either of those are a feature you hvae

  53. lovetox

    im in the process of rewriting the whole thing, so thats why i ask

  54. lovetox

    reaching bottom is good i guess

  55. lovetox

    but with that solution i dont need to save all message-ids, only the first unread

  56. lovetox

    and the total count

  57. Sam Whited

    It also depends if you have threads, I think. Those may change things.

  58. lovetox

    no i dont have threads

  59. lovetox

    and i will not

  60. lovetox

    personally i hat them

  61. Sam Whited

    Cool, no need to handle those differently then

  62. Sam Whited

    Yah I haven't seen a threading implementation I like. I want them, I like the general idea, I just don't like any of the implementations I've tried. Slack is the least-bad I think, but it's the only one I've used in a long time so I may just be used to the pain.

  63. jonas’

    Sam Whited, out of curiousity, did you try zulip?

  64. jonas’

    (a recent one, they had a major release in 2020)

  65. jonas’

    we had a zulip trial run at $dayjob, and I was pleasantly surprised. threads feel really natural and workable there.

  66. Kev

    Slack's looks ok on the surface, but then you realise that threads are invisible as soon as you don't choose 'share in main channel' or whatever it's called, and you don't see replies, and blah. I agree it's probably the least-bad, mind.

  67. Sam Whited

    jonas’: I think so, but I literally don't remember it. That sounds really familiar though. Definitely didn't try it in 2020, so maybe I'll play with it again

  68. Kev

    My favourite threading implementations are the ones that just allow replies to messages, rather than 'threads'.

  69. Sam Whited

    Kev: I really like that they're invisible actually and that I can get to them from the initial message and from the "Threads" view, I just wish they had a subject to make them more obvious and you could see a list of threads by channel

  70. Kev

    Different use case, I guess.

  71. Sam Whited

    I like it because I end up discussing a feature I'm working on in our team channel, and some front end people end up discussing some front end stuff I don't care about, and neither of us have to get every channel notification, it's just kind of hidden away for people who want that conversation to look at