Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using an AVPlayer returns a "non-Multipath connection" error

I'm using AVKit to play a youtube URL.

I have this code inside a button action:

 @IBAction func trailerButtonAction(_ sender: Any) {
    guard let youtubeUrl = youtubeURL else { return }
    let player = AVPlayer(url: youtubeUrl)
    let playerViewController = AVPlayerViewController()
    playerViewController.player = player

    present(playerViewController, animated: true) {
        player.play()
    }
}

The URL is valid, but when I press the button, the video doesn't stop loading and I'm getting this message on Debug area:

nw_endpoint_flow_copy_multipath_subflow_counts Called on non-Multipath connection

Edit:

I found that AVPlayer doesn't support youtube URL

like image 680
Alex Giatrakis Avatar asked Oct 17 '19 11:10

Alex Giatrakis


1 Answers

I would say this log isn't necessarily relevant. I was getting this error when trying to playback on the simulator but it wasn't happening on a real device.

like image 164
CMash Avatar answered Sep 18 '22 13:09

CMash