Forums

'pip install pyside' error

I got error message when i tried to install pyside in my virtualenv. Please, help me.

 (flask)14:16 ~$ pip install pyside
    Collecting pyside
    Exception:
    Traceback (most recent call last):
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/basecommand.py", line 223, in main
        status = self.run(options, args)
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/commands/install.py", line 293, in run
        wb.build(autobuilding=True)
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/wheel.py", line 705, in build
        self.requirement_set.prepare_files(self.finder)
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/req/req_set.py", line 334, in prepare_files
        functools.partial(self._prepare_file, finder))
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/req/req_set.py", line 321, in _walk_req_to_install
        more_reqs = handler(req_to_install)
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/req/req_set.py", line 491, in _prepare_file
        session=self.session)
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/download.py", line 814, in unpack_url
        unpack_file_url(link, location, download_dir)
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/download.py", line 723, in unpack_file_url
        unpack_file(from_path, location, content_type, link)
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/utils/__init__.py", line 644, in unpack_file
        flatten=not filename.endswith('.whl')
      File "/home/partrita/.virtualenvs/flask/local/lib/python2.7/site-packages/pip/utils/__init__.py", line 530, in unzip_file
        zip = zipfile.ZipFile(zipfp, allowZip64=True)
      File "/usr/lib/python2.7/zipfile.py", line 770, in __init__
        self._RealGetContents()
      File "/usr/lib/python2.7/zipfile.py", line 811, in _RealGetContents
        raise BadZipfile, "File is not a zip file"
    BadZipfile: File is not a zip file

I google it but can't find solution.

It looks to me like that may have been because a server gave you an error page instead of the tar archive that the installation needed. Try again and maybe the server will be in a better state.

By the way, I'm not sure that installing pyside will be any use. We are a remote server based environment so any of the GUI stuff in pyside will not work, though the other features may.