Message71554
== Summary ==
Installers made by bdist_wininst never set EstimatedSize in the Windows
registry. So Windows makes an estimate[1] of the installed software's
size so the Add/Remove Programs control panel can tell users how much
space the software is are taking up. Windows overestimates the size:
it estimates the size as equal to the size of the entire C:\Python
directory.
Nowadays, disk space is cheaper than ever, so I assume it's uncommon
for people to try to uninstall software to gain space back. So I do
not think it's worth fixing this bug. Does anyone think it *is* worth
fixing?
== Steps to repro ==
You *must* be running Windows XP or higher to repro this.[2] I used
Python 2.5 (which I installed using the MSI installer) but I would be
extremely surprised if this was already fixed in a newer Python's
distutils.
- Download the attached testcase.zip
- Unzip it to a temp directory
- From the temp directory, run the commands:
setup.py bdist_wininst
cd dist
foo-1.0.win32.exe
- Click on Start Menu > Settings > Control Panel > Add/Remove Programs
- Scroll down to "Python 2.5 foo-1.0".
== Actual results ==
- The "Size" column on the right says 46.86MB (that's the size of my
entire "C:\Python 2.5" directory.)
== Expected results ==
- The "Size" column on the right should say something close to 0.1
megabytes.
== Suggested fix ==
- When creating an installer, bdist_wininst should look at the total
size of all files to install, multiply that number by 3 (a reasonable
estimate of the total size the .pyc and .pyo files will take up), and
make the installer set the EstimatedSize[3] in the registry to that
number.
== Footnotes ==
^ [1]. See the blog entry "How does Add/Remove Programs get the size
and other information?" by Raymond Chen at
http://blogs.msdn.com/oldnewthing/archive/2004/07/09/178342.aspx for
info on the algorithm Windows uses.
^ [2]. Versions of Windows older than XP never try to estimate the
size of installed programs.
^ [3]. This is
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\(application
descriptor)\EstimatedSize and should be a DWORD representing the number
of kilobytes the software takes up, according to
http://forum.installsite.net/?showtopic=698#entry12501 |
|
Date |
User |
Action |
Args |
2008-08-20 16:14:10 | jasonspiro | set | recipients:
+ jasonspiro |
2008-08-20 16:14:10 | jasonspiro | set | messageid: <1219248850.4.0.277642755083.issue3621@psf.upfronthosting.co.za> |
2008-08-20 16:14:09 | jasonspiro | link | issue3621 messages |
2008-08-20 16:14:07 | jasonspiro | create | |
|