WHIP stream fails due to mandatory stream query parameter and URL encoding issues
ODAncona opened this issue · 0 comments
XIU version : v0.13.0
Describe the bug
Hi @harlanc,
I'm experiencing issues while trying to use WHIP with Xiu. I use whipclientsink gstreamer plugin of the gst-plugins-rs repo and I'm unable to use whip with Xiu as well. The required stream parameter forces the character & in the url app=app&stream=stream
. However, whipclientsink
doesn't handle the character & and I need to encode it as %26. However, xiu is unable to decode it.
To Reproduce
On a first terminal, launching xiu
$ xiu -w 8900
[2024-11-19T04:27:43Z INFO xwebrtc::webrtc] WebRTC server listening on tcp://0.0.0.0:8900
[2024-11-19T04:27:43Z INFO xiu::api] Http api server listening on http://0.0.0.0:8000
On another terminal, starting a gstreamer pipeline that sends a whip stream
$ gst-launch-1.0 videotestsrc ! video/x-raw,format=YUY2,width=1920,height=1200,framerate=30/1 \
! queue \
! videoconvert ! video/x-raw,format=I420 \
! queue \
! x264enc speed-preset=ultrafast bitrate=2000 \
! queue \
! video/x-h264,profile=baseline \
! whipclientsink signaller::whip-endpoint=http://localhost:8900/whip?app=live%26stream=test
After adding a debug line I found
[2024-11-19T05:02:25Z ERROR xwebrtc::session] WebRTCServerSession::run the http path is not correct: Uri { schema: WEBRTC, host: "", port: None, path: "/whip", query: Some("app=live%26stream=test") }
Expected behavior
The server should accept valid WHIP streams without imposing unnecessary parameter constraints.