Issues

Issue #138 resolved

zipimport.ZipImportError: bad local file header

Ralf Stephan
created an issue

Please invalid if already known. Any idea before I start a full upgrade ticket for Sage?

Installed /scratch/sage/local/lib/python2.7/site-packages/setuptools-2.0.1-py2. 7.egg Processing dependencies for setuptools==2.0.1 Traceback (most recent call last): File "setup.py", line 200, in <module> dist = setuptools.setup(**setup_params) File "/scratch/sage/local/lib/python2.7/distutils/core.py", line 152, in setu p dist.run_commands() File "/scratch/sage/local/lib/python2.7/distutils/dist.py", line 953, in run_ commands self.run_command(cmd) File "/scratch/sage/local/lib/python2.7/distutils/dist.py", line 972, in run_ command cmd_obj.run() File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2 .0.1.p0/src/setuptools/command/install.py", line 73, in run self.do_egg_install() File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2 .0.1.p0/src/setuptools/command/install.py", line 101, in do_egg_install cmd.run() File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2 .0.1.p0/src/setuptools/command/easy_install.py", line 359, in run self.easy_install(spec, not self.no_deps) File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2 .0.1.p0/src/setuptools/command/easy_install.py", line 575, in easy_install return self.install_item(None, spec, tmpdir, deps, True) File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2 .0.1.p0/src/setuptools/command/easy_install.py", line 626, in install_item self.process_distribution(spec, dist, deps) File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2 .0.1.p0/src/setuptools/command/easy_install.py", line 672, in process_distribut ion [requirement], self.local_index, self.easy_install File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2 .0.1.p0/src/pkg_resources.py", line 576, in resolve requirements.extend(dist.requires(req.extras)[::-1]) File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2 .0.1.p0/src/pkg_resources.py", line 2224, in requires dm = self._dep_map File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2.0.1.p0/src/pkg_resources.py", line 2209, in _dep_map for extra,reqs in split_sections(self._get_metadata(name)): File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2.0.1.p0/src/pkg_resources.py", line 2650, in split_sections for line in yield_lines(s): File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2.0.1.p0/src/pkg_resources.py", line 1910, in yield_lines for ss in strs: File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2.0.1.p0/src/pkg_resources.py", line 2238, in _get_metadata for line in self.get_metadata_lines(name): File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2.0.1.p0/src/pkg_resources.py", line 1300, in get_metadata_lines return yield_lines(self.get_metadata(name)) File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2.0.1.p0/src/pkg_resources.py", line 1292, in get_metadata return self._get(self._fn(self.egg_info,name)) File "/tmp/tmpDH6Cyy-sage-git-temp-2516/local/var/tmp/sage/build/setuptools-2.0.1.p0/src/pkg_resources.py", line 1356, in _get return self.loader.get_data(path) zipimport.ZipImportError: bad local file header in /scratch/sage/local/lib/python2.7/site-packages/setuptools-2.0.1-py2.7.egg

Comments (5)

  1. Richard Jones

    It looks to me like /scratch/sage/local/lib/python2.7/site-packages/setuptools-2.0.1-py2.7.egg might be corrupted. Perhaps try forcing a reinstall of setuptools?

  2. Ralf Stephan reporter

    This happens frequently during automatic installation of Sage (sagemath.org) which is done by its test robot. The investigation in the cause has just started. So thanks for your opinion, it helps, but it would be awkward to change the testbot to check for that error and restart installation for it might lead to an infinite loop.

    It does not appear during normal installation. OTOH, all is done is to run this script: https://github.com/sagemath/sage/blob/master/build/pkgs/setuptools/spkg-install so the culprit could be found.

  3. Log in to comment