Sodium Extra

Sodium Extra

25M Downloads

[Issue] With the newest version if updated, modpack no longer launches

DarkkRevenant opened this issue ยท 25 comments

commented

When updating mods, I updated this mod, and by doing so my modpack will no longer launch. Yes it is only this mod, I updated all the others and it works just fine, right up until I update this one

commented

Not sure which modpack you are referring to, but yes, I can confirm the crash when updating Sodium Extra from 0.3.5 to 0.3.6 on my Fabulously Optimized 2.4.1.

Crashlog: https://pastebin.com/40dBsKkh

Looking at the changes between the versions, there doesn't seem to be much.
The most concerning one seems to be the change of 10bdc39, however I don't understand why it crashes on client startup instead of world load then...

Notably the crash persists after downgrading from 0.3.6 to 0.3.5 again. I don't know how that works... mixin caches?

Edit: I can confirm reverting that change makes it run again.
Edit 2: MultiMC launcher log with -Dmixin.debug.export=true, maybe it helps: https://pastebin.com/ZyEQ2JR5

commented

This might be caused by the curseforge launcher since I have marked Sodium as an dependency, it will also bundle Sodium even if you have Iris installed.

Edit: This is just a speculation since I don't have access to my development machine to test any of this.

commented

This might be caused by the curseforge launcher since I have marked Sodium as an dependency, it will also bundle Sodium even if you have Iris installed.

Edit: This is just a speculation since I don't have access to my development machine to test any of this.

Suppose Madis can test this by unzipping the jar and editing it's mod.json to remove the dependency. I can't really try this myself, since I don't want to infect my computer with the curseforge launcher.

commented

The only thing I can really do is unmark Sodium as an dependency on CF to prevent the launcher from automatically bundling Sodium even if Iris is installed.

commented

This might be caused by the curseforge launcher since I have marked Sodium as an dependency, it will also bundle Sodium even if you have Iris installed.
Edit: This is just a speculation since I don't have access to my development machine to test any of this.

Suppose Madis can test this by unzipping the jar and editing it's mod.json to remove the dependency. I can't really try this myself, since I don't want to infect my computer with the curseforge launcher.

Hmm, it doesn't quite seem like it at first glance, because there is no 3488836 (of https://www.curseforge.com/minecraft/mc-mods/sodium/files/3488836) in https://github.com/Fabulously-Optimized/fabulously-optimized/blob/main/Curseforge/manifest.json

Besides, I did try this in MultiMC (available to download in my modpack's files) where there certainly is only Iris+Sodium. I've yet to test this with pure Sodium though.

commented

Besides, I did try this in MultiMC (available to download in my modpack's files) where there certainly is only Iris+Sodium

I stand corrected, there is
sodium-fabric-mc1.17.1-0.3.2+build.7 in my own crash log (at the top of this issue). Oh boy, at least Iris will soon work with native Sodium.

commented

image
Iris bundles with their custom version of Sodium and the version you mentioned above does not match with 0.3.2+IRIS2-build.9
image

Edit: whoops misunderstood previous comment

commented

Perhaps the solution would be to mark both Sodium and Iris as optional dependencies of Sodium Extra?
Until Iris works with official Sodium, that is.

commented

I have marked the latest version of 1.16.x and 1.17.x as optional dependencies

commented

This is rather unusual, because the class that seems to be causing this exception, class_1921, is RenderLayer, which is not at all related to the mixin changes in that commit. This wouldn't be the first time that some initialization order caused exceptions in weird places, but it's not something that I'd be able to investigate without loading up both Sodium Extras and whatever incompatible mod in a development environment.

commented

Here is a root cause I found after loading everything together:

Caused by: org.spongepowered.asm.mixin.injection.throwables.InjectionError:
 Critical injection failure:
  Redirector redirectGetUniformLocation(ILjava/lang/CharSequence;)I
   in sodium.mixins.json:features.shader.MixinShader
    from mod sodium failed injection check,
     (0/1) succeeded. Scanned 1 target(s).
      Using refmap mixins.sodium.refmap.json

Note that I did change the fabric api version, as other mods were crashing without it.

-    fabric_version=0.38.1+1.17
\ No newline at end of file
+    fabric_version=0.42.1+1.17
commented

@Madis0 I got your modpack to work by removing not-enough-crashes. Try taking that out.

commented

I can't seem to pin down the exact cause other than that it's this particular mixin in Sodium that is failing:
https://github.com/FlashyReese/sodium-fabric/blob/1.17.x/dev/src/main/java/me/jellysquid/mods/sodium/mixin/features/shader/MixinShader.java

The only reason I can think of that it would fail is:
A. There are two versions of Sodium being loaded somehow
B. Another mod is doing an infection into the same spot

I can't see any other mods that are injecting into the same class, so I have to assume it's A. In my dev environment the game launches when I remove iris-and-sodium but crashes shortly after joining a world, so perhaps try replacing iris with the recommended sodium build instead to see if that changes anything?

commented

So, this was partly also my fault that I wasn't paying attention - I can see the Sodium entry in CF Launcher and I can remove it, distribute without etc, just forgot to look for it and remove it at this time. (Edit: though that didn't change manifest for me so I have no idea how it works... Guess it's better to do at project level, like you did.)
And I can also confirm that Sodium Extra 0.3.6 works with Iris+Sodium if the original Sodium is not present.

I will also contact Indium dev to do the same change and Flashy, please do it for Reese's Sodium Options as well.
Big thanks to Sollace for even investigating this, that did help a lot.

commented

Flashy, please do it for Reese's Sodium Options as well.

Done

We'll just have to wait for Iris for the time being.

commented

Sorry I thought I had been replying to this conversation, but I guess not. Is this issue fixed yet, or are we still waiting?

commented

Sorry I thought I had been replying to this conversation, but I guess not. Is this issue fixed yet, or are we still waiting?

If you depend on Flashy's Sodium mods only, then it should be fixed for you. If you depend on Indium or something else as well, you need to wait a bit more or check the mod list in CF Launcher to make sure Sodium is removed. (I contacted Indium already.)

commented

The issue is not the mods, it's the CF Launcher since it just automatically bundles dependencies. Just be sure to remove Sodium if you have Iris installed. Basically you have 2 copies of Sodium trying to run at the same time.

commented

CF Launcher was downloading standard Sodium since I had it marked as an dependency on CF

commented

Okay, sounds good. I had Iris and Sodium Extra both installed at the time of the occurrence. Was Sodium Extra downloading Sodium due to dependencies?

commented

Well if that's what you told it to do that makes sense. You guys are awesome for getting it figured out so soon! Thanks so much!! I will keep you updated if any more issues occur.

commented

Besides, I did try this in MultiMC (available to download in my modpack's files) where there certainly is only Iris+Sodium

I stand corrected, there is sodium-fabric-mc1.17.1-0.3.2+build.7 in my own crash log (at the top of this issue). Oh boy, at least Iris will soon work with native Sodium.

I agree. Bundling major libraries as a JiJ is no bueno. I even saw one other mod in your pack which is bundling parts of fabric-api, though thankfully at least those are less heavy and not as prone to cause issues like a mod such as Sodium can be.

commented

Big thanks to Sollace for even investigating this, that did help a lot.

Aaaaw thank you!

commented

I agree. Bundling major libraries as a JiJ is no bueno. I even saw one other mod in your pack which is bundling parts of fabric-api, though thankfully at least those are less heavy and not as prone to cause issues like a mod such as Sodium can be.

Well, Sodium was there because I copy mods to my MultiMC version automatically and right now I just didn't notice it.

Not sure what you mean by JiJ though, and we can discuss that other mod as well if you post an issue to the modpack's GH or join its Discord from there. Let's not drive this conversation off-topic here ๐Ÿ™‚

commented

Well, Sodium was there because I copy mods to my MultiMC version automatically and right now I just didn't notice it.

Not sure what you mean by JiJ though, and we can discuss that other mod as well if you post an issue to the modpack's GH or join its Discord from there. Let's not drive this conversation off-topic here ๐Ÿ™‚

Getting kind of off topic for this issue, but basically JiJ is Jar in Jar. These are mods that are literally inside the mod jars you have installed. It's the same thing @FlashyReese was showing you in those screenshots of iris-and-sodium.jar