Skip to content

patool dislikes tricky filenames #3769

@yarikoptic

Description

@yarikoptic

edit: bug in cPython: https://bugs.python.org/issue38449

While test building 0.11.8 for debian sid, build failed with a number of tests failing with the same error from patool (patoolib=1.12):

======================================================================
ERROR: datalad.tests.test_archives.test_ExtractedArchive
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/build/datalad-0.11.8/.pybuild/cpython3_3.7_datalad/build/datalad/tests/utils.py", line 440, in newfunc
    create_tree(d, tree, archives_leading_dir=archives_leading_dir)
  File "/build/datalad-0.11.8/.pybuild/cpython3_3.7_datalad/build/datalad/utils.py", line 2248, in create_tree
    archives_leading_dir=archives_leading_dir)
  File "/build/datalad-0.11.8/.pybuild/cpython3_3.7_datalad/build/datalad/utils.py", line 2211, in create_tree_archive
    compress_files([dirname], name, path=path, overwrite=overwrite)
  File "/build/datalad-0.11.8/.pybuild/cpython3_3.7_datalad/build/datalad/support/archives.py", line 251, in compress_files
    verbosity=100)
  File "/usr/lib/python3/dist-packages/patoolib/__init__.py", line 505, in _create_archive
    format, compression = get_archive_format(archive)
  File "/usr/lib/python3/dist-packages/patoolib/__init__.py", line 293, in get_archive_format
    raise util.PatoolError("unknown archive format for file `%s'" % filename)
patoolib.util.PatoolError: unknown archive format for file ` "';b&b&c `| .tar.gz'

I do not remember us changing any of those tests since last release but previous release of patool used for building 0.11.7 where no failures happened was also 0.12 (checked -- debian revision was 0.12-3 in both cases).

neurodebian@smaug ~/deb/builds/datalad/0.11.7-1 % grep test_ExtractedArchive datalad_0.11.7-1_amd64.build
datalad.tests.test_archives.test_ExtractedArchive ... ok

So I have no immediate idea and it would need some digging.

edit: also doesn't reproduce for me locally

Metadata

Metadata

Assignees

No one assigned

    Labels

    regressionseverity-minora problem which doesn't affect the package's usefulness, and is presumably trivial to fix

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions