Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.10.15

Bug #13691 Pear doesn't remove old directories on upgrade
Submitted: 2008-04-16 06:25 UTC
From: alexandertumanovsky Assigned: cellog
Status: Closed Package: PEAR (version 1.7.1)
PHP Version: 5.2.3 OS: Windows XP, Linux
Roadmaps: 1.7.2    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 50 - 14 = ?

 
 [2008-04-16 06:25 UTC] alexandertumanovsky (Alexander Tumanovsky)
Description: ------------ I've made two versions of a test package for this test case. First version: SamplePackage SamplePackage/admin1/1.php Second version: SamplePackage SamplePackage/admin2/2.php Test script: --------------- -------------------------------------------------- C:\pearTest>pear install SamplePackage-1.0.4snapshot1207834335.tar install ok: channel://__uri/SamplePackage-1.0.4snapshot1207834335 C:\php\PEAR\pear\SamplePackage>dir /s Directory of C:\php\PEAR\pear\SamplePackage 16.04.2008 09:04 <DIR> admin1 Directory of C:\php\PEAR\pear\SamplePackage\admin1 16.04.2008 09:04 66 1.php -------------------------------------------------- Upgrade: -------------------------------------------------- C:\pearTest>pear install SamplePackage-1.0.4snapshot1207834335.tar install ok: channel://__uri/SamplePackage-1.0.4snapshot1207834335 C:\php\PEAR\pear\SamplePackage>dir /s Directory of C:\php\PEAR\pear\SamplePackage 16.04.2008 09:04 <DIR> admin1 Directory of C:\php\PEAR\pear\SamplePackage\admin1 16.04.2008 09:04 66 1.php -------------------------------------------------- Expected result: ---------------- SamplePackage/admin2/2.php (file installed with upgraded version) Actual result: -------------- SamplePackage/admin1/ (empty directory) SamplePackage/admin2/2.php (file installed with upgraded version)

Comments

 [2008-04-16 06:36 UTC] alexandertumanovsky (Alexander Tumanovsky)
The upgrade code was: -------------------------------------------------- C:\pearTest>pear upgrade SamplePackage-1.0.4snapshot1208273857.tar upgrade ok: channel://__uri/SamplePackage-1.0.4snapshot1208273857 C:\php\PEAR\pear\SamplePackage>dir /s Directory of C:\php\PEAR\pear\SamplePackage 16.04.2008 09:08 <DIR> admin1 16.04.2008 09:08 <DIR> admin2 Directory of C:\php\PEAR\pear\SamplePackage\admin1 Directory of C:\php\PEAR\pear\SamplePackage\admin2 16.04.2008 09:08 66 2.php --------------------------------------------------
 [2008-04-22 13:33 UTC] doconnor (Daniel O'Connor)
What happens when you pear uninstall either package?
 [2008-04-22 15:17 UTC] alexandertumanovsky (Alexander Tumanovsky)
The admin2 folder was deleted after uninstall, but SamplePackage/admin1 still present. C:\pearTest>pear uninstall __uri/SamplePackage uninstall ok: channel://__uri/SamplePackage-1.0.4snapshot1208273857 ... dir Directory of C:\php\PEAR\pear\SamplePackage 22.04.2008 18:13 <DIR> . 22.04.2008 18:13 <DIR> .. 16.04.2008 09:08 <DIR> admin1 0 File(s) 0 bytes 3 Dir(s) 2 368 557 056 bytes free After that I've installed again the first version of package, and then uninstalled it, and directory C:\php\PEAR\pear\SamplePackage was removed after that. So again - the problem is in upgrade process.
 [2008-05-13 21:28 UTC] cellog (Greg Beaver)
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.