Open GoogleCodeExporter opened 9 years ago
I see the same behavior in my application.
gdata is looking for a attribute len which it does not find and gives an
Attribute Error.
text='Education',
label='Education')],
)
extension = ExtensionElement('accessControl', namespace=YOUTUBE_NAMESPACE, attributes={'action': 'list', 'permission': 'denied'})
video_entry = gdata.youtube.YouTubeVideoEntry(media=my_media_group, extension_elements=[extension])
entry = yt_service.InsertVideoEntry(video_entry, video.file)
...
▶ Local vars
/home/quietrags/lib/python2.7/gdata/youtube/service.py in InsertVideoEntry
if hasattr(filename_or_handle, 'seek'):
filename_or_handle.seek(0)
file_handle = filename_or_handle
name = 'video'
if hasattr(filename_or_handle, 'name'):
name = filename_or_handle.name
mediasource = gdata.MediaSource(file_handle, content_type,
content_length=file_handle.len, file_name=name)
else:
raise YouTubeError({'status':YOUTUBE_INVALID_ARGUMENT, 'body':
'`filename_or_handle` must be a path name or a file-like object',
'reason': ('Found %s, not path name or object '
'with a .read() method' % type(filename_or_handle))})
upload_uri = '%s/%s/%s' % (YOUTUBE_UPLOAD_URI, youtube_username,
Original comment by quietr...@gmail.com
on 25 Oct 2012 at 4:38
Original issue reported on code.google.com by
m...@fogel.ca
on 10 Apr 2012 at 11:58