Musical Instrument Minecraft Interface (MIMI)

Musical Instrument Minecraft Interface (MIMI)

1M Downloads

[BUG] Unable to rejoin server with many large MIDIs

Sv443 opened this issue ยท 3 comments

commented

Image

I added around 200 MIDI files to my server, some of which are around 200kB since they contain some artworks in the form of midi notes.
After opening the server transmitter, I got kicked and was then unable to rejoin the server until I removed the larger half of the MIDI files.
The latest.log and debug.log don't really show anything that isn't already in the screenshot above.
I feel like there should be at least some kind of better error logging so it's more clear where the error comes from, since it was really unclear to me and took a lot of trial and error to figure out.

Log: debug.log

Environment:

  • OS: Windows 10
  • Mod Version: 4.1.3-neo
  • Minecraft Version: 1.21.1
  • Forge Version: NeoForge 21.1.172
commented

Hello and thank you so much for the detailed bug report!

I believe this issue is likely from a similar root cause as a few other existing issues and I'm hoping a rewrite of how MIMI handles loading MIDI files will resolve all of these together (#155, #144, #112).

The existing system wasn't really designed to handle that many files at once, or files of that size, so I am not totally surprised to see this sort of issue, but there is supposed to be both an individual file size limit and overall number of files limit in MIMI both of which seem to definitely not be working as expected. ๐Ÿ˜…

Technically I think the reason we're not seeing particularly useful logs here is that MIMI is properly loading and trying to send information about all of the files to your client, but the packet that it ends up creating to send all of that information is larger than the built-in Minecraft packet size limit. As a result the error being hit is being generated from within Minecraft's network stack itself and not actually from the mod, so any logging in the mod isn't actually being hit.

I'm going to check into the file size and file number limits and figure out why those aren't working as intended and I'll plan to include a fix for that in the next release.

The proper fix of a rewrite of the MIDI loading system will take a fair bit longer so I don't think I'll be able to get it into the next release, but hopefully not too long after that.

Thanks again for the report!

commented

Thank you for the detailed reply :)

commented

Hello! I've uploaded the latest full release of MIMI to Modrinth and CurseForge (CurseForge may take a few hours for it to be approved) which should address this issue!

For now the fix is just a properly enforced limit on the number of MIDI files that can be loaded at once, but hopefully I'll be able to get a rewrite of the MIDI loading system in the future to support this better!

Thanks for supporting MIMI! ๐Ÿ˜„