Luohuayu / CatServer

高性能和高兼容性的1.12.2/1.16.5/1.18.2版本Forge+Bukkit+Spigot服务端 (A high performance and high compatibility 1.12.2/1.16.5/1.18.2 version Forge+Bukkit+Spigot server)
https://catmc.org
GNU Lesser General Public License v3.0
1.98k stars 211 forks source link

[1.16.5] 使用trmenu检测玩家背包物品时报错 #496

Closed McAZero closed 1 year ago

McAZero commented 2 years ago

Environment

Minecraft version(1.12.2/1.16.5/1.18.2): 1.16.5 Build version(Get from /version command): CatServer-1.16.5-76952803-server Mods/Plugins: TrMenu-3.1.12

Describe the bug (If there is an error, please attach the pastebin link) 报错:https://paste.ubuntu.com/p/zGz5x977MF/ 菜单:https://paste.ubuntu.com/p/g66HnXGzd3/

Expected behavior 无法判断玩家背包是否有要求的物品 To Reproduce 使用点击菜单图标时报错,在 paper-1.16.5-794 上使用正常 Screenshot/Video (If it doesn't exist you can ignore it)

Kotori0629 commented 2 years ago

发我一份测试用菜单,只要能触发报错就可以,QQ发我

McAZero commented 1 year ago

发我一份测试用菜单,只要能触发报错就可以,QQ发我

此BUG在最新版本的插件和服务端依然存在,我已QQ发给你很久了。

菜单:https://paste.ubuntu.com/p/DqNrFhWGyT/

Kotori0629 commented 1 year ago

image 哪儿报错了

Kotori0629 commented 1 year ago

image TrMenu版本:https://github.com/TrPlugins/TrMenu/actions/runs/3082840832

Kotori0629 commented 1 year ago

image

甚至加上了take-item,它依旧没有报错

McAZero commented 1 year ago

image

甚至加上了take-item,它依旧没有报错

经过测试在Windows10上不会出现,在Linux系统上运行会有。 我服务器是Ubuntu 20.04.5

McAZero commented 1 year ago

演示:https://www.bilibili.com/video/BV1LP411N7SB/

我先zzzzzzzzz了,等审核

Kotori0629 commented 1 year ago

于CentOS8/Ubuntu18.04/Debian11/Deepin20.7.1进行了测试,并没有复现你描述的问题

建议移除核心libraries依赖库后重新下载, 并通过FoxLaunch库文件检查后重新运行 有相关开发能力的话, 分支一个CatServer1.16.5后, 在运行时使用类加载器单独加载 org.openjdk.nashorn.internal.runtime.Context$AnonymousContextCodeInstaller

参考: https://github.com/Luohuayu/CatServer/blob/1.16.5/src/fmllauncher/java/foxlaunch/FoxServerLauncher.java#L26 这不会是一个好办法, 也未经过相关测试, 这可能并不会解决你的问题

McAZero commented 1 year ago

于CentOS8/Ubuntu18.04/Debian11/Deepin20.7.1进行了测试,并没有复现你描述的问题

建议移除核心libraries依赖库后重新下载, 并通过FoxLaunch库文件检查后重新运行 有相关开发能力的话, 分支一个CatServer1.16.5后, 在运行时使用类加载器单独加载 org.openjdk.nashorn.internal.runtime.Context$AnonymousContextCodeInstaller

参考: https://github.com/Luohuayu/CatServer/blob/1.16.5/src/fmllauncher/java/foxlaunch/FoxServerLauncher.java#L26 这不会是一个好办法, 也未经过相关测试, 这可能并不会解决你的问题

奇怪的是,他们是同一个文件夹,Windows10上是使用网络驱动器连接到Ubuntu文件夹的,不太可能是依赖库的问题。手上机器不多,刚刚又在CentOS-7.6.1810-x64上测试依然会报错就很奇怪。(依赖库是重新下载的 27`MANAV8(THL0SDR5G2 MP