[MacPorts] #44091: In port interactive mode, pseudo-portnames corrupted after selfupdate
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------------------------------+-------------------------- Reporter: pjkim00@… | Owner: macports- Type: defect | tickets@… Priority: Normal | Status: new Component: base | Milestone: Keywords: corrupt pseudo-portname selfupdate | Version: 2.3.0 | Port: ------------------------------------------------+-------------------------- In interactive mode, after performing a selfupdate, several of the pseudo- portnames, e.g. inactive, obsolete both contain ~19K lines which I think is the entire list of available ports. Here is an example of what I mean. Same thing happens with "list inactive." [Lab/Transfac matrix] > '''list obsolete'''[[BR]] [Lab/Transfac matrix] > '''selfupdate'''[[BR]] ---> Updating MacPorts base sources using rsync[[BR]] MacPorts base version 2.3.0 installed,[[BR]] MacPorts base version 2.3.0 downloaded.[[BR]] ---> Updating the ports tree[[BR]] ---> MacPorts base is already the latest version[[BR]] The ports tree has been updated. To upgrade your installed ports, you should run[[BR]] port upgrade outdated[[BR]] [Lab/Transfac matrix] > '''list obsolete'''[[BR]] AppHack @1.1 aqua/AppHack[[BR]] AppKiDo @0.997 aqua/AppKiDo[[BR]] AquaLess @1.6 aqua/AquaLess[[BR]] ArpSpyX @1.1 aqua/ArpSpyX[[BR]] AssignmentTrackerX @2.0beta3.1 aqua/AssignmentTrackerX[[BR]] BGHUDAppKit @0.7 aqua/BGHUDAppKit[[BR]] BigSQL @1.0 aqua/BigSQL[[BR]] BiggerSQL @1.3.9 aqua/BiggerSQL[[BR]] Books @3.2.5c aqua/Books[[BR]] .... and onward for another ~19K lines -- Ticket URL: <https://trac.macports.org/ticket/44091> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+------------------------------------------------ Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 2.3.0 Resolution: | Keywords: corrupt pseudo-portname selfupdate Port: | ------------------------+------------------------------------------------ Comment (by ryandesign@…): I'm unable to reproduce that issue. Also, note that: * it is unusual to run `selfupdate` in interactive mode. Running selfupdate might update MacPorts. If so, MacPorts files may have been replaced/updated/removed, but you are still running the old version, which is not what you want; you want to be running the new version after selfupdating. * the `list` command is almost always the wrong command to use. See wiki:FAQ#portlist. In this case, `installed` is the correct command to use. -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:1> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+------------------------------------------------ Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 2.3.0 Resolution: | Keywords: corrupt pseudo-portname selfupdate Port: | ------------------------+------------------------------------------------ Comment (by pjkim00@…): I usually run individual port commands from the bash shell but sometimes my sudo times out so I wondered whether starting 'sudo port' once followed by calling everything else in interactive mode would save having to type my password. I just tried again and noted one thing. If selfupdate actually finds an outdated port, 'outdated' correctly contains the outdated ports. If however I upgrade those ports and selfupdate again, then 'outdated' now contains the entire port list of 19K items. I just found another method way to reproduce the same issue. In interactive mode, 'list outdated' returns nothing. But after the command 'outdated', 'list outdated' now returns the full list. Here is what I mean: [~]$ port[[BR]] MacPorts 2.3.0[[BR]] Entering interactive mode... ("help" for help, "quit" to quit)[[BR]] [Users/pjkim] > list outdated[[BR]] [Users/pjkim] > outdated[[BR]] No installed ports are outdated.[[BR]] [Users/pjkim] > list outdated[[BR]] AppHack @1.1 aqua/AppHack[[BR]] AppKiDo @0.997 aqua/AppKiDo[[BR]] ..... lots more lines[[BR]] Not a big deal because I will just stop using interactive mode and the problem/bug is absent when called non-interactively. My only concern is that this was an unexpected behavior that was possibly a real problem. After reading the FAQ you linked, I see that this is somewhat expected behavior, although the example above still puzzles me as it appears inconsistent/erratic. -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:2> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+-------------------------------- Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 2.3.0 Resolution: | Keywords: Port: | ------------------------+-------------------------------- Changes (by mf2k@…): * keywords: corrupt pseudo-portname selfupdate => -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:3> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+-------------------------------- Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 2.3.0 Resolution: | Keywords: Port: | ------------------------+-------------------------------- Comment (by jmr@…): Replying to [comment:1 ryandesign@…]:
* it is unusual to run `selfupdate` in interactive mode. Running selfupdate might update MacPorts. If so, MacPorts files may have been replaced/updated/removed, but you are still running the old version, which is not what you want; you want to be running the new version after selfupdating. This isn’t a problem, if base is actually updated then it exits immediately afterward.
I can repro this, but only with pseudo-portnames that evaluate to an empty list. Looks like ‘list $foo’ is becoming just ‘list’ when $foo is the empty string, and of course ‘port list’ is documented to list all the ports. But it works properly at first for some reason. -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:4> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+-------------------------------- Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 2.3.0 Resolution: | Keywords: Port: | ------------------------+-------------------------------- Comment (by pjkim00@…): Seems to be fixed in 2.3.1. Can probably close this ticket. Thank you to whoever fixed this. -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:5> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+-------------------------------- Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 2.3.0 Resolution: | Keywords: Port: | ------------------------+-------------------------------- Comment (by cal@…): Still happens for me on trunk, and I'm pretty sure I didn't see a commit touching the relevant code for this. -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:6> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+-------------------------------- Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 2.3.0 Resolution: | Keywords: Port: | ------------------------+-------------------------------- Comment (by cal@…): FWIW, I can also reproduce using {{{
list list outdated }}} or {{{ search list outdated }}}
I think the problem occurs as soon as a single command without arguments has been executed because the flag that's used to tell port that an argument has been provided but it expanded to an empty list never gets reset. -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:7> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+-------------------------------- Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: closed Priority: Normal | Milestone: MacPorts Future Component: base | Version: 2.3.0 Resolution: fixed | Keywords: Port: | ------------------------+-------------------------------- Changes (by cal@…): * status: new => closed * resolution: => fixed * milestone: => MacPorts Future Comment: r121485, merged into release_2_3 in r121486. In the next release. -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:8> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+-------------------------------- Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: closed Priority: Normal | Milestone: MacPorts Future Component: base | Version: 2.3.0 Resolution: fixed | Keywords: Port: | ------------------------+-------------------------------- Comment (by pjkim00@…): Replying to [comment:6 cal@…]:
Still happens for me on trunk, and I'm pretty sure I didn't see a commit touching the relevant code for this. You are correct. I jumped the gun. And thank you cal for fixing this.
-- Ticket URL: <https://trac.macports.org/ticket/44091#comment:9> MacPorts <http://www.macports.org/> Ports system for OS X
#44091: In port interactive mode, pseudo-portnames corrupted after selfupdate ------------------------+-------------------------------- Reporter: pjkim00@… | Owner: macports-tickets@… Type: defect | Status: closed Priority: Normal | Milestone: MacPorts 2.3.2 Component: base | Version: 2.3.0 Resolution: fixed | Keywords: Port: | ------------------------+-------------------------------- Changes (by jmr@…): * milestone: MacPorts Future => MacPorts 2.3.2 -- Ticket URL: <https://trac.macports.org/ticket/44091#comment:10> MacPorts <http://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts