Closed injust closed 1 month ago
It's not non-deterministic. In this case it will be because croc
or or similar gained a python@3.13
dependency which means it had to be installed before.
Okay, that kind of makes sense, but I'm still confused. My Brewfile only lists the leaves and not their dependencies. So let's assume that python@3.13
is a dependency for an earlier formula -- why does that have to impact the order?
@injust because otherwise it will be installed when written and, if it fails, it will be confusing as to why it was installed in between bat
and croc
and not in between pv
and ripgrep
.
Fair enough.
It's not non-deterministic. In this case it will be because
croc
or or similar gained apython@3.13
dependency which means it had to be installed before.
Is this direct dependencies only, or does it include transitive dependencies too?
If I try brew uninstall python@3.13
, it errors and tells me that it's a dependency of glib (not in the Brewfile because it's a dependency) and yt-dlp. yt-dlp is down near the bottom of the list.
Also, croc doesn't have any non-build dependencies. So I still don't see why python@3.13
got moved to that line in the Brewfile specifically.
Is this direct dependencies only, or does it include transitive dependencies too?
It includes recursive dependencies.
So I still don't see why
python@3.13
got moved to that line in the Brewfile specifically.
You can step through the code if you want to figure it out, it's all open source.
In this case, python@3.13 shifted because of the dependency chain:
ffmpeg -> cairo -> glib -> python@3.13
glib recently updated its dependencies from python@3.12 to python@3.13, which moved python@3.13 "above" the (invisible) cairo entry in the Brewfile, hence its position between bat and croc.
because otherwise it will be installed when written and, if it fails, it will be confusing as to why it was installed in between
bat
andcroc
and not in betweenpv
andripgrep
.
In this case, it feels like the toposort causes more confusion (but I haven't thought about cases where it would help).
In this case, it feels like the toposort causes more confusion (but I haven't thought about cases where it would help).
I have thought about cases where it would help which is why we have it. It causes less confusion (and I can state this as I've read every issue and comment ever made on this repository).
I version control my Brewfile and the non-deterministic ordering makes the diffs a bit noisy. This seems to happen on and off with the
python@3.1x
formula.I'd expect all the
brew "..."
entries in the Brewfile to be ordered alphabetically.For example, some time ago, I upgraded from
python@3.12
topython@3.13
, ranbrew bundle dump --force
, and this was the Brewfile diff:Later on, I installed the
whatsapp
cask, ranbrew bundle dump --force
again, and this was the diff: