Deltachat-desktop: Group image not updated if someone else changes it

Created on 3 Nov 2018  路  9Comments  路  Source: deltachat/deltachat-desktop

How to reproduce:

  1. create a group with someone
  2. change group image
  3. let the other user change image
  4. image not updated

Below I have a chat with "Dave". I first set the level.png group image (and Dave's android client updates the group image accordingly). However, when Dave _changes_ the group image on his side (to the delta.png image) the desktop client doesn't update (it renders a normal message with an attached image) and keeps the old level.png.

screenshot from 2018-11-03 15-52-53

Shouldn't this be automatically handled by core? Or do you need to do some magic on the specific client to make this work?

cc @r10s


TODO:

  • [x] Handle this in desktop (or wait for core to do that)
  • [x] Update message style (centered `$Person changed Group Image) (fixed in https://github.com/deltachat/deltachat-desktop/pull/366)
bug

All 9 comments

@r10s I'd really like your feedback on this when you have a few minutes over.

Shouldn't this be automatically handled by core? Or do you need to do some magic on the specific client to make this work?

this should be handled automatically by the core.

the core parses theses messages and you get the new image from dc_chat_get_profile_image(). ui-wise it should not make a difference if the group image was changed by the local or by a remote user - the event DC_EVENT_CHAT_MODIFIED is emitted in both cases.

however, please note that the dc_chat_get_profile_image() will just point to another file; the files as such won't be changed and the old file will also still be present (as the old message is probably also still there).

to get a better chat overview, i would suggest to check if a given message is an "info" message and render them differently - eg. only text, centered. to check this state, you can use dc_msg_is_info().

this should be handled automatically by the core.

My point is that core does _not_ handle this. The profile image for the chat isn't updated. I.e. if I call dc_chat_get_profile_image() again, it's the same file as the previous one.

i will have a closer look at this and check if it really works as expected on cmdline/android-dev.

@ralphtheninja it was a bug in the core, i just have fixed it in https://github.com/deltachat/deltachat-core/pull/455 - there's nothing to do in js/node on this.

Awesome. Thanks!

Thank you for being so patient.

We need to release this in new node bindings first. Keeping it open until that is done.

Works well now!

Was this page helpful?
0 / 5 - 0 ratings