Towny Classic

Towny Classic

3.2k Downloads

java.lang.IllegalArgumentException: CARROTS isn't an item

Techirion opened this issue · 5 comments

commented

What steps will reproduce the problem?

com.destroystokyo.paper.exception.ServerEventException: Could not pass event InventoryClickEvent to Towny v0.100.3.12
	at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:72)
	at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:131)
	at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:628)
	at net.minecraft.server.network.ServerGamePacketListenerImpl.handleContainerClick(ServerGamePacketListenerImpl.java:3217)
	at net.minecraft.network.protocol.game.ServerboundContainerClickPacket.handle(ServerboundContainerClickPacket.java:69)
	at net.minecraft.network.protocol.game.ServerboundContainerClickPacket.handle(ServerboundContainerClickPacket.java:33)
	at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$0(PacketUtils.java:56)
	at net.minecraft.server.TickTask.run(TickTask.java:18)
	at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:151)
	at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:24)
	at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1545)
	at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:201)
	at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:125)
	at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1522)
	at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1515)
	at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:135)
	at net.minecraft.server.MinecraftServer.managedBlock(MinecraftServer.java:1474)
	at net.minecraft.server.MinecraftServer.waitUntilNextTick(MinecraftServer.java:1481)
	at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1326)
	at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:331)
	at java.base/java.lang.Thread.run(Thread.java:1583)
Caused by: java.lang.IllegalArgumentException: CARROTS isn't an item
	at com.google.common.base.Preconditions.checkArgument(Preconditions.java:143)
	at org.bukkit.inventory.ItemStack.of(ItemStack.java:58)
	at org.bukkit.inventory.ItemStack.<init>(ItemStack.java:138)
	at org.bukkit.inventory.ItemStack.<init>(ItemStack.java:117)
	at org.bukkit.inventory.ItemStack.<init>(ItemStack.java:104)
	at org.bukkit.inventory.ItemStack.<init>(ItemStack.java:87)
	at Towny.jar//com.palmergames.bukkit.towny.utils.ResidentUtil.openGUIInventory(ResidentUtil.java:141)
	at Towny.jar//com.palmergames.bukkit.towny.listeners.TownyInventoryListener.onClick(TownyInventoryListener.java:129)
	at com.destroystokyo.paper.event.executor.asm.generated.GeneratedEventExecutor567.execute(Unknown Source)
	at org.bukkit.plugin.EventExecutor$2.execute(EventExecutor.java:77)
	at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:80)
	at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70)
	at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54)
	... 20 more

What is the expected output?

Not sure, I'm pretty sure we didn't add manually carrots anywhere in Towny config, but we did upgrade map and plugin a few times in between without resetting config (from 1.20.6 and Towny 100ish? to current versions)

Towny version

Towny v0.100.3.12

Server version

Paper 1.21.1 PaperMC/Paper@e08e667

Please use Pastebin.com to link the following files

  1. Your full server startup from the logs\latest.log:
  2. Your Towny config.yml:
  3. Your townyperms.yml:
  4. Your log's error:

(optional) If this is to do with permissions,
5. Your permissions file:

(optional) If this is to do with chat,
6. Your chatconfig.yml:
7. Your channels.yml:

commented

I will need to see your Towny config.yml.

commented

Carrots are part of the default farm block list, and we have a gui that attempts to show all the different allowed blocks
(for clarity, Material#CARROTS is the block that's placed down, Material#CARROT is the item you get in your inventory)

commented
commented

Carrots are part of the default farm block list, and we have a gui that attempts to show all the different allowed blocks (for clarity, Material#CARROTS is the block that's placed down, Material#CARROT is the item you get in your inventory)

Interesting, yea, somehow carrots got in this line...

allowedBlocks: COW_SPAWN_EGG,GOAT_SPAWN_EGG,MOOSHROOM_SPAWN_EGG,BAMBOO,BAMBOO_SAPLING,JUNGLE_LOG,JUNGLE_SAPLING,JUNGLE_LEAVES,OAK_LOG,OAK_SAPLING,OAK_LEAVES,BIRCH_LOG,BIRCH_SAPLING,BIRCH_LEAVES,ACACIA_LOG,ACACIA_SAPLING,ACACIA_LEAVES,DARK_OAK_LOG,DARK_OAK_SAPLING,DARK_OAK_LEAVES,SPRUCE_LOG,SPRUCE_SAPLING,SPRUCE_LEAVES,BEETROOTS,COCOA,CHORUS_PLANT,CHORUS_FLOWER,SWEET_BERRY_BUSH,KELP,SEAGRASS,TALL_SEAGRASS,GRASS,TALL_GRASS,FERN,LARGE_FERN,CARROTS,WHEAT,POTATOES,PUMPKIN,PUMPKIN_STEM,ATTACHED_PUMPKIN_STEM,NETHER_WART,COCOA,VINE,MELON,MELON_STEM,ATTACHED_MELON_STEM,SUGAR_CANE,CACTUS,ALLIUM,AZURE_BLUET,BLUE_ORCHID,CORNFLOWER,DANDELION,LILAC,LILY_OF_THE_VALLEY,ORANGE_TULIP,OXEYE_DAISY,PEONY,PINK_TULIP,POPPY,RED_TULIP,ROSE_BUSH,SUNFLOWER,WHITE_TULIP,WITHER_ROSE,CRIMSON_FUNGUS,CRIMSON_STEM,CRIMSON_HYPHAE,CRIMSON_ROOTS,MUSHROOM_STEM,NETHER_WART_BLOCK,BROWN_MUSHROOM,BROWN_MUSHROOM_BLOCK,RED_MUSHROOM,RED_MUSHROOM_BLOCK,SHROOMLIGHT,WARPED_FUNGUS,WARPED_HYPHAE,WARPED_ROOTS,WARPED_STEM,WARPED_WART_BLOCK,WEEPING_VINES_PLANT,WEEPING_VINES,NETHER_SPROUTS,SHEARS,MELON_SEEDS,MANGROVE_LEAVES,POTTED_ACACIA_SAPLING,CHERRY_SAPLING,TWISTING_VINES_PLANT,TORCHFLOWER,OAK_WOOD,SPRUCE_WOOD,FLOWERING_AZALEA_LEAVES,PINK_PETALS,AZALEA,SMALL_DRIPLEAF,PITCHER_POD,POTTED_BIRCH_SAPLING,POTTED_OAK_SAPLING,BAMBOO_BLOCK,TORCHFLOWER_SEEDS,PITCHER_PLANT,COCOA_BEANS,DARK_OAK_WOOD,POTTED_JUNGLE_SAPLING,POTTED_SPRUCE_SAPLING,CHERRY_WOOD,CHERRY_LOG,MANGROVE_LOG,PITCHER_CROP,CHERRY_LEAVES,JUNGLE_WOOD,PUMPKIN_SEEDS,SPORE_BLOSSOM,POTTED_CHERRY_SAPLING,FLOWERING_AZALEA,AZALEA_LEAVES,ACACIA_WOOD,MANGROVE_WOOD,WHEAT_SEEDS,BIG_DRIPLEAF,BIRCH_WOOD,POTTED_DARK_OAK_SAPLING,SEA_PICKLE,BEETROOT_SEEDS,CHORUS_FRUIT,MANGROVE_PROPAGULE

I'm pretty sure I didn't add this manually tho.

commented

They're in there by default so it's no surprise