Failed to set remote offer sdp: Failed to set remote video description streams for m-section with mid='video'

Hi Everyone,

I am integrating Jitsi Client in an Android Application by using native google-webrtc instead of using the lib-jitsi-meet.

I have done the signalling using XMPP and Web-Socket as done by lib-jitsi-meet. Everything seem to be working good except sometimes randomly out of the blue I receive below error while trying to update the remote SDP Offer Description of PeerConnection on receiving “source-add”:
Failed to set remote offer sdp: Failed to set remote video description streams for m-section with mid='video'.

This causes remote video track to show black and It connects successfully if I do a reconnect on android end but in this case I notice that remote video track’s suffix gets changed from -1 to -2. For ex. During first failed connect, if I was receiving track: 19a50454-aa29-4f3c-8c90-3843fb543db1-1, then in case of reconnect I would receive the same video track but suffix would change to -2 i.e. 19a50454-aa29-4f3c-8c90-3843fb543db1-2.

This tells me that issue might be related to simulcast but not sure why it only happen 5% of the times randomly.

Sometimes doing a reconnect on Android end does not change the track to -2 and I keep on getting the black stream until the track changes to -2 on multiple reconnects.

Environment Details:

  • Client facing the issue is on Android Application using Native google-webrtc with no support for simulcast.
  • Remote Client is on Google Chrome using the jitsi-meet-lib with simulcast enabled.
  • It is not a 1:1 call but a conference call.

Here is the SDP Offer received from the remote Client (Google Chrome):

v=0
o=- 1625066868930 2 IN IP4 127.0.0.1
s=-
t=0 0
a=group:BUNDLE audio video data
a=msid-semantic: WMS 20ab08c5-7afb-4f5b-9dcf-641bfcb5ee25 4776c688-4224-4960-8796-97a14b766933-1 6315be8d-3ac2-421a-bc91-e82d6c08dda8 mixedmslabel
m=audio 10000 RTP/SAVPF 111 103 104 126
c=IN IP4 13.248.179.188
a=rtcp:9 IN IP4 0.0.0.0
a=candidate:1 1 udp 2130706431 10.0.0.145 10000 typ host generation 0
a=candidate:2 1 udp 1694498815 13.248.179.188 10000 typ srflx raddr 10.0.0.145 rport 10000 generation 0
a=ice-ufrag:7sfe61f9eoh36p
a=ice-pwd:5o8n1hb46684h1vpmirfi5516i
a=fingerprint:sha-256 4E:5D:D6:E5:4F:66:59:EF:60:80:EC:3B:D4:88:D7:E6:06:ED:48:62:1E:DB:E6:9F:FD:91:15:1C:5A:35:54:74
a=setup:actpass
a=mid:audio
a=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level
a=sendrecv
a=rtcp-mux
a=rtpmap:111 opus/48000/2
a=fmtp:111 minptime=10;useinbandfec=1
a=rtpmap:103 ISAC/16000
a=rtpmap:104 ISAC/32000
a=rtpmap:126 telephone-event/8000
a=ssrc:2391343741 cname:mixed
a=ssrc:2391343741 msid:mixedmslabel mixedlabelaudio0
a=ssrc:2391343741 mslabel:mixedmslabel
a=ssrc:2391343741 label:mixedlabelaudio0
a=ssrc:2268147241 cname:gSCPFWkAGjFyT2Y
a=ssrc:2268147241 msid:6315be8d-3ac2-421a-bc91-e82d6c08dda8 ssp-5a97bffc-ce86-4984-a27f-f17c45bb228e
a=ssrc:2268147241 mslabel:6315be8d-3ac2-421a-bc91-e82d6c08dda8
a=ssrc:2268147241 label:ssp-5a97bffc-ce86-4984-a27f-f17c45bb228e
a=ssrc:3639365784 cname:yOSpJxNgHNkbijcW-1
a=ssrc:3639365784 msid:4776c688-4224-4960-8796-97a14b766933-1 ab562f8d-8651-4a18-91f6-f9d6f3e63516-1
a=ssrc:3639365784 mslabel:4776c688-4224-4960-8796-97a14b766933-1
a=ssrc:3639365784 label:ab562f8d-8651-4a18-91f6-f9d6f3e63516-1
m=video 10000 RTP/SAVPF 107 100 101 96 97 99
c=IN IP4 13.248.179.188
a=rtcp:9 IN IP4 0.0.0.0
a=candidate:1 1 udp 2130706431 10.0.0.145 10000 typ host generation 0
a=candidate:2 1 udp 1694498815 13.248.179.188 10000 typ srflx raddr 10.0.0.145 rport 10000 generation 0
a=ice-ufrag:7sfe61f9eoh36p
a=ice-pwd:5o8n1hb46684h1vpmirfi5516i
a=fingerprint:sha-256 4E:5D:D6:E5:4F:66:59:EF:60:80:EC:3B:D4:88:D7:E6:06:ED:48:62:1E:DB:E6:9F:FD:91:15:1C:5A:35:54:74
a=setup:actpass
a=mid:video
a=extmap:3 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time
a=sendrecv
a=rtcp-mux
a=rtpmap:107 H264/90000
a=rtcp-fb:107 ccm fir
a=rtcp-fb:107 nack
a=rtcp-fb:107 nack pli
a=fmtp:107 ;level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=42e01f;x-google-start-bitrate=800
a=rtpmap:100 VP8/90000
a=rtcp-fb:100 ccm fir
a=rtcp-fb:100 nack
a=rtcp-fb:100 nack pli
a=fmtp:100 x-google-start-bitrate=800
a=rtpmap:101 VP9/90000
a=rtcp-fb:101 ccm fir
a=rtcp-fb:101 nack
a=rtcp-fb:101 nack pli
a=fmtp:101 x-google-start-bitrate=800
a=rtpmap:96 rtx/90000
a=rtcp-fb:96 ccm fir
a=rtcp-fb:96 nack
a=rtcp-fb:96 nack pli
a=fmtp:96 apt=100
a=rtpmap:97 rtx/90000
a=fmtp:97 apt=101
a=rtpmap:99 rtx/90000
a=fmtp:99 apt=107
a=ssrc:49537967 cname:mixed
a=ssrc:49537967 msid:mixedmslabel mixedlabelvideo0
a=ssrc:49537967 mslabel:mixedmslabel
a=ssrc:49537967 label:mixedlabelvideo0
a=ssrc-group:FID 1860934305 3540357459
a=ssrc:1860934305 cname:gSCPFWkAGjFyT2Y
a=ssrc:1860934305 msid:20ab08c5-7afb-4f5b-9dcf-641bfcb5ee25 22426081-06b6-4e4d-b297-eda70fc76b11
a=ssrc:1860934305 mslabel:20ab08c5-7afb-4f5b-9dcf-641bfcb5ee25
a=ssrc:1860934305 label:22426081-06b6-4e4d-b297-eda70fc76b11
a=ssrc:3540357459 cname:gSCPFWkAGjFyT2Y
a=ssrc:3540357459 msid:20ab08c5-7afb-4f5b-9dcf-641bfcb5ee25 22426081-06b6-4e4d-b297-eda70fc76b11
a=ssrc:3540357459 mslabel:20ab08c5-7afb-4f5b-9dcf-641bfcb5ee25
a=ssrc:3540357459 label:22426081-06b6-4e4d-b297-eda70fc76b11
a=ssrc-group:FID 4188803544 1967355454
a=ssrc-group:FID 4267808407 3009773730
a=ssrc-group:FID 503282428 2952353283
a=ssrc-group:SIM 4188803544 4267808407 503282428
a=ssrc:503282428 cname:yOSpJxNgHNkbijcW-1
a=ssrc:503282428 msid:496f9c4c-21b4-451f-aec5-6d878b698430-1 19a50454-aa29-4f3c-8c90-3843fb543db1-1
a=ssrc:1967355454 cname:yOSpJxNgHNkbijcW-1
a=ssrc:1967355454 msid:496f9c4c-21b4-451f-aec5-6d878b698430-1 19a50454-aa29-4f3c-8c90-3843fb543db1-1
a=ssrc:2952353283 cname:yOSpJxNgHNkbijcW-1
a=ssrc:2952353283 msid:496f9c4c-21b4-451f-aec5-6d878b698430-1 19a50454-aa29-4f3c-8c90-3843fb543db1-1
a=ssrc:3009773730 cname:yOSpJxNgHNkbijcW-1
a=ssrc:3009773730 msid:496f9c4c-21b4-451f-aec5-6d878b698430-1 19a50454-aa29-4f3c-8c90-3843fb543db1-1
a=ssrc:4188803544 cname:yOSpJxNgHNkbijcW-1
a=ssrc:4188803544 msid:496f9c4c-21b4-451f-aec5-6d878b698430-1 19a50454-aa29-4f3c-8c90-3843fb543db1-1
a=ssrc:4267808407 cname:yOSpJxNgHNkbijcW-1
a=ssrc:4267808407 msid:496f9c4c-21b4-451f-aec5-6d878b698430-1 19a50454-aa29-4f3c-8c90-3843fb543db1-1
m=application 10000 DTLS/SCTP 5000
c=IN IP4 13.248.179.188
a=candidate:1 1 udp 2130706431 10.0.0.145 10000 typ host generation 0
a=candidate:2 1 udp 1694498815 13.248.179.188 10000 typ srflx raddr 10.0.0.145 rport 10000 generation 0
a=ice-ufrag:7sfe61f9eoh36p
a=ice-pwd:5o8n1hb46684h1vpmirfi5516i
a=fingerprint:sha-256 4E:5D:D6:E5:4F:66:59:EF:60:80:EC:3B:D4:88:D7:E6:06:ED:48:62:1E:DB:E6:9F:FD:91:15:1C:5A:35:54:74
a=setup:actpass
a=mid:data
a=sctpmap:5000 webrtc-datachannel 1024

Could this be related to this JITSI feature?
New off-stage layer suppression feature

Issue was with the SDP Offer formatting order but was happening randomly. I fixed the order and I no longer face this issue.