Skip to content

Detect more version notations of missing Fabric mod dependencies - #228

Merged
pavog merged 1 commit into
masterfrom
fabric-dependency-version-notations
Nov 17, 2026
Merged

pavog merged 1 commit into
masterfrom
fabric-dependency-version-notations

Conversation

@pavog

@pavog pavog commented Nov 17, 2026

Copy link
Copy Markdown
Member
	 - Mod 'Foo1' (foo1) 1.0.0 requires any 2.x version of bar1, which is missing!
	 - Mod 'Foo3' (foo3) 1.0.0 requires version 2.0.0 or earlier of bar3, which is missing!
	 - Mod 'Foo4' (foo4) 1.0.0 requires version 2.0.0 or version 3.0.0 of bar4, which is missing!
	 - Mod 'Foo5' (foo5) 1.0.0 requires an unsatisfiable version range of bar5, which is missing!
	 - Mod 'Foo6' (foo6) 1.0.0 requires any 2.1.x version of bar6, which is missing!

Fabric Loader writes the version requirement of a dependency in different forms, depending on the depends entry in the fabric.mod.json.
FabricModDependencyProblem only knew any version, or later, after, before, an exact version and between, so a missing dependency written as 2.x, 2.1.x, <=2.0.0 or a list of versions was not detected at all.
This PR adds the patterns wildcard, maximum and list, the same ones FabricModIncompatibleMinecraftVersionProblem already has for Minecraft, and passes the version to ModInstallSolution as before (2.x, <=2.0.0, 2.0.0 or 3.0.0).

an unsatisfiable version range means that no version of the dependency can fulfil the requirement, for example >=2.0.0 <1.0.0.
Installing the dependency does not help then, so the solution is to install a different version of the mod that declares it.

The patterns end at the comma after the dependency, so they also match but only the wrong version is present.
That line still says "missing", which is a separate, already known inaccuracy.

Changes

  • add the patterns wildcard, maximum, list and unsatisfiable to FabricModDependencyProblem
  • add test log fabric-dependency-version-notations.log from a real Fabric Loader 0.20.1 server with six mods using different depends notations

@pavog
pavog merged commit 7b535e8 into master Nov 17, 2026
3 checks passed
@pavog
pavog deleted the fabric-dependency-version-notations branch November 17, 2026 16:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant