wintermute123 / youtube-upload

Automatically exported from code.google.com/p/youtube-upload
0 stars 0 forks source link

ImportError: No module named expat; use SimpleXMLTreeBuilder instead #91

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
= Versions

youtube-upload: 0.7.1
python: 2.7
python-gdata: 2.0.17

= Describe the steps (including the command you run) that will reproduce
the problem?

python youtube-upload --email=myoutubeaccname@gmail.com 
--password=mypasswordhere --title="Cim" --description="$(< description.txt)" 
--category=Game --keywords="keywords" filename.mpg

If i run this command i geting error:

Login to Youtube API: email='mgtmultigaming@gmail.com', password='***********'
Traceback (most recent call last):
  File "youtube-upload", line 448, in <module>
    sys.exit(catch_exceptions(EXIT_CODES, main_upload, sys.argv[1:]))
  File "youtube-upload", line 104, in catch_exceptions
    fun(*args, **kwargs)
  File "youtube-upload", line 380, in main_upload
    captcha_response=options.captcha_response)
  File "youtube-upload", line 181, in login
    self.service.ProgrammaticLogin(captcha_token, captcha_response)
  File "/mnt/programs/usr/lib/python2.7/site-packages/gdata/service.py", line 771, in ProgrammaticLogin
    headers={'Content-Type':'application/x-www-form-urlencoded'})
  File "/mnt/programs/usr/lib/python2.7/site-packages/atom/http.py", line 132, in request
    connection = self._prepare_connection(url, all_headers)
  File "/mnt/programs/usr/lib/python2.7/site-packages/atom/http.py", line 214, in _prepare_connection
    return HttpClient._prepare_connection(self, url, headers)
  File "/mnt/programs/usr/lib/python2.7/site-packages/atom/http.py", line 185, in _prepare_connection
    return httplib.HTTPSConnection(url.host)
AttributeError: 'module' object has no attribute 'HTTPSConnection'

Im try to run this script, on my openwrt router. Any ide what is the problem?

Original issue reported on code.google.com by batta.da...@gmail.com on 3 Jan 2013 at 11:44

GoogleCodeExporter commented 8 years ago
Note that the error of the summary does not match the error in the traceback.

I had never seen this, google a bit and report back if you know how to solve it:

http://goo.gl/nZtXH
https://forum.openwrt.org/viewtopic.php?id=33622

Original comment by tokland on 3 Jan 2013 at 12:01

GoogleCodeExporter commented 8 years ago
Ok i solve the problem, i just need install python-openssl.

opkg install python-openssl

But now i have another problem: 

Login to Youtube API: email='mgtmultigaming@gmail.com', password='***********'
Traceback (most recent call last):
  File "youtube-upload", line 448, in <module>
    sys.exit(catch_exceptions(EXIT_CODES, main_upload, sys.argv[1:]))
  File "youtube-upload", line 104, in catch_exceptions
    fun(*args, **kwargs)
  File "youtube-upload", line 380, in main_upload
    captcha_response=options.captcha_response)
  File "youtube-upload", line 182, in login
    self.categories = self.get_categories()
  File "youtube-upload", line 254, in get_categories
    xml = ElementTree.XML(xmldata)
  File "/mnt/programs/usr/lib/python2.7/xml/etree/ElementTree.py", line 1300, in XML
    parser = XMLParser(target=TreeBuilder())
  File "/mnt/programs/usr/lib/python2.7/xml/etree/ElementTree.py", line 1466, in __init__
    "No module named expat; use SimpleXMLTreeBuilder instead"
ImportError: No module named expat; use SimpleXMLTreeBuilder instead

Original comment by batta.da...@gmail.com on 3 Jan 2013 at 7:47

GoogleCodeExporter commented 8 years ago
> ImportError: No module named expat; use SimpleXMLTreeBuilder instead

I have no idea, did you google the error?

Original comment by tokland on 3 Jan 2013 at 7:53

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Ok i solve the problem i just need to install: 

opkg install python-openssl
opkg install python-expat

But do not install "python-curl" im geting error with it!

Original comment by batta.da...@gmail.com on 3 Jan 2013 at 8:01

GoogleCodeExporter commented 8 years ago
Ok, good to know for other openwrt users.

Original comment by tokland on 3 Jan 2013 at 8:02

GoogleCodeExporter commented 8 years ago

Original comment by tokland on 3 Jan 2013 at 8:03

GoogleCodeExporter commented 8 years ago

Original comment by tokland on 13 May 2014 at 2:55