-
-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue: Socket Not Connected Error During Video Processing #70
Comments
Can you send the sample code you use to get the streams? Are you using remote only? |
Hi @alexeichhorn func start(_ url: URL, theChat: ChatSD) {
currentState = .downloading
currentConversation = theConversation
Task {
do {
try await swiftDataService.updateChatState(theChat, to: .youtubeDownloading)
let video = try await YouTube(url: url, methods: [.local, .remote])
guard let audioStream = try await video
.streams
.filterAudioOnly()
.filter({ $0.fileExtension == .m4a })
.lowestAudioBitrateStream()
else {
throw NSError(domain: "YouTubeTranscription", code: 1, userInfo: [
NSLocalizedDescriptionKey: "No suitable audio stream found",
])
}
// Get audio URL
let audioURL = audioStream.url
// ... so the
was not able to get the audioStream, so the NSError got thrown, any clue thanks ? |
@alexeichhorn an update, I noticed that if I removed the |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Issue: Socket Not Connected Error Causing Download Failures
Description
Hi YouTubeKit team, first of all, thanks for putting this amazing project together—it’s great!
I’ve noticed constant download failures recently. The issue often comes with an error indicating that an error occurs when processing YouTube videos using YouTubeKit. The operation fails due to a “Socket is not connected” error, leading to download failures.
Steps to Reproduce
Error Logs
Here are the detailed logs for reference:
Expected Behavior
The video should be processed/downloaded without encountering any errors.
Actual Behavior
The operation fails with a "Socket is not connected" error, and the download is not completed.
Environment
Thank you for looking into this issue! Let me know if you need more information or additional logs.
The text was updated successfully, but these errors were encountered: