
[Bug] Player invite/uninvite issue.
Remski01 opened this issue ยท 4 comments
Description of the Problem
Console gives an error, players cannot be uninvited from warps anymore once the server/plugin have been restarted.
Steps to Reproduce
1, Make an private warp.
2, invite an player.
3, restart the server/plugin (/warp reload)
4, You can now re-invite while the player can already warp to it.
4.1, You cannot un uninvite players anymore as they will still be enable to warp as well that /warp info shows them as invited. Trying to remove them will just say they have been removed or that player x isnt invited.
Log Output
[21:50:34 INFO]: Polski05 issued server command: /warp invite exowolf test
[21:50:34 WARN]: Exception in thread "pool-74-thread-5" io.github.mywarp.mywarp.internal.jooq.exception.DataAccessException: SQL [insert into "mywarp"."warp_player_map" ("warp_id", "player_id") values ((select "mywarp"."warp"."warp_id" from "mywarp"."warp" where "mywarp"."warp"."name" = cast(? as varchar(32)) limit ?), (select "mywarp"."player"."player_id" from "mywarp"."player" where "mywarp"."player"."uuid" = cast(? as uuid) limit ?))]; (Message 23505 not found); SQL statement:
[21:50:34 WARN]: insert into "mywarp"."warp_player_map" ("warp_id", "player_id") values ((select "mywarp"."warp"."warp_id" from "mywarp"."warp" where "mywarp"."warp"."name" = cast(? as varchar(32)) limit ?), (select "mywarp"."player"."player_id" from "mywarp"."player" where "mywarp"."player"."uuid" = cast(? as uuid) limit ?)) [23505-200]
[21:50:34 WARN]: at io.github.mywarp.mywarp.internal.jooq_3.14.4.H2.debug(Unknown Source)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.Tools.translate(Tools.java:2904)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.DefaultExecuteContext.sqlException(DefaultExecuteContext.java:757)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.AbstractQuery.execute(AbstractQuery.java:389)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.AbstractDelegatingQuery.execute(AbstractDelegatingQuery.java:119)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.warp.storage.JooqWarpStorage.lambda$addPlayerInvitation$5(JooqWarpStorage.java:313)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.DefaultDSLContext$3.run(DefaultDSLContext.java:615)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.DefaultDSLContext$3.run(DefaultDSLContext.java:612)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.DefaultDSLContext.lambda$transactionResult0$0(DefaultDSLContext.java:543)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.Tools$35$1.block(Tools.java:5215)
[21:50:34 WARN]: at java.base/java.util.concurrent.ForkJoinPool.unmanagedBlock(ForkJoinPool.java:3465)
[21:50:34 WARN]: at java.base/java.util.concurrent.ForkJoinPool.managedBlock(ForkJoinPool.java:3436)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.Tools$35.get(Tools.java:5212)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.DefaultDSLContext.transactionResult0(DefaultDSLContext.java:595)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.DefaultDSLContext.transactionResult(DefaultDSLContext.java:512)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.DefaultDSLContext.transaction(DefaultDSLContext.java:612)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.warp.storage.JooqWarpStorage.addPlayerInvitation(JooqWarpStorage.java:295)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.warp.storage.JooqWarpStorage.addInvitation(JooqWarpStorage.java:275)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.warp.storage.AsyncWritingWarpStorage.lambda$addInvitation$2(AsyncWritingWarpStorage.java:70)
[21:50:34 WARN]: at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
[21:50:34 WARN]: at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
[21:50:34 WARN]: at java.base/java.lang.Thread.run(Thread.java:833)
[21:50:34 WARN]: Caused by: io.github.mywarp.mywarp.internal.h2.jdbc.JdbcSQLIntegrityConstraintViolationException: (Message 23505 not found); SQL statement:
[21:50:34 WARN]: insert into "mywarp"."warp_player_map" ("warp_id", "player_id") values ((select "mywarp"."warp"."warp_id" from "mywarp"."warp" where "mywarp"."warp"."name" = cast(? as varchar(32)) limit ?), (select "mywarp"."player"."player_id" from "mywarp"."player" where "mywarp"."player"."uuid" = cast(? as uuid) limit ?)) [23505-200]
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.message.DbException.getJdbcSQLException(DbException.java:459)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.message.DbException.getJdbcSQLException(DbException.java:429)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.message.DbException.get(DbException.java:205)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.message.DbException.get(DbException.java:181)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.index.BaseIndex.getDuplicateKeyException(BaseIndex.java:103)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.mvstore.db.MVSecondaryIndex.checkUnique(MVSecondaryIndex.java:221)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.mvstore.db.MVSecondaryIndex.add(MVSecondaryIndex.java:196)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.mvstore.db.MVTable.addRow(MVTable.java:531)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.command.dml.Insert.insertRows(Insert.java:195)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.command.dml.Insert.update(Insert.java:151)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.command.CommandContainer.update(CommandContainer.java:198)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.command.Command.executeUpdate(Command.java:251)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.h2.jdbc.JdbcPreparedStatement.execute(JdbcPreparedStatement.java:240)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.tools.jdbc.DefaultPreparedStatement.execute(DefaultPreparedStatement.java:214)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.AbstractQuery.execute(AbstractQuery.java:458)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.AbstractDMLQuery.execute(AbstractDMLQuery.java:947)
[21:50:34 WARN]: at mywarp-bukkit-3.1.1-all.jar//io.github.mywarp.mywarp.internal.jooq.impl.AbstractQuery.execute(AbstractQuery.java:375)
[21:50:34 WARN]: ... 18 more
Affected Version
- MyWarp:
3.1.2-SNAPSHOT+GitHub_Action-b274.git-b695eb101e
- Minecraft and Bukkit Implementation:
git-Paper-196
Additional context
Have not been tested with an fresh database.Still broken.- (^ Tested with an older version, doubt it will change the result though)
Thanks, I was able to reproduce the issue. Like you mention, the issue is not limited to custom aliases. Rather, it seems like something is seriously wrong with storing/re-reading/handling invitations in/from the database.
I'll let you now when I have tracked down the issue - hopefully soon.
Thanks for the quick repons as well being quickly with reproducing the issue, and ya, thoughed it was related with the aliases. Although after all the typing it made no sense as i only then noticed the error was related to the database, as well that not reloading the database it worked fine.
Thank you so much for keeping the plugin updated โค๏ธ
Could you test the latest development build?