[MacPorts] #53857: port -N reclaim does not remove any ports

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

[MacPorts] #53857: port -N reclaim does not remove any ports

MacPorts
#53857: port -N reclaim does not remove any ports
--------------------+-----------------
 Reporter:  raimue  |      Owner:
     Type:  defect  |     Status:  new
 Priority:  Normal  |  Milestone:
Component:  base    |    Version:
 Keywords:          |       Port:
--------------------+-----------------
 When reclaim is started in non-interactive mode with `sudo port -N
 reclaim`, the command will check for "unnecessary unrequested ports", but
 will not remove any of them.

 {{{
 $ sudo port -N reclaim
 --->  Checking for unnecessary unrequested ports
 Found unrequested ports without requested dependents: qt5-qt3d, grep,
 grep, gmake, py27-sphinx, py27-sphinx, [...]
 --->  Checking for inactive ports
 --->  Building list of distfiles still in use
 --->  Searching for unused distfiles
 --->  Scanning binaries for linking errors
 --->  No broken files found.
 }}}

 I expected the command to remove all listed ports without asking me for
 confirmation, similar to the behavior of commands like `port -N uninstall`
 that assume 'yes' as answer in non-interactive mode.

--
Ticket URL: <https://trac.macports.org/ticket/53857>
MacPorts <https://www.macports.org/>
Ports system for macOS
Reply | Threaded
Open this post in threaded view
|

Re: [MacPorts] #53857: port -N reclaim does not remove any ports

MacPorts
#53857: port -N reclaim does not remove any ports
---------------------+-----------------
  Reporter:  raimue  |      Owner:
      Type:  defect  |     Status:  new
  Priority:  Normal  |  Milestone:
 Component:  base    |    Version:
Resolution:          |   Keywords:
      Port:          |
---------------------+-----------------
Description changed by raimue:

Old description:

> When reclaim is started in non-interactive mode with `sudo port -N
> reclaim`, the command will check for "unnecessary unrequested ports", but
> will not remove any of them.
>
> {{{
> $ sudo port -N reclaim
> --->  Checking for unnecessary unrequested ports
> Found unrequested ports without requested dependents: qt5-qt3d, grep,
> grep, gmake, py27-sphinx, py27-sphinx, [...]
> --->  Checking for inactive ports
> --->  Building list of distfiles still in use
> --->  Searching for unused distfiles
> --->  Scanning binaries for linking errors
> --->  No broken files found.
> }}}
>
> I expected the command to remove all listed ports without asking me for
> confirmation, similar to the behavior of commands like `port -N
> uninstall` that assume 'yes' as answer in non-interactive mode.

New description:

 When reclaim is started in non-interactive mode with `sudo port -N
 reclaim`, the command will check for "unnecessary unrequested ports", but
 will not remove any of them.

 {{{
 $ sudo port -N reclaim
 --->  Checking for unnecessary unrequested ports
 Found unrequested ports without requested dependents: qt5-qt3d, grep,
 grep, gmake, py27-sphinx, py27-sphinx, [...]
 --->  Checking for inactive ports
 --->  Building list of distfiles still in use
 --->  Searching for unused distfiles
 --->  Scanning binaries for linking errors
 --->  No broken files found.
 }}}

 I expected the command to remove all listed ports without asking me for
 confirmation, similar to the behavior of commands like `port -N install`
 that assume 'yes' as answer in non-interactive mode.

--

--
Ticket URL: <https://trac.macports.org/ticket/53857#comment:1>
MacPorts <https://www.macports.org/>
Ports system for macOS
Reply | Threaded
Open this post in threaded view
|

Re: [MacPorts] #53857: port -N reclaim does not remove any ports

MacPorts
In reply to this post by MacPorts
#53857: port -N reclaim does not remove any ports
---------------------+-----------------
  Reporter:  raimue  |      Owner:
      Type:  defect  |     Status:  new
  Priority:  Normal  |  Milestone:
 Component:  base    |    Version:
Resolution:          |   Keywords:
      Port:          |
---------------------+-----------------

Comment (by mf2k):

 I think the issue is that "yes" is not a valid answer for it. I see this:

 {{{
 Enter option(s) [1-82/all]:
 }}}

 So it should say "all" in this case.

--
Ticket URL: <https://trac.macports.org/ticket/53857#comment:2>
MacPorts <https://www.macports.org/>
Ports system for macOS
Reply | Threaded
Open this post in threaded view
|

Re: [MacPorts] #53857: port -N reclaim does not remove any ports

MacPorts
In reply to this post by MacPorts
#53857: port -N reclaim does not remove any ports
---------------------+-----------------
  Reporter:  raimue  |      Owner:
      Type:  defect  |     Status:  new
  Priority:  Normal  |  Milestone:
 Component:  base    |    Version:
Resolution:          |   Keywords:
      Port:          |
---------------------+-----------------

Comment (by raimue):

 You are right, this is a 'multichoice' as it is called internally. What I
 meant is that the command should continue as if the user chose to remove
 all of the ports.

--
Ticket URL: <https://trac.macports.org/ticket/53857#comment:3>
MacPorts <https://www.macports.org/>
Ports system for macOS
Reply | Threaded
Open this post in threaded view
|

Re: [MacPorts] #53857: port -N reclaim does not remove any ports

MacPorts
In reply to this post by MacPorts
#53857: port -N reclaim does not remove any ports
---------------------+-----------------
  Reporter:  raimue  |      Owner:
      Type:  defect  |     Status:  new
  Priority:  Normal  |  Milestone:
 Component:  base    |    Version:
Resolution:          |   Keywords:
      Port:          |
---------------------+-----------------
Changes (by ryandesign):

 * cc: rbanffy (added)


Comment:

 Has duplicate #55698.

--
Ticket URL: <https://trac.macports.org/ticket/53857#comment:4>
MacPorts <https://www.macports.org/>
Ports system for macOS
Reply | Threaded
Open this post in threaded view
|

Re: [MacPorts] #53857: port -N reclaim does not remove any ports

MacPorts
In reply to this post by MacPorts
#53857: port -N reclaim does not remove any ports
---------------------+----------------------------
  Reporter:  raimue  |      Owner:  g5pw
      Type:  defect  |     Status:  assigned
  Priority:  Normal  |  Milestone:  MacPorts 2.5.0
 Component:  base    |    Version:
Resolution:          |   Keywords:
      Port:          |
---------------------+----------------------------
Changes (by raimue):

 * owner:   => g5pw
 * status:  new => assigned
 * milestone:   => MacPorts 2.5.0


Comment:

 The default for `port -N reclaim` should be to just delete everything,
 while one could still use `port -N -y reclaim` (dry-run) to see what it
 would do.

--
Ticket URL: <https://trac.macports.org/ticket/53857#comment:5>
MacPorts <https://www.macports.org/>
Ports system for macOS
Reply | Threaded
Open this post in threaded view
|

Re: [MacPorts] #53857: port -N reclaim does not remove any ports

MacPorts
In reply to this post by MacPorts
#53857: port -N reclaim does not remove any ports
---------------------+----------------------------
  Reporter:  raimue  |      Owner:  g5pw
      Type:  defect  |     Status:  assigned
  Priority:  Normal  |  Milestone:  MacPorts 2.5.0
 Component:  base    |    Version:
Resolution:          |   Keywords:
      Port:          |
---------------------+----------------------------

Comment (by raimue):

 Pull request: https://github.com/macports/macports-base/pull/65

--
Ticket URL: <https://trac.macports.org/ticket/53857#comment:6>
MacPorts <https://www.macports.org/>
Ports system for macOS
Reply | Threaded
Open this post in threaded view
|

Re: [MacPorts] #53857: port -N reclaim does not remove any ports

MacPorts
In reply to this post by MacPorts
#53857: port -N reclaim does not remove any ports
---------------------+----------------------------
  Reporter:  raimue  |      Owner:  g5pw
      Type:  defect  |     Status:  closed
  Priority:  Normal  |  Milestone:  MacPorts 2.5.0
 Component:  base    |    Version:
Resolution:  fixed   |   Keywords:
      Port:          |
---------------------+----------------------------
Changes (by raimue):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"08d0a695cae3f69740bb99d48e6a78772128dc50/macports-base"
 08d0a695cae3f69740bb99d48e6a78772128dc50/macports-base]:
 {{{
 #!ConfigurableCommitTicketReference repository="macports-base"
 revision="08d0a695cae3f69740bb99d48e6a78772128dc50"
 reclaim: Respect -N and -y flags

 Do not ask questions in non-interactive mode (-N), but still run all the
 checks and remove ports and files by default. Do not delete any files in
 dry-run mode (-y), even if the user confirmed the removal.

 Closes: https://trac.macports.org/ticket/53857
 }}}

--
Ticket URL: <https://trac.macports.org/ticket/53857#comment:7>
MacPorts <https://www.macports.org/>
Ports system for macOS