Slide 8
Slide 8 text
Zip files and zipapps
Zip files and zipapps
pkg = Path(thepkg.__file__).parent
path = pkg / 'data' / 'sample.dat'
with open(path, 'rb') as fp:
contents = fp.read()
Traceback (most recent call last):
File "run.py", line 7, in
with open(path, 'rb') as fp:
NotADirectoryError: [Errno 20] Not a directory:
'.../thepkg.zip/thepkg/data/sample.dat'