segfault using shutil.make_archive

Random832 random832 at fastmail.com
Thu Oct 6 14:04:01 EDT 2016


On Thu, Oct 6, 2016, at 13:45, Random832 wrote:
> On Thu, Oct 6, 2016, at 12:46, Tim wrote:
> > I need to zip up a directory that's about 400mb.
> > I'm using shutil.make_archive and I'm getting this response:
> > 
> >     Segmentation fault: 11 (core dumped)
> > 
> > The code is straightforward (and works on other, smaller dirs):
> 
> Are you able to make a test case that reproduces it reliably without any
> specifics about what data you are using (e.g. can you generate a
> directory full of blank [or /dev/urandom if the compressed size is a
> factor] files that causes this)? Is it a large number of files or a
> large total size of files?

Also consider passing a logging object to make_archive and see if it
prints out anything interesting before the segfault.

import shutil
import logging
import sys
logger = logging.getLogger()
logger.setLevel(logging.DEBUG)
logger.addHandler(logging.StreamHandler(sys.stderr))
shutil.make_archive(..., logger=logger)



More information about the Python-list mailing list