FAQ
Edit report at http://pear.php.net/bugs/bug.php?id=17350&edit=1

ID: 17350
Updated by: tim@timj.co.uk
Reported By: tim at timj dot co dot uk
Summary: "pear install --force" doesn't uninstall files from
previous pkg versions
Status: Open
Type: Bug
Package: PEAR
Operating System: Linux
Package Version: 1.9.0
PHP Version: Irrelevant
Roadmap Versions:
New Comment:

First package.xml:

<?xml version="1.0" encoding="UTF-8"?>
<package version="2.0" xmlns="http://pear.php.net/dtd/package-2.0"
xmlns:tasks="http://pear.php.net/dtd/tasks-1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0
http://pear.php.net/dtd/tasks-1.0.xsd
http://pear.php.net/dtd/package-2.0
" rel="nofollow">http://pear.php.net/dtd/package-2.0.xsd">
<name>Test_Package99</name>
<channel>__uri</channel>
<summary>A test package</summary>
<description>Whatever</description>
<lead>
<name>Example User</name>
<user>example</user>
<email>example@example.comk</email>
<active>yes</active>
</lead>
<date>2007-02-03</date>
<version>
<release>1.0.0</release>
<api>1.0</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license>Foo License</license>
<notes>This is the first release.
</notes>
<contents>
<dir name="/">
<file role="php" name="test1.php" />
<file role="php" name="test2.php" />
</dir>
</contents>
<dependencies>
<required>
<php>
<min>4.3.0</min>
</php>
<pearinstaller>
<min>1.4.0</min>
</pearinstaller>
</required>
</dependencies>
<phprelease />
</package>


Previous Comments:
------------------------------------------------------------------------

[2010-04-28 09:14:32] timj

Description:
------------
When using "pear install --force" to install a different version of
package which is already installed, any files existing in the original
version but not in the version being force-installed are not removed.

Test script:
---------------
See attached package.xml files for two packages:
- Test_Package99-1.0.0 which has two files, test1.php and test2.php
- Test_Package99-1.1.0 which has only one file, test1.php

pear install Test_Package99-1.0.0/package2.xml
pear install -f Test_Package99-1.1.0/package2.xml

This test case is for illustration only; here, there's no reason to
force the install. The point still applied in the general case though.

Expected result:
----------------
Only one file, test1.php is in php_dir

Actual result:
--------------
Two files, test1.php and test2.php are in php_dir. test2.php is left
over from the old installation of Test_Package99-1.0.0 and is orphaned;
it will never be removed.

------------------------------------------------------------------------

Search Discussions

  • Tim at Apr 28, 2010 at 8:22 am
    Edit report at http://pear.php.net/bugs/bug.php?id=17350&edit=1

    ID: 17350
    Updated by: tim@timj.co.uk
    Reported By: tim at timj dot co dot uk
    Summary: "pear install --force" doesn't uninstall files from
    previous pkg versions
    Status: Open
    Type: Bug
    Package: PEAR
    Operating System: Linux
    Package Version: 1.9.0
    PHP Version: Irrelevant
    Roadmap Versions:
    New Comment:

    Second package.xml:

    <?xml version="1.0" encoding="UTF-8"?>
    <package version="2.0" xmlns="http://pear.php.net/dtd/package-2.0"
    xmlns:tasks="http://pear.php.net/dtd/tasks-1.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0
    http://pear.php.net/dtd/tasks-1.0.xsd
    http://pear.php.net/dtd/package-2.0
    " rel="nofollow">http://pear.php.net/dtd/package-2.0.xsd">
    <name>Test_Package99</name>
    <channel>__uri</channel>
    <summary>A test package</summary>
    <description>Whatever</description>
    <lead>
    <name>Example User</name>
    <user>example</user>
    <email>example@example.comk</email>
    <active>yes</active>
    </lead>
    <date>2007-02-03</date>
    <version>
    <release>1.1.0</release>
    <api>1.0</api>
    </version>
    <stability>
    <release>stable</release>
    <api>stable</api>
    </stability>
    <license>Foo License</license>
    <notes>This is the first release.
    </notes>
    <contents>
    <dir name="/">
    <file role="php" name="test1.php" />
    </dir>
    </contents>
    <dependencies>
    <required>
    <php>
    <min>4.3.0</min>
    </php>
    <pearinstaller>
    <min>1.4.0</min>
    </pearinstaller>
    </required>
    </dependencies>
    <phprelease />
    </package>


    Previous Comments:
    ------------------------------------------------------------------------

    [2010-04-28 09:15:55] timj

    First package.xml:

    <?xml version="1.0" encoding="UTF-8"?>
    <package version="2.0" xmlns="http://pear.php.net/dtd/package-2.0"
    xmlns:tasks="http://pear.php.net/dtd/tasks-1.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0
    http://pear.php.net/dtd/tasks-1.0.xsd
    http://pear.php.net/dtd/package-2.0
    " rel="nofollow">http://pear.php.net/dtd/package-2.0.xsd">
    <name>Test_Package99</name>
    <channel>__uri</channel>
    <summary>A test package</summary>
    <description>Whatever</description>
    <lead>
    <name>Example User</name>
    <user>example</user>
    <email>example@example.comk</email>
    <active>yes</active>
    </lead>
    <date>2007-02-03</date>
    <version>
    <release>1.0.0</release>
    <api>1.0</api>
    </version>
    <stability>
    <release>stable</release>
    <api>stable</api>
    </stability>
    <license>Foo License</license>
    <notes>This is the first release.
    </notes>
    <contents>
    <dir name="/">
    <file role="php" name="test1.php" />
    <file role="php" name="test2.php" />
    </dir>
    </contents>
    <dependencies>
    <required>
    <php>
    <min>4.3.0</min>
    </php>
    <pearinstaller>
    <min>1.4.0</min>
    </pearinstaller>
    </required>
    </dependencies>
    <phprelease />
    </package>

    ------------------------------------------------------------------------

    [2010-04-28 09:14:32] timj

    Description:
    ------------
    When using "pear install --force" to install a different version of
    package which is already installed, any files existing in the original
    version but not in the version being force-installed are not removed.

    Test script:
    ---------------
    See attached package.xml files for two packages:
    - Test_Package99-1.0.0 which has two files, test1.php and test2.php
    - Test_Package99-1.1.0 which has only one file, test1.php

    pear install Test_Package99-1.0.0/package2.xml
    pear install -f Test_Package99-1.1.0/package2.xml

    This test case is for illustration only; here, there's no reason to
    force the install. The point still applied in the general case though.

    Expected result:
    ----------------
    Only one file, test1.php is in php_dir

    Actual result:
    --------------
    Two files, test1.php and test2.php are in php_dir. test2.php is left
    over from the old installation of Test_Package99-1.0.0 and is orphaned;
    it will never be removed.

    ------------------------------------------------------------------------
  • Helgith at Apr 29, 2010 at 2:13 am
    Edit report at http://pear.php.net/bugs/bug.php?id=17350&edit=1

    ID: 17350
    Updated by: helgith@gmail.com
    Reported By: tim at timj dot co dot uk
    Summary: "pear install --force" doesn't uninstall files from
    previous pkg versions
    Status: Open
    Type: Bug
    Package: PEAR
    Operating System: Linux
    Package Version: 1.9.0
    PHP Version: Irrelevant
    -Assigned To:
    +Assigned To: dufuz
    Roadmap Versions:
    New Comment:

    -Assigned To:
    +Assigned To: dufuz



    Previous Comments:
    ------------------------------------------------------------------------

    [2010-04-28 09:16:13] timj

    Second package.xml:

    <?xml version="1.0" encoding="UTF-8"?>
    <package version="2.0" xmlns="http://pear.php.net/dtd/package-2.0"
    xmlns:tasks="http://pear.php.net/dtd/tasks-1.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0
    http://pear.php.net/dtd/tasks-1.0.xsd
    http://pear.php.net/dtd/package-2.0
    " rel="nofollow">http://pear.php.net/dtd/package-2.0.xsd">
    <name>Test_Package99</name>
    <channel>__uri</channel>
    <summary>A test package</summary>
    <description>Whatever</description>
    <lead>
    <name>Example User</name>
    <user>example</user>
    <email>example@example.comk</email>
    <active>yes</active>
    </lead>
    <date>2007-02-03</date>
    <version>
    <release>1.1.0</release>
    <api>1.0</api>
    </version>
    <stability>
    <release>stable</release>
    <api>stable</api>
    </stability>
    <license>Foo License</license>
    <notes>This is the first release.
    </notes>
    <contents>
    <dir name="/">
    <file role="php" name="test1.php" />
    </dir>
    </contents>
    <dependencies>
    <required>
    <php>
    <min>4.3.0</min>
    </php>
    <pearinstaller>
    <min>1.4.0</min>
    </pearinstaller>
    </required>
    </dependencies>
    <phprelease />
    </package>

    ------------------------------------------------------------------------

    [2010-04-28 09:15:55] timj

    First package.xml:

    <?xml version="1.0" encoding="UTF-8"?>
    <package version="2.0" xmlns="http://pear.php.net/dtd/package-2.0"
    xmlns:tasks="http://pear.php.net/dtd/tasks-1.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0
    http://pear.php.net/dtd/tasks-1.0.xsd
    http://pear.php.net/dtd/package-2.0
    " rel="nofollow">http://pear.php.net/dtd/package-2.0.xsd">
    <name>Test_Package99</name>
    <channel>__uri</channel>
    <summary>A test package</summary>
    <description>Whatever</description>
    <lead>
    <name>Example User</name>
    <user>example</user>
    <email>example@example.comk</email>
    <active>yes</active>
    </lead>
    <date>2007-02-03</date>
    <version>
    <release>1.0.0</release>
    <api>1.0</api>
    </version>
    <stability>
    <release>stable</release>
    <api>stable</api>
    </stability>
    <license>Foo License</license>
    <notes>This is the first release.
    </notes>
    <contents>
    <dir name="/">
    <file role="php" name="test1.php" />
    <file role="php" name="test2.php" />
    </dir>
    </contents>
    <dependencies>
    <required>
    <php>
    <min>4.3.0</min>
    </php>
    <pearinstaller>
    <min>1.4.0</min>
    </pearinstaller>
    </required>
    </dependencies>
    <phprelease />
    </package>

    ------------------------------------------------------------------------

    [2010-04-28 09:14:32] timj

    Description:
    ------------
    When using "pear install --force" to install a different version of
    package which is already installed, any files existing in the original
    version but not in the version being force-installed are not removed.

    Test script:
    ---------------
    See attached package.xml files for two packages:
    - Test_Package99-1.0.0 which has two files, test1.php and test2.php
    - Test_Package99-1.1.0 which has only one file, test1.php

    pear install Test_Package99-1.0.0/package2.xml
    pear install -f Test_Package99-1.1.0/package2.xml

    This test case is for illustration only; here, there's no reason to
    force the install. The point still applied in the general case though.

    Expected result:
    ----------------
    Only one file, test1.php is in php_dir

    Actual result:
    --------------
    Two files, test1.php and test2.php are in php_dir. test2.php is left
    over from the old installation of Test_Package99-1.0.0 and is orphaned;
    it will never be removed.

    ------------------------------------------------------------------------

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppear-bugs @
categoriesphp
postedApr 28, '10 at 8:21a
activeApr 29, '10 at 2:13a
posts3
users2
websitepear.php.net

2 users in discussion

Tim: 2 posts Helgith: 1 post

People

Translate

site design / logo © 2022 Grokbase