This bug was found while implementing Bug #32085 ("Write tests for StreamedMedia") Gabble's incoming-basics.py test includes the following: # Changing members in any way other than adding or removing yourself is # meaningless for incoming calls, and the flags need not be sent to change # your own membership. assert not flags & cs.GF_CAN_ADD, flags assert not flags & cs.GF_CAN_REMOVE, flags assert not flags & cs.GF_CAN_RESCIND, flags I had to comment it out. There are also other problems with group-flags that I had a bash at fixing, but I'm not sure what the *correct* behaviour is (and I don't know of anyone who actually checks the group flags at the moment) so I've split out this bug so that they can be fixed later.
http://telepathy.freedesktop.org/spec/Channel_Type_Streamed_Media.html roughly describes how group interface manipulations affect calls (though I notice it doesn't specify whether you should remove yourself or your peer from an ongoing call to end it … whoops). Given that, plus the ruling that you may always remove the self handle from a group, even if CAN_REMOVE is not set—which was in the spec. forever, but not implemented, so the CM has to call tp_group_mixin_class_allow_self_removal() to make tp-glib allow it—then I think the flags should be as follows: Incoming call: members=[peer] local-pending=[self_handle] flags=0 -- you can reject the call by removing yourself Outgoing call: members=[self_handle] remote-pending=[peer] flags=Can_Rescind Ongoing call: members=[peer, self_handle] flags=0 (or Can_Remove if you think that removing the other person is a reasonable way to end calls).
Added it to the end of my streamedmedia_tests branch. > Incoming call: > > members=[peer] > local-pending=[self_handle] > flags=0 -- you can reject the call by removing yourself > Yup. This is what I end up with. > Outgoing call: > > members=[self_handle] > remote-pending=[peer] > flags=Can_Rescind > I end up with CAN_ADD and CAN_REMOVE as well, for compatibility with the legacy ways of making outgoing calls. > Ongoing call: > > members=[peer, self_handle] > flags=0 (or Can_Remove if you think that removing the other person is a > reasonable way to end calls). Decided to keep CAN_REMOVE set if we are the initiator, because that's what the code allows. For incoming calls, we have it set to 0. Roll on Telepathy 1.0, when we can delete this mess.
Merged to master along with the fixes for #32085.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.