kylejginavan / youtube_it

An object-oriented Ruby wrapper for the YouTube GData API
http://groups.google.com/group/ruby-youtube-library
595 stars 223 forks source link

Problem with YouTubeIt::Upload::AuthenticationError #15

Closed alexis closed 13 years ago

alexis commented 13 years ago

Hi, Kyle!

So, here's the problem. When youtube responses me with something like:

<errors xmlns='http://schemas.google.com/g/2005'><error><domain>GData</domain><code>ServiceForbiddenException</code><internalReason>Not an owner of the video</internalReason></error></errors>

or this:

<?xml version='1.0' encoding='UTF-8'?><errors><error><domain>yt:quota</domain><code>too_many_recent_calls</code></error></errors>

then youtube_it parsed the response with:

raise AuthenticationError, response.body[/<TITLE>(.+)<\/TITLE>/, 1]

(https://github.com/kylejginavan/youtube_it/blob/00378b40/lib/youtube_it/request/video_upload.rb#L488)

Which of course didn't work.

I hope my fix will be of some help. Thanks!

kylejginavan commented 13 years ago

merged and released