Gajim - 2017-10-17


  1. concerto lovetox: all menu entries in the Gajim menu are grayed out, too, so I can't disable plugins the usual way.
  2. Zash So Gajim publishes PEP items with id="0" in most places. But bookmarks use "current"
  3. Nothing4You hm
  4. Nothing4You gui on osx has some issues
  5. Nothing4You also i can't find a way (without config edit & restart) to bring the roster back after hiding it
  6. Nothing4You nvm got it back now
  7. Nothing4You it won't get focused anymore though
  8. Nothing4You https://imgur.com/a/Y7Ea1 first one is the tray icon
  9. Nothing4You second is some weird positions of checkboxes
  10. lovetox hm first one we can nothing do about it, you can deactivate the tray if you like
  11. lovetox if you minimize gajim it should be in your dock
  12. lovetox second i dont see something weird about that, they are like that
  13. lovetox Zash i will change that to set no id
  14. lovetox it seems the most correct behavior for these kind of publishes
  15. Zash why?
  16. Nothing4You are those checkboxes whether those messages are supposed to have a custom color?
  17. lovetox because its not the responisbility of the client to manage what IDs are at what point in time inside the Node and what IDs should be maybe overwritten
  18. Nothing4You they look misplaced when just looking at it
  19. lovetox at least for this scenario
  20. lovetox i publish to the Node, and PEP must deliever the last published item to my contacts
  21. Nothing4You i'd like to use the tray, now it seems to work
  22. Nothing4You and it seems to be safer to just show/hide roster via the tray icon
  23. Zash lovetox: There was that text that says to use the id "current" in case there should only ever be one item
  24. lovetox that makes no sense in this context because its unclear for the client what happens if another client doesnt respect this
  25. Zash In this case, Gajim is the one not respecting it
  26. lovetox yeah and we dont have to
  27. lovetox thats the point
  28. lovetox but thats why i change it to set NO id
  29. lovetox because then the server is responsible for doing the right thing
  30. lovetox i agree current in this context should not be used
  31. lovetox or do you delete all other itemids if i publish with current?
  32. lovetox i doubt it
  33. Zash No but I overwrite it.
  34. lovetox the current one, but what if theres others in there
  35. Zash Almost done with removing items to keep within the limit tho, but damn databases.
  36. lovetox i mean whats the difference in behavior if i publish to "current1" or to "current" in both cases i guess you will always overwrite the id
  37. Zash Except here I have one client using "current" and then I started Gajim and stored items with id "0"
  38. Zash And the real difference is that https://xmpp.org/extensions/xep-0060.html#impl-singleton says > it is RECOMMENDED for the publisher to specify an ItemID of "current" to ensure that the publication of a new item will overwrite the existing item.
  39. lovetox the existing with the id "current"
  40. lovetox but this behavior is the same for all other items ids
  41. lovetox i would have to query the node first to see if there is a current itemid and not maybe others, then delete all others, then start publishing to current to overwrite
  42. lovetox and for what? all that i want is that pep delivers the last published item
  43. lovetox if it has id current or something else i dont care
  44. lovetox and neither should PEP care
  45. pep. I promise I do care
  46. lovetox =)
  47. lovetox infact overwriting a itemid is again unclear what will happen
  48. lovetox if i overwrite a itemid is it then the last published one?
  49. lovetox even if the itemid exstist longer than others
  50. Zash https://xmpp.org/extensions/xep-0060.html#impl-uniqueness
  51. lovetox ah thanks
  52. lovetox But Zash just to clear that up for me, simply publishing with id "current" does make a Node Singleton ?
  53. Zash lovetox: Other way around. If it's a singleton node you should use id = "current". The node should also be configured with max items = 1, but maybe some funny person went and configured it with something else. Or some bleeding edge implementation doesn't support max items yet.
  54. lovetox a node that has max items = 1 does not care if i publish with "current" or any other ID, it holds always only one item
  55. lovetox the only way this part of the xep would make sense to me is if a server would set max-items=1 automatically once he receives a push with id "current"
  56. lovetox but that seems not to be the case
  57. lovetox and i found another part that worrys me
  58. lovetox When processing a new subscription, the service MAY send not only the last published item but instead all items that are currently associated with the node
  59. lovetox this is from PEP xep
  60. lovetox please dont do this
  61. lovetox dont send all items on subscription
  62. Zash I don't actually know if that works at all currently
  63. lovetox to be honest all these problems go away if you just config the default max-items of a node as 1
  64. lovetox this should be the SMART default for a PEP impl
  65. Zash it is
  66. lovetox thats good then :)
  67. Zash It's just that I'm in the middle of implementing that for when it's set to be persistent
  68. Zash And the code used for persisting stuff is the same as used for MAM, which didn't have this requirement when it was originally written.
  69. lovetox ah now i get it
  70. lovetox previously everything was in mem
  71. lovetox now you have to use the DB
  72. lovetox so new storage code
  73. lovetox or old (MAM) but new for pep
  74. Zash And you usually only delete the oldest MAM messages, and we do it by timestamp currently, not item count.
  75. Zash And it turns out that (in case of a SQL backend) telling a database to delete all but the last X items is nontrivial
  76. lovetox hm, i guess you first have to count
  77. lovetox then delete
  78. lovetox sort per timestamp (i dont know if this made it to the room)
  79. Zash sqlite can `delete where ... order by timestamp limit -1 offset n` and it does what I want
  80. Zash Guess if that works in anything else
  81. lovetox ah forgot about offset
  82. lovetox is limit -1 really necessary?
  83. Zash yes
  84. Zash -1 is no limit apparently
  85. lovetox yeah but what if i specify no limit
  86. Zash and the query without limit and only offset is an error
  87. lovetox ah ok
  88. Zash and mysql can only do limit (delete this number of items) and no offset
  89. Zash postgres has neithre
  90. lovetox Nothing4You, int, do you use the tray icon?
  91. lovetox i would remove it and then move the entrys to the menu that you can pop up if you click on the icon in the dock
  92. int Lovetox great idea :D
  93. int Lovetox but the messages window gets focused on the first click i hope :)
  94. lovetox no i dont think i can do that, its not for me to say what gets focused on click sadly
  95. lovetox but why you dont use single window mode?
  96. Asterix And hard to guess which chat window to open if there are several
  97. Nothing4You I suppose that might be an option
  98. Asterix Single window mode is here for that
  99. Nothing4You I guess you're talking about the context menu?
  100. lovetox hm i looked into it, would need a lot of restructuring code, not worth the effort
  101. lovetox i guess the tray icon is not needed when using single window mode anyway
  102. bot Philipp Hörist pushed 2 commits to branch _refs/heads/master_ of _gajim_ <https://dev.gajim.org/gajim/gajim>: *1f0cc2b6* <https://dev.gajim.org/gajim/gajim/commit/1f0cc2b6655ef34cb6773f0d0c39273c50871723> Fix bindtextdomain not available on MacOS *0d16ef32* <https://dev.gajim.org/gajim/gajim/commit/0d16ef32e6193b3b20f13816b3faee33a12aa118> Fix StatusIcon on MacOS
  103. lovetox this is a fix, still does not really look natural , but at least its not doubled
  104. lovetox but i recommend single window mode and disabling the tray altogether
  105. Nothing4You except i don't use single window mode :|
  106. Nothing4You i prefer single chat window + roster
  107. lovetox why?
  108. Link Mauve Traceback (most recent call last): File "/usr/lib/python3.6/site-packages/gi/overrides/GLib.py", line 747, in <lambda> func_fdtransform = lambda _, cond, *data: callback(channel, cond, *data) File "/usr/lib/python3.6/site-packages/nbxmpp/idlequeue.py", line 549, in _process_events return IdleQueue._process_events(self, fd, flags) File "/usr/lib/python3.6/site-packages/nbxmpp/idlequeue.py", line 409, in _process_events obj.pollin() File "/usr/lib/python3.6/site-packages/nbxmpp/transports_nb.py", line 446, in pollin self._do_receive() File "/usr/lib/python3.6/site-packages/nbxmpp/transports_nb.py", line 669, in _do_receive self._on_receive(received) File "/usr/lib/python3.6/site-packages/nbxmpp/transports_nb.py", line 683, in _on_receive self.on_receive(data) File "/usr/lib/python3.6/site-packages/nbxmpp/dispatcher_nb.py", line 531, in _WaitForData resp(self._owner, _iq, **args) File "/usr/lib/python3.6/site-packages/gajim/common/connection_handlers.py", line 476, in _parse_vcard callback(jid, resource, room, vcard) File "/usr/lib/python3.6/site-packages/gajim/common/connection_handlers.py", line 518, in _on_avatar_received avatar_sha, photo_decoded = self.get_vcard_photo(vcard) File "/usr/lib/python3.6/site-packages/gajim/common/connection_handlers.py", line 448, in get_vcard_photo photo_decoded = base64.b64decode(photo.encode('utf-8')) File "/usr/lib/python3.6/base64.py", line 87, in b64decode return binascii.a2b_base64(s) binascii.Error: Incorrect padding
  109. Link Mauve lovetox, so that thing I found in poezio somewhere in my contacts is actually also present in Gajim.
  110. Link Mauve You should consider the avatar invalid in that codepath.
  111. Link Mauve I will do so in poezio too.
  112. lovetox ok you mean i should catch the error and print a warning
  113. lovetox thanks for letting me know, even if i suspect you will be the only person who ever sends these invalid avatars ^^
  114. lovetox you probably uploaded one already to your vcard to see how many clients crash ^^
  115. Link Mauve I’m not the one sending them, it’s some of my contacts.
  116. Link Mauve They probably should get their client fixed.
  117. Link Mauve My own avatar is perfectly valid. :p
  118. Asterix Yes a log.warn + ignore the avatar
  119. mathieui except for the lack of png, Link Mauve ?
  120. Link Mauve mathieui, neither 0054 nor 0153 mandate any PNG.
  121. Link Mauve It’s only a SHOULD in a receiving application to be able to decode it.
  122. Zash 84 is the one saying at least one published picture MUST be PNG, IIRC
  123. Link Mauve Zash, thankfully I don’t publish my avatar that way. :)
  124. bot Philipp Hörist pushed 1 commit to branch _refs/heads/master_ of _gajim_ <https://dev.gajim.org/gajim/gajim>: *3a6e1ac9* <https://dev.gajim.org/gajim/gajim/commit/3a6e1ac9fc7d0f1f1a5f690c4bb3e0ee3aea9422> Catch exception for invalid avatars
  125. lovetox do you want to test that Link Mauve ?
  126. Link Mauve Sure.
  127. Link Mauve lovetox, don’t use % for logging.
  128. lovetox damn
  129. lovetox i didnt above
  130. Link Mauve If you use a different argument, the concatenation will only happen if the message is to be logged.
  131. Link Mauve You didn’t do it twice, you did it the third time. :p
  132. lovetox thats because pylint needs minutes to parse the files
  133. lovetox ..
  134. lovetox in my defense i only didnt do it once
  135. Link Mauve ^^
  136. debacle Is there a road map or plan, when plugins are ported to GTK3? I'm mainly interested in rostertweaks, triggers, and urlimagepreview. Not need to rush, just to get an idea... TIA!
  137. debacle plugins = remaining plugins
  138. debacle I know, that antispam, httpupload, omemo, pgp, and others are already ported.
  139. lovetox would have to look into it, some are probably easy
  140. lovetox like rostertweaks
  141. lovetox debacle, roster tweaks is ported
  142. lovetox one option is buggy and should be removed though
  143. lovetox but i wonder if people use this and what for
  144. Link Mauve lovetox, in the preferences, pane Style, at the bottom the “Your message” checkbox is messing up dark themes.
  145. Link Mauve You may want to uncheck that by default.
  146. Link Mauve That way it’s correctly white on these.
  147. lovetox yeah
  148. lovetox do you know a css parser/writer?
  149. lovetox i would like to write these style options to a user css file
  150. Link Mauve No, I wrote one for poezio but that’s all.
  151. Link Mauve Why don’t you rely on the GTK+ theme?
  152. lovetox because its not user friendly to tell a user hey edit the css in the gtk theme
  153. lovetox of course for the default i would rely on default gtk theme
  154. Link Mauve I mean, remove style customisation from Gajim altogether.
  155. lovetox but for some options users should be able to change it
  156. Link Mauve Because it’s a big pane which mostly clutters the interface for no reason.
  157. lovetox hm .. no it works so why removing it, we just should use sane defaults also for dark theme
  158. Link Mauve Because having clutter in the interface makes people want to stop dealing with it.
  159. lovetox the best thing would be if i could write the options to css, then load the user css. but writing a own parser and writer ...
  160. lovetox what clutter? what interface? you mean one page in the preference?
  161. Link Mauve For one user in one thousand who will find value in modifying one config value, you will have 980 who will flee screaming at the interface.
  162. Link Mauve Most of the preferences actually.
  163. lovetox i dont fint it cluttered, its not even many preferences
  164. lovetox there are many missing, that can only be set with ace
  165. ThibG Tbh, I used to avoid the preference screen so far, so that I almost completely forgot about its existence. Switching from latest stable to the current dev version switched to Gtk3 and hence used my dark Gtk3 theme (as set by gnome-tweak-tool)
  166. Zash We all have different tolerances for that :)
  167. Zash I think Swift has too many options and menus
  168. Link Mauve Same.
  169. Link Mauve Dino got it almost right, there are still a few too many but it’s almost correct.
  170. lovetox Link Mauve, dino is a client who is not used by many and not very old
  171. lovetox the older it gets the more people it uses, the more options it will get
  172. lovetox thats natural
  173. Link Mauve I hope not.
  174. Zash Some would say one should resist adding too many options.
  175. Link Mauve And from what I’ve heard from one of the maintainers, it won’t.
  176. Zash Depends on your target audience a bit tho
  177. lovetox my opinion is, client should have good defaults so that users dont think about changing something
  178. lovetox but if he thinks about it, it should be possible if its something reasonable
  179. Asterix Default gtk theme is the default in Gajim
  180. ThibG And while the experience with a dark theme across applications is not so good, gajim just made me go back to the default theme
  181. ThibG Messing with the styling was too much of a pain
  182. lovetox not for everything asterix, it seems we set a custom color for message text color
  183. Link Mauve lovetox, nitpick about the commit you asked me to test: you should also display who sent that avatar to me.
  184. Link Mauve Such as “17/10/17 21:47:07 (W) gajim.avatar Invalid Avatar from foo@bar: Incorrect padding”
  185. lovetox you can see it, if you log with gajim.avatar=DEBUG
  186. lovetox but its hard to get all infos into the method for the warning
  187. Asterix lovetox: hmm ok, I'll check that. We should not.
  188. Asterix GN guys
  189. lovetox GN
  190. debacle lovetox: about rostertweaks: I don't use it myself, but I heard it were useful on PocketCHIP, which has a very small screen. With Gajim + rostertweaks on PocketCHIP one has a very cheap and nice portable XMPP client.
  191. debacle Unfortunately, I could not yet buy me one :~(
  192. lovetox its probably then about removing the status bar
  193. lovetox gives you a inch more
  194. lovetox also the GTK2 version had a menu in the window
  195. lovetox the GTK3 the menu is exported as global menu in most systems
  196. lovetox dont know what pocketchip uses
  197. debacle lovetox: No idea. Something small :~)
  198. bot Philipp Hörist pushed 2 commits to branch _refs/heads/gtk3_ of _gajim-plugins_ <https://dev.gajim.org/gajim/gajim-plugins>: *b96cb2ee* <https://dev.gajim.org/gajim/gajim-plugins/commit/b96cb2ee2ba9f046c0a41f2effb55fc805c78e55> [rostertweaks] Fix some Bugs - pylint/pep8 - Fix show/hide menubar - Fix send status - Update glade file to Gtk 3.18 *6a82485e* <https://dev.gajim.org/gajim/gajim-plugins/commit/6a82485e23df4b1fd4d4f60cabbd716a61257cf9> [rostertweaks] Update manifest.ini
  199. lovetox so debacle rostertweaks should be usable now