3 ms·
On my system right now: % du -h --exclude=site-packages /usr/lib/python3.10 | tail -n1 41M /usr/lib/python3.10 The amount of savings seems to be about
by Beltalowda 5y ago
On my system right now:
% du -h --exclude=site-packages /usr/lib/python3.10 | tail -n1
41M /usr/lib/python3.10
The amount of savings seems to be about 0.83M:
% ls -l \
**/*aifc* \
**/*asynchat* \
**/*asyncore* \ \
**/*cgi* \
**/*cgitb* \
**/*chunk* \
**/*crypt* \
**/*imghdr* \
**/*nntplib* \
**/*ossaudiodev* \
**/*pipes* \
**/*smtpd* \
**/*sndhdr* \
**/*spwd* \
**/*sunau* \
**/*telnetlib* \
**/*uu* \
**/*xdrlib* |
awk '{ print $5 }' | paste -sd+ | bc
877283
This excludes the "msilib" and "nis" packages, which aren't on my system (I guess my distro excludes them?), and you should also really round up the files to the disk block size (usually 4k), so let's round it up to 1M.
Is that significant? You decide. It doesn't seem all that significant to me given that the stdlib is 41M, so for space-constrained use-cases you're still not going to be able to copy/install all of the stdlib in the first place as it's still not even close to fitting on "devices with just a few hundred kilobyte of storage (e.g. BBC Micro:bit)" that the PEP mentions.
I do think that removing these packages is a good idea, but "space savings" seems like a very weak argument.
- loeg 5y agomsilib and nis are probably Windows-only.
- Someone 5y ago> you should also really round up the files to the disk block size (usually 4k), so let's round it up to 1M. A decent first-go model for the amount of bytes to add is half a block per file. You’re adding about 168kB. That model would predict that for 84 files. I guess there are quite a few more in those (at least) 18 directories.