Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] StackTrace when defining names of inventory types #5923

Open
1 task done
Fusezion opened this issue Aug 19, 2023 · 4 comments
Open
1 task done

[BUG] StackTrace when defining names of inventory types #5923

Fusezion opened this issue Aug 19, 2023 · 4 comments
Labels
bug An issue that needs to be fixed. Alternatively, a PR fixing an issue. PR available Issues which have a yet-to-be merged PR resolving it priority: low Issues that are not harmful to the experience but are related to useful changes or additions.

Comments

@Fusezion
Copy link
Contributor

Fusezion commented Aug 19, 2023

Skript/Server Version

[19:12:28 INFO]: [Skript] Skript's aliases can be found here: https://github.com/SkriptLang/skript-aliases
[19:12:28 INFO]: [Skript] Skript's documentation can be found here: https://docs.skriptlang.org/
[19:12:28 INFO]: [Skript] Skript's tutorials can be found here: https://docs.skriptlang.org/tutorials
[19:12:28 INFO]: [Skript] Server Version: git-Paper-126 (MC: 1.20.1)
[19:12:28 INFO]: [Skript] Skript Version: 2.8.0-dev (selfbuilt-unknown)
[19:12:28 INFO]: [Skript] Installed Skript Addons:
[19:12:28 INFO]: [Skript]  - skript-gui v1.3 (https://github.com/APickledWalrus/skript-gui)
[19:12:28 INFO]: [Skript]  - skript-reflect v2.3.1-for-skript-beta (https://github.com/TPGamesNL/skript-reflect)
[19:12:28 INFO]: [Skript]  - SkBee v2.16.1 (https://github.com/ShaneBeee/SkBee)
[19:12:28 INFO]: [Skript] Installed dependencies:
[19:12:28 INFO]: [Skript]  - Vault v1.7.3-b131

Bug Description

When attempting to rename select inventories the server is unable to name them and instead throws an ArrayStoreException

Expected Behavior

No error to occure in console and to be given a inventory with my requested name

Steps to Reproduce

command /test:
  trigger:
    set {_inv} to shulker box inventory named name of player's tool

Errors or Screenshots

[19:07:05 ERROR]: #!#! java.lang.ArrayStoreException: org.bukkit.event.inventory.InventoryType
[19:07:05 ERROR]: #!#!     at Skript.jar//org.skriptlang.skript.lang.converter.Converters.convert(Converters.java:480)
[19:07:05 ERROR]: #!#!     at Skript.jar//org.skriptlang.skript.lang.converter.Converters.convertUnsafe(Converters.java:542)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.registrations.Converters.convertUnsafe(Converters.java:203)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.expressions.base.PropertyExpression.get(PropertyExpression.java:119)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.expressions.ExprNamed.get(ExprNamed.java:74)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.expressions.base.PropertyExpression.get(PropertyExpression.java:88)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.util.SimpleExpression.getArray(SimpleExpression.java:101)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.effects.EffChange.execute(EffChange.java:272)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.Effect.run(Effect.java:50)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:62)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:90)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.Trigger.execute(Trigger.java:52)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.function.ScriptFunction.execute(ScriptFunction.java:86)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.function.Function.execute(Function.java:129)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.function.FunctionReference.execute(FunctionReference.java:301)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.function.EffFunctionCall.execute(EffFunctionCall.java:52)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.Effect.run(Effect.java:50)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:62)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.TriggerItem.walk(TriggerItem.java:90)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.lang.Trigger.execute(Trigger.java:52)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.SkriptEventHandler.check(SkriptEventHandler.java:146)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.SkriptEventHandler.access$000(SkriptEventHandler.java:50)
[19:07:05 ERROR]: #!#!     at Skript.jar//ch.njol.skript.SkriptEventHandler$PriorityListener.lambda$new$0(SkriptEventHandler.java:63)
[19:07:05 ERROR]: #!#!     at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:81)
[19:07:05 ERROR]: #!#!     at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70)
[19:07:05 ERROR]: #!#!     at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54)
[19:07:05 ERROR]: #!#!     at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:126)
[19:07:05 ERROR]: #!#!     at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:615)
[19:07:05 ERROR]: #!#!     at org.bukkit.craftbukkit.v1_20_R1.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:591)
[19:07:05 ERROR]: #!#!     at org.bukkit.craftbukkit.v1_20_R1.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:548)
[19:07:05 ERROR]: #!#!     at org.bukkit.craftbukkit.v1_20_R1.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:542)
[19:07:05 ERROR]: #!#!     at org.bukkit.craftbukkit.v1_20_R1.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:538)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.network.PlayerConnection.a(PlayerConnection.java:2061)
[19:07:05 ERROR]: #!#!     at net.minecraft.network.protocol.game.PacketPlayInBlockPlace.a(PacketPlayInBlockPlace.java:32)
[19:07:05 ERROR]: #!#!     at net.minecraft.network.protocol.game.PacketPlayInBlockPlace.a(PacketPlayInBlockPlace.java:8)
[19:07:05 ERROR]: #!#!     at net.minecraft.network.protocol.PlayerConnectionUtils.lambda$ensureRunningOnSameThread$0(PlayerConnectionUtils.java:51)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.TickTask.run(TickTask.java:18)
[19:07:05 ERROR]: #!#!     at net.minecraft.util.thread.IAsyncTaskHandler.d(IAsyncTaskHandler.java:153)
[19:07:05 ERROR]: #!#!     at net.minecraft.util.thread.IAsyncTaskHandlerReentrant.d(IAsyncTaskHandlerReentrant.java:24)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.MinecraftServer.b(MinecraftServer.java:1339)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:197)
[19:07:05 ERROR]: #!#!     at net.minecraft.util.thread.IAsyncTaskHandler.x(IAsyncTaskHandler.java:126)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.MinecraftServer.bg(MinecraftServer.java:1316)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.MinecraftServer.x(MinecraftServer.java:1309)
[19:07:05 ERROR]: #!#!     at net.minecraft.util.thread.IAsyncTaskHandler.c(IAsyncTaskHandler.java:136)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.MinecraftServer.p_(MinecraftServer.java:1287)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:1175)
[19:07:05 ERROR]: #!#!     at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:318)
[19:07:05 ERROR]: #!#!     at java.base/java.lang.Thread.run(Thread.java:1623)
[19:07:05 ERROR]: #!#!
[19:07:05 ERROR]: #!#! Version Information:
[19:07:05 ERROR]: #!#!   Skript: 2.8.0-dev (custom version)
[19:07:05 ERROR]: #!#!     Flavor: selfbuilt-unknown
[19:07:05 ERROR]: #!#!     Date: unknown
[19:07:05 ERROR]: #!#!   Bukkit: 1.20.1-R0.1-SNAPSHOT
[19:07:05 ERROR]: #!#!   Minecraft: 1.20.1
[19:07:05 ERROR]: #!#!   Java: 20.0.2 (Java HotSpot(TM) 64-Bit Server VM 20.0.2+9-78)
[19:07:05 ERROR]: #!#!   OS: Windows 10 amd64 10.0
[19:07:05 ERROR]: #!#!
[19:07:05 ERROR]: #!#! Server platform: Paper
[19:07:05 ERROR]: #!#!
[19:07:05 ERROR]: #!#! Current node: null
[19:07:05 ERROR]: #!#! Current item: set {_inv} (as java.lang.Object) to [[inventorytype:shulker box inventory]] named the name of {_item}
[19:07:05 ERROR]: #!#! Current trigger: function BSB_Open (simple event) (test.sk, line 113)
[19:07:05 ERROR]: #!#!
[19:07:05 ERROR]: #!#! Thread: Server thread
[19:07:05 ERROR]: #!#!
[19:07:05 ERROR]: #!#! Language: english
[19:07:05 ERROR]: #!#! Link parse mode: STRICT
[19:07:05 ERROR]: #!#!
[19:07:05 ERROR]: #!#! End of Error.
[19:07:05 ERROR]: #!#!

Other

this isn't limited to only shulker box inventory as it also occures when using loom I have not tested to see what converter is causing this issue at least it appears to be a converter

Agreement

  • I have read the guidelines above and affirm I am following them with this report.
@Fusezion
Copy link
Contributor Author

Fusezion commented Aug 19, 2023

This issue is caused only when not using strings like "" i.e. name of player's tool or {_null}
using stuff like "%name of player's tool%" and "Pear" all work as expected

@Fusezion

This comment was marked as off-topic.

@Fusezion
Copy link
Contributor Author

Reopening as this is not related to skript-gui and my inability to debug things getting the better of me.

@Fusezion Fusezion reopened this Aug 20, 2023
@Fusezion Fusezion changed the title [BUG] StackTrace when setting name of select inventory types [BUG] StackTrace when defining names of inventory types Aug 20, 2023
@AyhamAl-Ali AyhamAl-Ali added bug An issue that needs to be fixed. Alternatively, a PR fixing an issue. priority: low Issues that are not harmful to the experience but are related to useful changes or additions. labels Aug 20, 2023
@AyhamAl-Ali
Copy link
Member

Low priority only because it's a specific case (unless it's deeper than that) and has an easy temp fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An issue that needs to be fixed. Alternatively, a PR fixing an issue. PR available Issues which have a yet-to-be merged PR resolving it priority: low Issues that are not harmful to the experience but are related to useful changes or additions.
Projects
None yet
Development

No branches or pull requests

3 participants