-
Notifications
You must be signed in to change notification settings - Fork 25
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
Uploading videos fails #178
Comments
Thank you for taking the time to file such a detailed writeup, We actually just released (2 days ago) a new upload library that will replace this one: https://github.com/vimeo/VimeoUpload I highly recommend you use VimeoUpload as we are no longer supporting or using VIMUpload. From what you describe above the issue seems related to cert pinning. Can you confirm that the cert is included properly in your project and that you're properly pinning against it. Or, can you confirm that you're not cert pinning and still seeing this issue? |
Hi! I am not cert pinning. As i explained above the problem has nothing to do with SSL. After i traced the calls down i see that simply the url which VimeoUpload is trying to open is missing (404). Although cocoa returns an SSL error - it's caused exactly because of this 404. Have a look at the above second screenshot i've uploaded - this url - when opened (while the breakpoint is on there) returns a 404. I'll have a look at VimeoUpload tomorrow. I guess hardcoding the tokens is also a choice with it right? Because this is our idea - to use Vimeo as a cloud storage service / player / VimeoPro :) |
Hey @miraclebg, VIMUpload needs to make 4 separate requests in sequence in order to perform an upload. It looks like the first request is succeeding. This is the request that gets an upload ticket. The upload ticket contains the url that you upload the video file to. It sounds like the second request, the one that uploads the video file, is failing. I see the error that you're printing but it's hard to debug without additional context. Can you provide more info on the upload ticket object's properties, and the specific location in VIMUpload where the error is being thrown (as opposed to the location from within AFNetworking - current screenshot). Neither screenshot shows info on the http status code etc, that info would be helpful too. Have you tried loading the file upload url in the browser? Does it give you a 404 as well? Thanks |
Haven't got the chance to test out VimeoUpload yet but i am answering on your previous question. The url which is failing is this - just got it while debugging: https://1511923892.cloud.vimeo.com/upload?ticket_id=485ed01b33a084a847b1f1bf36fa327a&video_file_id=498691779&signature=4747a5ea28fbe5463972f6f7544245ba&v6=1 It returns 404 - Not Found. This is as you said - one of the requests which VIMUpload is making. Before this request - the previous one also fails - but without any error (or just AFNetworking is not parsing it properly - the error delegate method is called with a nil NSError). I am attaching the entire sample test project i am testing with. Please ignore / close your eyes when you see how the video is obtained :) This is something quick - a hack if you must just to see how Vimeo works so we can continue and integrate it normally in the real app. You will need to run this in a simulator and upload a sample video before that to the simulator. I am also attaching the same video here. Breakpoints are also in and enabled. Token is hardcoded and in there too - it's a trial account expiring soon so .. no problem. Hope this is enough :) If not - shoot out :) https://www.dropbox.com/s/yled8f5pkg6hcbg/VimeoVideos.zip?dl=0 |
The sample video. |
Issue Summary
I am not able to upload videos in an IOS prepared sample app using the Vimeo iOS SDK.
Reproduction Steps
Expected Behavior
My expectations were to receive a successful response after making the API calls.
Actual Behavior
Hello there!
We are experiencing some issues while trying to integrate the Vimeo iOS SDK parts.
Currently i've created a simple demo to see how everything works and to make sure i understand how it all works.
The setup is CocoaPods including the following projects:
OAuth2 is NOT used - i am hardcoding the access tokens (this is what is necessary).
Authenticating and fetching video information works fine - no questions here.
But the problem is with uploads - they always fail.
I've spent quite some time to dig into what is happening as there is no obvious error being shown.
At the end what i realized is that right now i am trying to upload 1 MP4 video and i see 2 network requests made through AFNetworking - one after another.
What is strange is that the first network request fails - without any errors when stopped at the debugger (https://www.dropbox.com/s/a4hukteeo9yark3/First%20error.png?dl=0).
It lands at the error delegate method but the error is nil. I think this method is the one responsible to allocate TICKETS.
The second call which i see also fails - but it does return an error - it says there is an SSL error although this is probably something else as i see your server returns 404 Not Found and i guess AFNetworking is getting confused somewhere about this.
Why is this URL missing? Is it because the first call failed and the TICKET session was not properly obtained? (Screenshot of the second error: https://www.dropbox.com/s/lw410mpcvak6olo/Second%20error.png?dl=0)
PS: iOS App Transport Security Settings is properly setup.
What we want at the end of the day is to upload and play videos with a hardcoded access token in both our iOS and Android apps using your PRO service.
I would be glad if you can help out as i've spent several hours on this and whatever i try - nothing works.
And a few other questions - after we get this working:
The text was updated successfully, but these errors were encountered: