Reading the logjava.lang.ArithmeticException: / by zero (Division by Zero)
What the log looks like
java\.lang\.ArithmeticException: / by zero
How to fix it
- Open the crashing side's full crash report or `logs/latest.log` (if a player disconnects from a server with `Connection reset`, check that player's client crash report, not the server log) and find `java.lang.ArithmeticException: / by zero`.
- Read the first 3 to 5 `at ...` lines directly below `/ by zero` (skipping `java.lang.Math`) to spot the responsible mod's package name or Mixin tag, such as `de.keksuccino.fancymenu` or `handler$...$bobbyUpdate`.
- If the crash happens when opening a modded screen or terminal and `fancymenu` appears in those lines, update or remove FancyMenu, or disable its customization for that GUI.
- If the crash happens when joining a server or loading a world with `bobbyUpdate` in the stack trace while using OptiFabric, remove either Bobby or OptiFabric/OptiFine.
- If the error triggers during an Applied Energistics 2 autocrafting job (`appeng.crafting.CraftingTreeNode.request`), look for AE2 addons in the stack trace (such as AppliedE or OmniSequence) and remove or re-encode patterns whose output item count is zero.
- If another mod is named right below `/ by zero` and you recently changed configs or resource packs, inspect that mod's config file for any rate, interval, scale, or count set to `0` and restore its default value.
| Loaders | Forge, Neoforge, Fabric, Quilt, Server |
|---|
| Severity | Stops the game |
|---|
| Category | Reading the log |
|---|
Check your own log