Failed to remap class.

Discussion in 'Plugin Development' started by marwzoor, Apr 25, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    marwzoor

    Hey guys!

    I made a market plugin which worked just fine in 1.4.7 and now that I updated it to 1.5.1 it just stopped working. Eclipse is not showing any errors what so ever but when I start my server using the plugin it prints out this error message:

    Click the spoiler for the error code.
    Show Spoiler

    Code:
    2013-04-24 20:36:49 [SEVERE] Could not load 'plugins\SmudgeMarket.jar' in folder 'plugins'
    org.bukkit.plugin.InvalidPluginException: java.lang.ClassNotFoundException: Failed to remap class net.smudgecraft.smudgemarket.SmudgeMarket
        at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:155)
        at org.bukkit.plugin.SimplePluginManager.loadPlugin(SimplePluginManager.java:307)
        at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:231)
        at org.bukkit.craftbukkit.v1_5_R2.CraftServer.loadPlugins(CraftServer.java:266)
        at org.bukkit.craftbukkit.v1_5_R2.CraftServer.<init>(CraftServer.java:244)
        at net.minecraft.server.PlayerList.<init>(PlayerList.java:55)
        at net.minecraft.server.DedicatedPlayerList.<init>(SourceFile:11)
        at net.minecraft.server.DedicatedServer.init(DedicatedServer.java:94)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:392)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:573)
    Caused by: java.lang.ClassNotFoundException: Failed to remap class net.smudgecraft.smudgemarket.SmudgeMarket
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:89)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:34)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:144)
        ... 9 more
    Caused by: java.lang.RuntimeException: java.lang.ClassNotFoundException: net.smudgecraft.smudgemarket.MarketItem
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.ClassWriter.getCommonSuperClass(ClassWriter.java:1601)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.ClassWriter.getMergedType(ClassWriter.java:1571)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.Frame.merge(Frame.java:1424)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.Frame.merge(Frame.java:1325)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.MethodWriter.visitMaxs(MethodWriter.java:1303)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.ClassReader.readCode(ClassReader.java:1409)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.ClassReader.readMethod(ClassReader.java:938)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.ClassReader.accept(ClassReader.java:669)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.ClassReader.accept(ClassReader.java:506)
        at org.bukkit.craftbukkit.libs.org.objectweb.asm.ClassWriter.toByteArray(ClassWriter.java:912)
        at org.bukkit.plugin.java.ClassRemapper.remap(ClassRemapper.java:69)
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:71)
        ... 15 more


    I would be really greatful if anyone could help me to resolve this issue!

    Thanks in advance!
     
  2. Offline

    BajanAmerican

    Try reconfiguring your plugin.yml, or any other access files you associated with to your plugin.
     
  3. Set the latest craftbukkit.jar as the dependency, that should work.
     
  4. Offline

    marwzoor

    Well, since I am not using any craftbukkit code, then that would be unneccesary, but I believe that you are reffering to the latest bukkit.jar as my dependency?

    Hellsing

    I tried to do that, but I get the same error as before Hellsing

    Hellsing
    It turned out to be that I was using libigot, and something was wrong there!

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 1, 2016
  5. Offline

    qwiso

    i've just hit the same error on libigot. Can you explain what you did to fix it?

    I assume because I built it against craftbukkit and am running libigot?

    but then why do all of the other plugins work?
     
  6. Offline

    marwzoor

    qwiso

    I don't really know, I didn't resolve the error :( I just made the plugin work by building against bukkit and run craftbukkit. But since we run our server with libigot(because of heroes) my plugin is pretty useless since it only works on craftbukkit...
    I am building against libkit and won't recieve any compiler errors and I really can't see why it isn't working!
     
  7. Maybe try updating the java version or so,...I had an error like this once and I fixed by updating my java version..
     
  8. Offline

    qwiso

    Yes, I solved it last night because I was building on 1.7 and the server plugin was running on 1.6. I was using libigot but am no longer using Heroes in favor of exactly the plugin I'm making to replace it (QCharSheet- will be making the project/repo in the next week or two).
     
Thread Status:
Not open for further replies.

Share This Page