Invalid Plugin Yml

Discussion in 'Plugin Development' started by Cezzar, Jun 18, 2015.

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

    Cezzar

    Please HELP ! My console keeps saying :

    Show Spoiler
    Loading libraries, please wait...
    [12:54:16 INFO]: Starting minecraft server version 1.7.9
    [12:54:16 INFO]: Loading properties
    [12:54:17 INFO]: Default game type: SURVIVAL
    [12:54:17 INFO]: Generating keypair
    [12:54:17 INFO]: Starting Minecraft server on 192.168.2.2:25565
    [12:54:17 INFO]: This server is running CraftBukkit version git-Bukkit-1.7.2-R0.
    3-64-g3012211-b3076jnks (MC: 1.7.9) (Implementing API version 1.7.9-R0.1-SNAPSHO
    T)
    [12:54:17 ERROR]: Could not load 'plugins\Haberci.jar' in folder 'plugins'
    org.bukkit.plugin.InvalidDescriptionException: Invalid plugin.yml
    at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPlug
    inLoader.java:160) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks
    ]
    at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager
    .java:133) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.bukkit.craftbukkit.v1_7_R3.CraftServer.loadPlugins(CraftServer.ja
    va:357) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.bukkit.craftbukkit.v1_7_R3.CraftServer.<init>(CraftServer.java:31
    9) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at net.minecraft.server.v1_7_R3.PlayerList.<init>(PlayerList.java:68) [c
    raftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at net.minecraft.server.v1_7_R3.DedicatedPlayerList.<init>(SourceFile:14
    ) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at net.minecraft.server.v1_7_R3.DedicatedServer.init(DedicatedServer.jav
    a:126) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at net.minecraft.server.v1_7_R3.MinecraftServer.run(MinecraftServer.java
    :436) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at net.minecraft.server.v1_7_R3.ThreadServerApplication.run(SourceFile:6
    28) [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    Caused by: org.yaml.snakeyaml.scanner.ScannerException: null; mapping values are
    not allowed here
    at org.yaml.snakeyaml.scanner.ScannerImpl.fetchValue(ScannerImpl.java:73
    3) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.scanner.ScannerImpl.fetchMoreTokens(ScannerImpl.ja
    va:305) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.scanner.ScannerImpl.checkToken(ScannerImpl.java:17
    9) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.parser.ParserImpl$ParseBlockMappingKey.produce(Par
    serImpl.java:563) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]

    at org.yaml.snakeyaml.parser.ParserImpl.peekEvent(ParserImpl.java:161) ~
    [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.parser.ParserImpl.checkEvent(ParserImpl.java:146)
    ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java
    :230) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:160) ~
    [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java
    :237) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:160) ~
    [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java
    :237) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:160) ~
    [craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.composer.Composer.composeDocument(Composer.java:12
    3) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.composer.Composer.getSingleNode(Composer.java:106)
    ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.constructor.BaseConstructor.getSingleData(BaseCons
    tructor.java:121) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]

    at org.yaml.snakeyaml.Yaml.loadFromReader(Yaml.java:480) ~[craftbukkit.j
    ar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.yaml.snakeyaml.Yaml.load(Yaml.java:411) ~[craftbukkit.jar:git-Buk
    kit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.bukkit.plugin.PluginDescriptionFile.<init>(PluginDescriptionFile.
    java:189) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks]
    at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPlug
    inLoader.java:155) ~[craftbukkit.jar:git-Bukkit-1.7.2-R0.3-64-g3012211-b3076jnks
    ]



    This is my first plugin(Broadcast Plugin), I copied some codes from here.My plugin.yml:


    Show Spoiler
    name: Haberci
    author: Cezzar
    version: 1.0
    main: me.cezzar.haberci
    description: Duyuru yapma eklentisi
    commands:
    duyur:
    description: Bu kod ile duyuru yapabilirsiniz
    permission: haberci.duyur


    My Plugin Source:

    Show Spoiler
    package me.cezzar.haberci;

    import java.util.logging.Level;
    import java.util.logging.Logger;

    import org.bukkit.command.Command;
    import org.bukkit.command.CommandSender;
    import org.bukkit.plugin.java.JavaPlugin;

    public class Haberci extends JavaPlugin {
    public static final Logger logcu = Logger.getLogger("Minecraft");

    public void onEnable() {
    logcu.log(Level.INFO, "Eklenti Baslatiliyor!");
    }

    public void onDisable() {
    logcu.log(Level.INFO, "Eklenti Kapatiliyor!");
    }

    public boolean onCommand(CommandSender sender, Command cmd, String commandLabel, String[] args) {
    if (commandLabel.equalsIgnoreCase("duyur")) {

    }
    return false;
    }
    }
     
  2. Online

    timtower Administrator Administrator Moderator

    @Cezzar That isn't your plugin.yml
    That is your plugin source.
    Please post the content of the plugin.yml
     
  3. Offline

    Cezzar

    I've changed it.Thanks.
     
  4. Offline

    CyranoTrinity

    @Cezzar
    Check whether there are tabs in your plugin.yml
    Change those tabs to spaces if there are any.
     
  5. Offline

    Cezzar

    [​IMG][/url][/IMG] [​IMG][/url][/IMG] Adsız.png
     
  6. @Cezzar Ensure the indentation is correct.
     
  7. Offline

    Drkmaster83

    Additionally, change your main to me.cezzar.haberci.Haberci
     
  8. Offline

    CyranoTrinity

    1. Don't use tabs in yml. Use blankspaces instead
    2. In the plugin.yml main: must include the package AND the class name.
     
  9. Offline

    Cezzar

    [​IMG]
     
    Last edited: Jun 18, 2015
  10. Offline

    xTrollxDudex

    Can you please post the actual plugin.yml source, on a site like pastebin so it records the indentation? Posting pictures doesn't really tell us anything because the error points to a more technical issue.
     
  11. Offline

    CXdur

    Code:
    name: Haberci
    author: Cezzar
    version: 1.0
    main: me.cezzar.haberci
    description: Duyuru yapma eklentisi
    commands:
         duyur:
           description: Bu kod ile duyuru yapabilirsiniz
           permission: haberci.duyur
           usage: |
                  /<command>
    Try using this as a plugin.yml, put it in the src folder. Be sure to indent properly, if not your plugin will not work properly! A good way to see whether or not your plugin.yml file is valid is putting it through an online validator, at least that is an easy way for you to figure out whether or not there are errors in the yml file.
     
  12. Offline

    Drkmaster83

    :eek: You added 'Haberci' onto the name of your package... I didn't ask you to do that T_T
    Remove that '.Haberci' from your package, and take it and replace this line in your plugin.yml:
    Code:
    main: me.cezzar.haberci.Haberci
    *cry*
     
    dlange likes this.
  13. Offline

    Cezzar

    Thank you all, I fixed it. The problem was a very very small. It is working smoothly now :D
     
Thread Status:
Not open for further replies.

Share This Page