NametagEdit

721k Downloads

Importing NameTagEdit through Maven causes errors while initialising the plugin

thehydrogen opened this issue ยท 9 comments

commented

Bug Report

Type /ver NametagEdit and post the output.
Can't, the plugin doesn't load. Using the latest NTE

What version of Bukkit/Spigot/PaperSpigot are you using? Type /ver
PaperSpigot 1.8

What plugins are you using? Type /plugins
LuckPerms, AllianceCore (custom plugin, using NTE API), Hubs (custom plugin), NameTagEdit, QuickBoard, FAWE

Please explain your issue. How do you trigger it?
I imported the NTE API using Maven into my plugin, and when loading up the server NTE does not load. The errors are listed below:

Are there any errors in the console? Please use: https://pastebin.com
https://pastebin.com/HTAgvusY

commented

It looks like you are initialising NTE from some other place (org.bukkit.plugin.InvalidPluginException: java.lang.IllegalArgumentException: Plugin already initialized!).

Ensure that you aren't somehow loading it from any of your other plugins

commented

I'm not?

commented

Without seeing any code I can't help you more than that.

commented

I haven't written any code, all I've done is imported NameTagEdit through the listed Maven repository and it doesn't work.

commented

To have done that you have written a plugin that runs, regardless if it has any functionality. This issue is very weird, and hasn't happened to me whenever I've used the API.

Can you show your plugin.yml of said plugin and also show the output of /pl in game?

commented

How would the plugin.yml or the output of /pl be relevant?
Also, I have written code. Just none that uses the NTE API

commented

They would be relevant because this is not an API bug. The API works perfectly fine and I am simply trying to help you fix your issue.

plugin.yml is relevant because you need to depend upon NametagEdit, and that could be causing some issues.

/pl is relevant because if it's not your plugin that's causing the issue (ie if you can disable your plugin and NTE still breaks) then it is another plugin that is causing it.

We can't help you if you don't give us anything to work with.

commented

How are you importing the NTE API? Because I believe when importing through Maven I am including the whole plugin source, not the API, and causing it to enable twice.

commented

Issue found. Turns out I have to add depend: [NametagEdit] in my plugin.yml as @AvrooVulcan said.