Modern XMPP project discussion - 2021-12-05


  1. lovetox

    Zash, just because im reading the old history in this room

  2. lovetox

    about XEP0084

  3. lovetox

    it was not created with the goal in mind to publish the same avatar in multiple sizes

  4. lovetox

    what it specifies is that you can publish the same avatar in multiple content-types

  5. lovetox

    but only image/png, can be in pubsub

  6. lovetox

    the rest needs to be added with alternative methods like https links or whatever is allowed

  7. Zash

    you can't stop me from publishing multiple resolutions!

  8. lovetox

    why though, why would i not download the highest resolution one, and scale it to whatever i need as client?

  9. Zash

    why would you, when you could not

  10. Zash

    save the bandwidth and storage use until it is needed

  11. lovetox

    the logic you would need for that is not worth the 2 seconds more for a higher resolution

  12. lovetox

    you cant just say as a client i need 100x100 pixel

  13. jonas’

    it may be more than 2 seconds on a GPRS mobile link

  14. lovetox

    you need to ask, on what monitor am i, do i have high dpi?

  15. lovetox

    what reosolution does the user operate on etc

  16. lovetox

    then it goes furter, do i display this avatar in different sizes in the UI?

  17. lovetox

    in roster its small, so i need a smaller one

  18. lovetox

    in profile window its big so i need a bigger one

  19. lovetox

    you can invest months into adding this logic only to determine what avatar you download, and the user does not even see the effort or value it in any way

  20. lovetox

    you didnt spend your time to actually make a useful thing for the main goal of your application

  21. lovetox

    that is communicating with other people

  22. jonas’

    if it unblocks the mobile link, sure.

  23. lovetox

    you just invested months into a 40x40 avatar picture somewhere on the side on the screen

  24. jonas’

    (also, months? wtf…)

  25. lovetox

    yeah months, and it will be buggy, and not even work on all operating systems

  26. lovetox

    and you will draw in dependencys only to get the needed infos from your system on all os

  27. lovetox

    and you are the first human who ever invested that time into an avatar, and nobody will ever know

  28. lovetox

    because nobody cares really

  29. Zash

    you don't care ≠ nobody cares

  30. jonas’

    Ok.

  31. Zash

    not worth the effort in a desktop client with broadband ≠ not worth it

  32. MattJ

    Product vs protocol: probably a product would store every avatar in two standard sizes, and that's that

  33. MattJ

    The smaller size would be enough to display as a thumbnail in/beside a chat or in the contact list. The larger one would be used only when viewing the user's profile

  34. lovetox

    yes MattJ but i download the higher one, and scale it myself to the smaller one

  35. lovetox

    because i need to scale anyway

  36. lovetox

    because nobody will publish in the size i need to display anyway

  37. MattJ

    If the high one is high-res (photo, etc.) that download and scaling *can* be costly multiplied by contacts and time

  38. lovetox

    but it is not costly, scaling on any machine is only a fraction of the time a download needs

  39. lovetox

    and we are talking about small resolutions here

  40. lovetox

    like <400x400 max

  41. pep.

    What's the guarantee you'll have a 400x400 max picture

  42. lovetox

    the standard who says dont upload big pictures :D

  43. lovetox

    and the size attribute in the metadata, who tells me what i dont want to download

  44. Zash

    the standard that says you must upload 64x64px png, but gives you a way to communicate the size and the type?

  45. Zash

    and does having only 64x64px png seem like a Modern thing?

  46. lovetox

    no i agree there probably should not be a size mentioned

  47. lovetox

    just a guiding value

  48. lovetox

    64x64 is definitly to small

  49. lovetox

    on highdpi with scale 2 thats like almost an icon

  50. lovetox

    or i have to scale it up and it looks shitty

  51. pep.

    Maybe standards have to be updated with the fashion of the moment

  52. pep.

    (*surprise*)

  53. MattJ

    It's the kind of thing that if we don't get into a XEP, should definitely have recommendations on modernxmpp.org

  54. lovetox

    but i would offer a option to download no avatars at all for the user, if he is on a link where this can be a problem

  55. Link Mauve

    lovetox, image bombs are a thing, where the file size is small but the resolution is very high, burning through a lot of computation when you do your scaling.

  56. lovetox

    because many small avatars is still much traffic

  57. Link Mauve

    It might not matter on a big powerful modern desktop computer, it will on a not-so-modern mobile device.

  58. Zash

    I'm thinking publish a scaled something reasonable + original as alternative format.

  59. lovetox

    Link Mauve, thats sad, but still i need the resolution i need in my gui, and not the one someone publishes an avatar for, so no scaling is not an option

  60. lovetox

    Zash, whats you idea behind that?

  61. lovetox

    like you want to save people data with your avatar

  62. lovetox

    or what?

  63. lovetox

    you cant even know on what machine, in what UI they look at it

  64. lovetox

    every size you think is ok, might be shitty for them

  65. lovetox

    we would have to make some vote under the clients, what the ususal avatar size is they need

  66. lovetox

    to determine "reasonable"

  67. pep.

    *at the time of voting

  68. pep.

    And for the type of clients voting*

  69. lovetox

    in Gajim i upload avatars at 200x200

  70. lovetox

    if the original picture has that of course

  71. Link Mauve

    “13:32:44 lovetox> because many small avatars is still much traffic”, btw, do you have stats about the bandwidth required by the various features in different usecases?

  72. Link Mauve

    Like, for avatars I’d assume that’s mostly a one-time download, afterwards it will get cached, so it’s not that much worth optimising for.

  73. lovetox

    of course not, but yes would be interesting, measure MAM vs Avatar download on MUC join

  74. lovetox

    etc

  75. Link Mauve

    Even if you have a shitton of contacts, the download will only happen either when you add them, or when they update their avatar.

  76. Link Mauve

    Ah right, MUC as well.

  77. lovetox

    yes, thats what im saying, its not worth to put any work into this logic

  78. lovetox

    i download the highest and im fine

  79. Link Mauve

    Well, first connection is still a thing.

  80. Link Mauve

    It gives the first impression of your software.

  81. lovetox

    yeah, thats why i have for avatars a queue

  82. lovetox

    so it will need some minutes to download 100 avatars

  83. lovetox

    also so joining mucs is faster

  84. lovetox

    because most avatars are via vcard request

  85. lovetox

    if you join a muc with 300 people and you send 300 vcard request, this means you join the other mucs slower

  86. Zash

    if you join a MUC with 300 people and all of them fetch your vcard, that's a pile of traffic for the MUC and your server

  87. Link Mauve

    Is your queue priorised? So that when the user scrolls in the participants list you will move downloading the visible avatars to the front?

  88. Link Mauve

    Zash, if it became an issue, the MUC service could cache the request.

  89. Link Mauve

    Zash, if it became an issue, the MUC service could cache the response.

  90. lovetox

    haha Link Mauve, no

  91. Link Mauve

    lovetox, also I’ve seen people use services like Discord or such, where the list of users is so long they don’t download anything not in the view.

  92. lovetox

    yeah that depends on the capabilities of your framework

  93. Link Mauve

    It makes it feel pretty slow ime, but optimises away most of the traffic until it is needed.

  94. Link Mauve

    GTK 4 supports that. :)

  95. lovetox

    alone the work to get the info "whats currently in the view" is not an easy task in gtk

  96. lovetox

    Gtk4 supports not drawing whats not in the view

  97. Zash

    wasn't that the thing GTK4 has magic to do for you?

  98. Link Mauve

    lovetox, even not having widgets for those.

  99. lovetox

    its great that GTK4 has some new things which are welcome

  100. Link Mauve

    And recycling widgets which moved out of the view for the ones now in the view.

  101. lovetox

    but look at the gtk4 issue tracker

  102. lovetox

    shit is broken all around, basic things dont work

  103. Link Mauve

    Oh really?

  104. lovetox

    like im notgoing to migrate to that in the next year

  105. lovetox

    its a small project, they have view developers who added a bunch of new things

  106. Link Mauve

    I haven’t had any issue with it so far, after I finished fixing its GLES 2.0 backend for my phone circa GTK 4.2.

  107. lovetox

    and now we can wait for them to find the time to make them stable

  108. lovetox

    so yeah, gtk3 has issues, but im not ready to trade them against other issues :)

  109. lovetox

    especially if i know other messengers, from companys who pour in millions into the development

  110. Link Mauve

    Ok, well, have fun then. ^^'

  111. lovetox

    and i dont see them perform any better

  112. lovetox

    Cross UI Frameworks on desktop are a compromise

  113. lovetox

    but yeah that gtk4 feature to draw only whats on screen is badly needed

  114. lovetox

    in Gajim we have logic, to unload much stuff, or otherwise the client will get laggy

  115. MattJ

    lovetox: BTW, on the topic of Gajim and modern XMPP, do you think it's a possibility for OMEMO to merge into core or at least be enabled by default?

  116. MattJ

    And is there an issue about it sending the first couple of messages in plaintext even when enabled?

  117. lovetox

    omemo has to be enabled for every chat specifically

  118. lovetox

    and no if you enable it, its not possible to send a message unencrypted

  119. lovetox

    at least im not aware of any bug there

  120. lovetox

    what probably happens is, people download the plugin, enable the plugin, and now think everything is encrypted

  121. MattJ

    I see

  122. lovetox

    they probably miss that the need now to enable it in the specific chat

  123. lovetox

    enabling it by default, is and open improvement issue on our tracker

  124. lovetox

    enabling it by default, is an open improvement issue on our tracker

  125. lovetox

    i just didnt have yet the time to do it

  126. MattJ

    Good to know, thanks

  127. lovetox

    on Windows the plugin is packaged, and enabled by default

  128. lovetox

    so i dont see much difference to it beeing in core

  129. lovetox

    and on debian for example it is also automatically installed if you pull "recommended" packages

  130. Sam

    That's the difference with it being in core though; some OS's (Arch in particular, Debian as well but they provide an easy way to install at least) won't install any plugins by default and people don't know they have to go install them separately

  131. Sam

    Other OS's take the approach of bundling sensible defaults.

  132. Sam

    Having it in core means you don't have to rely on their policies, they'll all just have the sensible defaults you pick.

  133. Link Mauve

    Sam, ArchLinux very much assumes the user will read the optdepends when installing a package.

  134. Link Mauve

    If the user doesn’t do that, they probably should use a different distribution.

  135. Sam

    Link Mauve: yes, that's my point.

  136. lovetox

    Sam, usually if something new comes up, and its not sure if its something the community needs, we implement it as a plugin

  137. lovetox

    later if its clear that it something that everybody uses now, we move it into core

  138. lovetox

    plugins also let you faster iterate

  139. lovetox

    and its not something the core maintainers need to look at

  140. lovetox

    also it gives contributors and easy way into the project, implementing something of use, without going it to broad discussion with the core maintainers if this is something we need in the core

  141. lovetox

    also it gives contributors and easy way into the project, implementing something of use, without going into broad discussion with the core maintainers if this is something we need in the core

  142. Sam

    lovetox: yes, I know, I was suggesting that it might make sense to have this in core now (or as a bundled plugin, doesn't matter, just "shipped with core" however you do that).

  143. lovetox

    you mean the current version, or the one the XEP describes but almost nobody has implemented :D

  144. lovetox

    but yes omemo has become a wide implemented thing right now

  145. lovetox

    it makes sense to consider it core of a client