Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix regex patterns for Forge and mod version validation #99

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

tomjpeg
Copy link
Collaborator

@tomjpeg tomjpeg commented Dec 19, 2024

Updated regex patterns to properly detect incorrect Forge versions and incompatible mod versions.

@tomjpeg tomjpeg requested review from pavog and matthi4s December 19, 2024 11:28
'/net\.minecraftforge\.fml\.LoadingFailedException: Loading errors encountered: \[\n(?:.*\n)*Mod \§.([^\§]+)§. requires \§.([^\§]+)\§. \§.([^ \§]+)[^\§]*\§./'
'/net\.minecraftforge\.fml\.common\.MissingModsException: Mod \S+ \((.+)\) requires (?!minecraft[,\s])(.+)/',
'/net\.minecraftforge\.fml\.ModLoadingException: Mod \§.([^\§]+)\§. requires \§.(?!minecraft\§.)([^\§]+)\§. \§.([^ \§]+)[^\§]*\§./',
'/net\.minecraftforge\.fml\.LoadingFailedException: Loading errors encountered: \[\n(?:.*\n)*Mod \§.([^\§]+)§. requires \§.(?!minecraft\§.)([^\§]+)\§. \§.([^ \§]+)[^\§]*\§./'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are changing 3 patterns here, but only adding one to the Minecraft version problem.

@@ -1773,8 +1773,8 @@
]
},
{
"message": "The mod 'car' is missing the required mod 'minecraft'.",
"counter": 2,
"message": "The mod 'car' is not compatible with the Minecraft version 1.15.1.",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should add a new log for the non-Minecraft test case.

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.

3 participants