Don't update tube contact capabilities according to contact's features
@gdesmott
Submitted by Guillaume Desmottes Assigned to Telepathy bugs list
Description
Created attachment 32704 log when test user is connecting using Gabble 0.8.9
I'm running Gabble master and the contact (my test user actually) gabble 0.8.9. We are both implementing a ChannelHandler supporting the "x-wormux" stream tube.
When this contact connects, I query its caps as I don't trust his URI. Once received, I called GetContactCapabilities(). As you can see the x-wormux stream tube is not announced (neither the 'rfb' one).
{26L: [({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.Text', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.TargetHandle']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.StreamTube', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.TargetHandle', u'org.freedesktop.Telepathy.Channel.TargetID', u'org.freedesktop.Telepathy.Channel.Type.StreamTube.Service']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.DBusTube', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.TargetHandle', u'org.freedesktop.Telepathy.Channel.TargetID', u'org.freedesktop.Telepathy.Channel.Type.DBusTube.ServiceName']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.StreamedMedia', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.Type.StreamedMedia.InitialAudio', u'org.freedesktop.Telepathy.Channel.Type.StreamedMedia.InitialVideo']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.Call.DRAFT', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.Type.Call.DRAFT.InitialAudio', u'org.freedesktop.Telepathy.Channel.Type.Call.DRAFT.InitialVideo', u'org.freedesktop.Telepathy.Channel.Type.Call.DRAFT.MutableContents']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.FileTransfer', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.ContentHashType', u'org.freedesktop.Telepathy.Channel.TargetHandle', u'org.freedesktop.Telepathy.Channel.TargetID', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.ContentType', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.Filename', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.Size', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.ContentHash', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.Description', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.Date'])]}
If the test user connects with Gabble master instead (and so have the same version as me), I trust the URI and GetContactCapabilities() returns the right caps.
{26L: [({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.Text', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.TargetHandle']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.StreamTube', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L, u'org.freedesktop.Telepathy.Channel.Type.StreamTube.Service': u'rfb'}, [u'org.freedesktop.Telepathy.Channel.TargetHandle', u'org.freedesktop.Telepathy.Channel.TargetID']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.StreamTube', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L, u'org.freedesktop.Telepathy.Channel.Type.StreamTube.Service': u'x-wormux'}, [u'org.freedesktop.Telepathy.Channel.TargetHandle', u'org.freedesktop.Telepathy.Channel.TargetID']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.StreamTube', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.TargetHandle', u'org.freedesktop.Telepathy.Channel.TargetID', u'org.freedesktop.Telepathy.Channel.Type.StreamTube.Service']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.DBusTube', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.TargetHandle', u'org.freedesktop.Telepathy.Channel.TargetID', u'org.freedesktop.Telepathy.Channel.Type.DBusTube.ServiceName']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.StreamedMedia', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.Type.StreamedMedia.InitialAudio', u'org.freedesktop.Telepathy.Channel.Type.StreamedMedia.InitialVideo']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.Call.DRAFT', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.Type.Call.DRAFT.InitialAudio', u'org.freedesktop.Telepathy.Channel.Type.Call.DRAFT.InitialVideo', u'org.freedesktop.Telepathy.Channel.Type.Call.DRAFT.MutableContents']), ({u'org.freedesktop.Telepathy.Channel.ChannelType': u'org.freedesktop.Telepathy.Channel.Type.FileTransfer', u'org.freedesktop.Telepathy.Channel.TargetHandleType': 1L}, [u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.ContentHashType', u'org.freedesktop.Telepathy.Channel.TargetHandle', u'org.freedesktop.Telepathy.Channel.TargetID', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.ContentType', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.Filename', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.Size', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.ContentHash', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.Description', u'org.freedesktop.Telepathy.Channel.Type.FileTransfer.Date'])]}
See in attachment the log of these 2 scenarios.
Attachment 32704, "log when test user is connecting using Gabble 0.8.9":
caps.log