[MacPorts] #15186: port upgrade does not work correctly on current pseudo-port

MacPorts noreply at macports.org
Mon Apr 2 13:54:58 UTC 2018


#15186: port upgrade does not work correctly on current pseudo-port
---------------------+----------------------------
  Reporter:  raimue  |      Owner:  raimue
      Type:  defect  |     Status:  assigned
  Priority:  Normal  |  Milestone:  MacPorts 2.5.0
 Component:  base    |    Version:  1.6.0
Resolution:          |   Keywords:
      Port:          |
---------------------+----------------------------
Changes (by ryandesign):

 * cc: ryandesign (added)


Comment:

 Replying to [ticket:15186 raimue]:
 > Imagine you got some directory with a Portfile outside of your ports
 tree which has the same `name` as a port in the tree. Then run `port
 upgrade` in this directory, and not the port from this directory is build
 and installed, but the one from the tree. This is absolutely not expected
 behavior.

 I have been bitten by this behavior before, and I agree it was not at all
 obvious what was happening.

 Replying to [comment:7 jmroot]:
 > Replying to [comment:4 neverpanic]:
 > > This is a very uncommon usecase otherwise, so it's probably not worth
 investing a lot of time into it.
 > I don't know about that; I do it most of the time when updating ports.
 It's not ''needed'' of course, but it'll be an annoyance to retrain
 around.

 I also use `sudo port upgrade` constantly. Whenever I work on a port, I
 first `cd $(port dir foo)` so that I can easily `edit Portfile`, `sudo
 port install`, `sudo port upgrade`, `sudo port uninstall`, `port info`,
 and so forth, without having to further specify the port name.

 Could we only error out if `sudo port upgrade` is being attempted on a
 port that is ''not'' the one that is in the index?

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


More information about the macports-tickets mailing list