#70886 closed defect (invalid)
`port migrate` gets dependencies wrong
Reported by: | ShadSterling (Shad Sterling) | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.10.1 |
Keywords: | sequoia | Cc: | |
Port: |
Description
port migrate
(and port restore --last
) refuse to reinstall MPlayer after gss build fails, but installing MPlayer separately doesn't try to install gss
- MPlayer Skipped because its dependency gss failed
Change History (12)
comment:1 Changed 7 weeks ago by ShadSterling (Shad Sterling)
comment:2 Changed 7 weeks ago by jmroot (Joshua Root)
Have you confirmed this with port rdependents gss
after the restore of MPlayer finishes? (The gss port is now fixed so this is possible.) It's more likely that the dependencies resolve differently when restoring from the snapshot because different variants are selected.
comment:3 Changed 7 weeks ago by jmroot (Joshua Root)
port snapshot --all --diff <snapshot-id>
might also give some insights about what is different.
comment:4 follow-up: 6 Changed 7 weeks ago by ShadSterling (Shad Sterling)
curl did have the gsasl variant, which does bring in gss; it's the only one so far to succeed
The diff doesn't show what the variants were for MPlayer or dia so I can't be sure.
For MPlayer the only variant is universal which I doubt I had enabled, and I wouldn't expect it to change dependencies.
For dia it's less involved than curl, I tried +quartz-universal with +python27, which failed on #70866, and with -python27 which failed with errors like #70804, both without attempting to install gss
The rest will have to wait for tomorrow
comment:5 Changed 7 weeks ago by jmroot (Joshua Root)
It isn't necessarily a difference in MPlayer's variants, it could be any of its recursive dependencies. There are also dependencies that can be satisfied by multiple ports (like openssl/libressl), so things will go differently depending on which ports were installed.
comment:6 Changed 7 weeks ago by jmroot (Joshua Root)
Replying to ShadSterling:
curl did have the gsasl variant, which does bring in gss; it's the only one so far to succeed
Curl is also a dependency of MPlayer via cmake, so it seems like it was working correctly?
comment:7 Changed 7 weeks ago by ShadSterling (Shad Sterling)
Possibly; I tried to restore again with the fix to gss, and now it's failing to computer the dependency order at all.
Output of port selfupdate; port -v -d restore --last
ends with
DEBUG: Dependency calculation for port mpv DEBUG: Opening port in directory: /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/multimedia/mpv DEBUG: OS darwin/24.0.0 (macOS 15.0) arch i386 DEBUG: Sourcing PortGroup github 1.0 from /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/_resources/port1.0/group/github-1.0.tcl DEBUG: Re-registering default for configure.cmd DEBUG: Re-registering default for configure.pre_args DEBUG: Re-registering default for build.dir DEBUG: Re-registering default for build.cmd DEBUG: Re-registering default for build.target DEBUG: Re-registering default for destroot.cmd DEBUG: Re-registering default for destroot.post_args DEBUG: Sourcing PortGroup meson 1.0 from /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/_resources/port1.0/group/meson-1.0.tcl DEBUG: Sourcing PortGroup compiler_blacklist_versions 1.0 from /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/_resources/port1.0/group/compiler_blacklist_versions-1.0.tcl DEBUG: Sourcing PortGroup legacysupport 1.1 from /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/_resources/port1.0/group/legacysupport-1.1.tcl DEBUG: Sourcing PortGroup active_variants 1.1 from /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/_resources/port1.0/group/active_variants-1.1.tcl DEBUG: Re-registering default for extract.rename DEBUG: Re-registering default for livecheck.url DEBUG: Re-registering default for livecheck.regex DEBUG: Sourcing PortGroup xcodeversion 1.0 from /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/_resources/port1.0/group/xcodeversion-1.0.tcl DEBUG: compiler clang 1600.0.26.3 not blacklisted because it doesn't match {clang < 700} DEBUG: universal_variant is false, so not adding the default universal variant DEBUG: Executing variant python312 provides python312 DEBUG: Executing variant screenshot provides screenshot DEBUG: Executing variant network provides network Error: mpv: Variant network conflicts with network_ytdlp DEBUG: process_cmd failed: can't read "variants": no such variable while executing "ui_error "Unable to open port '$portname' with variants '$variants': $result"" (procedure "resolve_dependencies" line 96) invoked from within "resolve_dependencies $snapshot $include_unrequested" (procedure "restore_state" line 3) invoked from within "restore_state $snapshot $include_unrequested" (procedure "restore::main" line 66) invoked from within "restore::main $opts" (procedure "macports::restore_main" line 10) invoked from within "macports::restore_main $opts" (procedure "action_restore" line 5) invoked from within "$action_proc $action $portlist [array get global_options]" (procedure "process_cmd" line 126) invoked from within "process_cmd $remaining_args" ("try" body line 3) Error: process_cmd failed: can't read "variants": no such variable
How can I get port snapshot
to show me each port & variants included in a snapshot?
comment:8 Changed 7 weeks ago by ShadSterling (Shad Sterling)
Got aria2 installed
port snapshot --all --diff <snapshot-id>
includes
- aria2 requested variants changed from '+cares+sqlite3-docs-gnutls-openssl-universal' to '+cares+docs+sqlite3-gnutls-universal' variants changed from '+cares+sqlite3' to '+cares+docs+sqlite3'
port rdependents gss
does not include aria2
The following ports are dependent on gss: libgsasl curl cargo cmake git libgit2 rust mupdf tesseract
Could adding +docs have removed a dependency?
comment:9 Changed 7 weeks ago by jmroot (Joshua Root)
Resolution: | → invalid |
---|---|
Status: | new → closed |
In the case of MPlayer it was definitely a case of its dependency curl being installed with a different variant. If you have a specific reproducible example where dependencies are calculated incorrectly, please reopen.
comment:10 Changed 7 weeks ago by ShadSterling (Shad Sterling)
1100 ports in the migrate snapshot
38 ports failing before #70886 (gss) was fixed
17 could be installed individually (after #70886 was fixed)
14 could be installed with the same variants
9 installed with the same variants do not appear in port rdependents gss
8 installed with the same variants do not appear in port rdependents gss
and were Skipped because its dependency gss failed
aria2, gnuplot, graphviz-gui, gstreamer1-gst-plugins-base, mercurial, py-jupyter_console, ruby33, youtube-dl
port rdependents gss
:
The following ports are dependent on gss: libgsasl curl cargo cmake freeciv git jp2a libgit2 rust lnav mupdf tesseract wxWidgets-3.2
Excerpts from the output of the last run of port -v -d restore --last
(before #70886 was fixed):
Migration finished with errors. The following ports could not be restored:
- aria2 Skipped because its dependency gss failed
- gnuplot Skipped because its dependency gss failed - graphviz-gui Skipped because its dependency gss failed - gstreamer1-gst-plugins-base Skipped because its dependency gss failed
- mercurial Skipped because its dependency gss failed
- ruby33 Skipped because its dependency gss failed
The following ports could not be fully restored:
- py-jupyter_console Skipped because its dependency gss failed state changed from 'installed' to 'inactive'
- youtube-dl Skipped because its dependency gss failed state changed from 'installed' to 'inactive'
Excerpts from the output of port snapshot --all --diff 1
after individually reinstalling with the same variants (after #70886 was fixed):
The following ports are in the snapshot and installed, but with changes:
- aria2 requested variants changed from '+cares+sqlite3-docs-gnutls-openssl-universal' to '+cares+sqlite3-docs-universal'
- gstreamer1-gst-plugins-base requested variants changed from '+ogg-universal-x11' to '-universal-x11'
gnuplot, graphviz-gui, mercurial, py-jupyter_console, ruby33, and youtube-dl were not included in this diff, despite being included in earlier diffs and the restore.
I'm not going to re-break my system before I even get it back to normal to try to reproduce this
comment:11 Changed 7 weeks ago by jmroot (Joshua Root)
All of those ports have curl somewhere in their rdeps (aria2 due to the non-default cares variant). Please open a separate ticket if there is an issue with port snapshot --diff
.
comment:12 Changed 7 weeks ago by ShadSterling (Shad Sterling)
Then I guess the bug here is that rdependents
output is incomplete
same with curl