difficult zipefile Question

Michael Hoffman m.h.3.9.1.without.dots.at.cam.ac.uk at example.com
Wed Oct 6 19:01:07 EDT 2004


matthiasjanes wrote:
> def zipit(path, ziper):
> 
>   for root, dirs, files in os.walk(path):
> 
>     for anyFile in files:
> 
>       fullname = os.path.join(root, anyFile)

Where is the "ziper" variable used? I don't see how this code does 
anything except create an empty zipfile.

$ python samplecode.py

$ unzip test.zip
Archive:  test.zip
warning [test.zip]:  zipfile is empty

If you Google for <zipfile empty> you will find a python-list thread 
with this solution in it:

http://mail.python.org/pipermail/python-list/2003-June/170526.html

Alternatively you could submit a patch or a bug.

HTH,
-- 
Michael Hoffman



More information about the Python-list mailing list