kangarko / ChatControl-Red

Issue tracker and documentation for the next generation ChatControl Red, the most advanced chat management plugin.
49 stars 23 forks source link

1.19: ClassCastException #1967

Closed MADS0LADEN closed 2 years ago

MADS0LADEN commented 2 years ago

Minecraft Version: 1.19 MySQL: true BungeeCord: true

I sometimes get this error when people chat

------------------------------------[ 05.07.2022 01:33:52 ]-----------------------------------
ChatControlRed 10.12.1 encountered a ClassCastException
Running Purpur 1.19-R0.1-SNAPSHOT and Java 17.0.3
Plugins: Watson v1.0.1, PlaceholderAPI v2.11.2, HolographicDisplays v3.0.0-SNAPSHOT-b225, ServerUtils v3.5.1, LuckPerms v5.4.30, Harbor v1.6.3, Playtime v3.0.3, squaremap v1.1.6, OpenInv v4.2.0, MineSecure v1.3.7-SNAPSHOT, spark v1.9.23, BuycraftX v12.0.8, Votifier v2.7.3, ProtocolLib v5.0.0-SNAPSHOT-b573, Vault v1.7.3-b131, Chunky v1.2.217, WorldEdit v7.2.11-beta-01+6200-0877589, HeadDatabase v4.17.0, XConomy v2.18.14, LiteBans v2.9.5, Multiverse-Core v4.3.1-b861, PhoenixCrates v1.2, DeluxeMenus v1.13.5-Release, TAB v3.1.2, WorldGuard v7.0.8-SNAPSHOT+2201-6efdb10, EntityDetection v1.2.0 (build #23), AuctionHouse v3.3.1, CoreProtect v21.2, WorldGuardExtraFlags v4.2.0, Citizens v2.0.30-SNAPSHOT (build 2596), CraftBook v3.10.7;4761-11ee8f6, mcMMO v2.1.214, GriefPrevention v16.18, ChestShop v3.12.2 (build 353), ChatControlRed v10.12.1, AdvancedRegionMarket v3.3.7, BetterRTP v3.4.4, Skript v2.6.2, PremiumVanish v2.7.15, PlayerWarps v6.17.3, MarriageMaster v2.6.5-Release, CMILib v1.2.1.0, Jobs v5.1.0.0, ChestShopNotifier v1.3.3 (build 51), squaremap-griefprevention v1.0.0-SNAPSHOT, Plan v5.4 build 1722, skript-placeholders v1.5.2, skript-reflect v2.2.2-dev, MorphRedeem v1.2.3, skRayFall v1.9.27, SkBee v1.16.3, skript-yaml v1.4, SelectionVisualizer v3.2.0.0
----------------------------------------------------------------------------------------------

More Information: 
Failed to serialize to json, unparsed data: {Current_Component={
    'Inherit_Formatting' = '{"text":"Godnat :D"}'
}, Past_Components=[{
    'Hover_Event' = '{"Action":"SHOW_TEXT","Value":"{\"extra\":[{\"text\":\"flpm_944c048d-9a72-4e16-8927-8e0925ca1f46 flps_77a5f0e0-9435-42bd-8857-9ae32f60c19c\"}],\"text\":\"\"}"}'
}, {
}, {
    'Text' = '§4*§r'
    'View_Permission' = 'chatcontrol.removemessages'
    'Hover_Event' = '{"Action":"SHOW_TEXT","Value":"{\"extra\":[{\"color\":\"red\",\"text\":\"Slet denne besked for alle spillere.\\n\"},{\"color\":\"dark_gray\",\"text\":\"05\/07\/2022 01:33:51.955\"}],\"text\":\"\"}"}'
    'Click_Event' = '{"Action":"RUN_COMMAND","Value":"\/chc internal remove 944c048d-9a72-4e16-8927-8e0925ca1f46"}'
}, {
    'Text' = '[§d❤§f] '
    'Hover_Event' = '{"Action":"SHOW_TEXT","Value":"{\"extra\":[{\"color\":\"gray\",\"text\":\"Info om \"},{\"color\":\"aqua\",\"text\":\"LesbianLover3\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Ranks: \"},{\"color\":\"white\",\"text\":\"[\"},{\"bold\":true,\"color\":\"blue\",\"text\":\"Mod\"},{\"color\":\"white\",\"text\":\"] \"},{\"color\":\"blue\",\"text\":\" \\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Gift med: \"},{\"color\":\"light_purple\",\"text\":\"Lykkemark\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Penge: \"},{\"color\":\"gold\",\"text\":\"⛃\"},{\"color\":\"white\",\"text\":\"30.464.32\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Dødsfald: \"},{\"bold\":true,\"color\":\"red\",\"text\":\"4\\n\\n \"},{\"italic\":true,\"color\":\"gray\",\"text\":\"Tryk for at sende spilleren\\n \"},{\"italic\":true,\"color\":\"gray\",\"text\":\"en privat besked...\"}],\"text\":\"\"}"}'
    'Click_Event' = '{"Action":"SUGGEST_COMMAND","Value":"\/msg LesbianLover3 "}'
    'Inherit_Formatting' = '{"color":"white","clickEvent":{"action":"run_command","value":"/chc internal remove 944c048d-9a72-4e16-8927-8e0925ca1f46"},"hoverEvent":{"action":"show_text","value":[{"extra":[{"color":"red","text":"Slet denne besked for alle spillere.\n"},{"color":"dark_gray","text":"05/07/2022 01:33:51.955"}],"text":""}]},"text":""}'
}, {
    'Text' = '§f[§4§k|§b§l25§6✯§4§k|§f] §f'
    'Hover_Event' = '{"Action":"SHOW_TEXT","Value":"{\"extra\":[{\"color\":\"gray\",\"text\":\"Info om \"},{\"color\":\"aqua\",\"text\":\"LesbianLover3\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Ranks: \"},{\"color\":\"white\",\"text\":\"[\"},{\"bold\":true,\"color\":\"blue\",\"text\":\"Mod\"},{\"color\":\"white\",\"text\":\"] \"},{\"color\":\"blue\",\"text\":\" \\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Gift med: \"},{\"color\":\"light_purple\",\"text\":\"Lykkemark\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Penge: \"},{\"color\":\"gold\",\"text\":\"⛃\"},{\"color\":\"white\",\"text\":\"30.464.32\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Dødsfald: \"},{\"bold\":true,\"color\":\"red\",\"text\":\"4\\n\\n \"},{\"italic\":true,\"color\":\"gray\",\"text\":\"Tryk for at sende spilleren\\n \"},{\"italic\":true,\"color\":\"gray\",\"text\":\"en privat besked...\"}],\"text\":\"\"}"}'
    'Click_Event' = '{"Action":"SUGGEST_COMMAND","Value":"\/msg LesbianLover3 "}'
    'Inherit_Formatting' = '{"color":"white","clickEvent":{"action":"suggest_command","value":"/msg LesbianLover3 "},"hoverEvent":{"action":"show_text","value":[{"extra":[{"color":"gray","text":"Info om "},{"color":"aqua","text":"LesbianLover3\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Ranks: "},{"color":"white","text":"["},{"bold":true,"color":"blue","text":"Mod"},{"color":"white","text":"] "},{"color":"blue","text":" \n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Gift med: "},{"color":"light_purple","text":"Lykkemark\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Penge: "},{"color":"gold","text":"⛃"},{"color":"white","text":"30.464.32\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Dødsfald: "},{"bold":true,"color":"red","text":"4\n\n "},{"italic":true,"color":"gray","text":"Tryk for at sende spilleren\n "},{"italic":true,"color":"gray","text":"en privat besked..."}],"text":""}]},"text":"] "}'
}, {
    'Text' = '§f[§9§lMod§f] §9'
    'Hover_Event' = '{"Action":"SHOW_TEXT","Value":"{\"extra\":[{\"color\":\"gray\",\"text\":\"Info om \"},{\"color\":\"aqua\",\"text\":\"LesbianLover3\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Ranks: \"},{\"color\":\"white\",\"text\":\"[\"},{\"bold\":true,\"color\":\"blue\",\"text\":\"Mod\"},{\"color\":\"white\",\"text\":\"] \"},{\"color\":\"blue\",\"text\":\" \\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Gift med: \"},{\"color\":\"light_purple\",\"text\":\"Lykkemark\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Penge: \"},{\"color\":\"gold\",\"text\":\"⛃\"},{\"color\":\"white\",\"text\":\"30.464.32\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Dødsfald: \"},{\"bold\":true,\"color\":\"red\",\"text\":\"4\\n\\n \"},{\"italic\":true,\"color\":\"gray\",\"text\":\"Tryk for at sende spilleren\\n \"},{\"italic\":true,\"color\":\"gray\",\"text\":\"en privat besked...\"}],\"text\":\"\"}"}'
    'Click_Event' = '{"Action":"SUGGEST_COMMAND","Value":"\/msg LesbianLover3 "}'
    'Inherit_Formatting' = '{"color":"white","clickEvent":{"action":"suggest_command","value":"/msg LesbianLover3 "},"hoverEvent":{"action":"show_text","value":[{"extra":[{"color":"gray","text":"Info om "},{"color":"aqua","text":"LesbianLover3\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Ranks: "},{"color":"white","text":"["},{"bold":true,"color":"blue","text":"Mod"},{"color":"white","text":"] "},{"color":"blue","text":" \n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Gift med: "},{"color":"light_purple","text":"Lykkemark\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Penge: "},{"color":"gold","text":"⛃"},{"color":"white","text":"30.464.32\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Dødsfald: "},{"bold":true,"color":"red","text":"4\n\n "},{"italic":true,"color":"gray","text":"Tryk for at sende spilleren\n "},{"italic":true,"color":"gray","text":"en privat besked..."}],"text":""}]},"text":""}'
}, {
    'Text' = '§4§lL§c§le§6§ls§e§lb§2§li§a§la§b§ln§3§lL§9§lo§1§lv§5§le§d§lr'
    'Hover_Event' = '{"Action":"SHOW_TEXT","Value":"{\"extra\":[{\"color\":\"gray\",\"text\":\"Info om \"},{\"color\":\"aqua\",\"text\":\"LesbianLover3\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Ranks: \"},{\"color\":\"white\",\"text\":\"[\"},{\"bold\":true,\"color\":\"blue\",\"text\":\"Mod\"},{\"color\":\"white\",\"text\":\"] \"},{\"color\":\"blue\",\"text\":\" \\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Gift med: \"},{\"color\":\"light_purple\",\"text\":\"Lykkemark\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Penge: \"},{\"color\":\"gold\",\"text\":\"⛃\"},{\"color\":\"white\",\"text\":\"30.464.32\\n \"},{\"bold\":true,\"color\":\"dark_aqua\",\"text\":\"| \"},{\"color\":\"gray\",\"text\":\"Dødsfald: \"},{\"bold\":true,\"color\":\"red\",\"text\":\"4\\n\\n \"},{\"italic\":true,\"color\":\"gray\",\"text\":\"Tryk for at sende spilleren\\n \"},{\"italic\":true,\"color\":\"gray\",\"text\":\"en privat besked...\"}],\"text\":\"\"}"}'
    'Click_Event' = '{"Action":"SUGGEST_COMMAND","Value":"\/msg LesbianLover3 "}'
    'Inherit_Formatting' = '{"color":"blue","clickEvent":{"action":"suggest_command","value":"/msg LesbianLover3 "},"hoverEvent":{"action":"show_text","value":[{"extra":[{"color":"gray","text":"Info om "},{"color":"aqua","text":"LesbianLover3\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Ranks: "},{"color":"white","text":"["},{"bold":true,"color":"blue","text":"Mod"},{"color":"white","text":"] "},{"color":"blue","text":" \n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Gift med: "},{"color":"light_purple","text":"Lykkemark\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Penge: "},{"color":"gold","text":"⛃"},{"color":"white","text":"30.464.32\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Dødsfald: "},{"bold":true,"color":"red","text":"4\n\n "},{"italic":true,"color":"gray","text":"Tryk for at sende spilleren\n "},{"italic":true,"color":"gray","text":"en privat besked..."}],"text":""}]},"text":""}'
}, {
    'Text' = '§r: '
    'Inherit_Formatting' = '{"bold":true,"color":"light_purple","clickEvent":{"action":"suggest_command","value":"/msg LesbianLover3 "},"hoverEvent":{"action":"show_text","value":[{"extra":[{"color":"gray","text":"Info om "},{"color":"aqua","text":"LesbianLover3\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Ranks: "},{"color":"white","text":"["},{"bold":true,"color":"blue","text":"Mod"},{"color":"white","text":"] "},{"color":"blue","text":" \n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Gift med: "},{"color":"light_purple","text":"Lykkemark\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Penge: "},{"color":"gold","text":"⛃"},{"color":"white","text":"30.464.32\n "},{"bold":true,"color":"dark_aqua","text":"| "},{"color":"gray","text":"Dødsfald: "},{"bold":true,"color":"red","text":"4\n\n "},{"italic":true,"color":"gray","text":"Tryk for at sende spilleren\n "},{"italic":true,"color":"gray","text":"en privat besked..."}],"text":""}]},"text":"r"}'
}, {
    'Inherit_Formatting' = '{"color":"white","text":": "}'
}, {
    'Text' = 'Godnat :D'
}]}
ClassCastException class org.mineacademy.chatcontrol.lib.jsonsimple.JSONObject cannot be cast to class java.lang.String (org.mineacademy.chatcontrol.lib.jsonsimple.JSONObject is in unnamed module of loader 'ChatControl-Red-10.12.1.jar' @3ff70896; java.lang.String is in module java.base of loader 'bootstrap')
     at ChatControl-Red-10.12.1.jar//org.mineacademy.chatcontrol.lib.jsonsimple.JSONParser.inPassedPairKey(JSONParser.java:323)
     at ChatControl-Red-10.12.1.jar//org.mineacademy.chatcontrol.lib.jsonsimple.JSONParser.parse(JSONParser.java:494)
     at ChatControl-Red-10.12.1.jar//org.mineacademy.chatcontrol.lib.jsonsimple.JSONParser.parse(JSONParser.java:447)
     at ChatControl-Red-10.12.1.jar//org.mineacademy.chatcontrol.lib.SerializeUtil.serialize(SerializeUtil.java:252)
     at ChatControl-Red-10.12.1.jar//org.mineacademy.chatcontrol.lib.collection.SerializedMap.toJson(SerializedMap.java:974)
     at ChatControl-Red-10.12.1.jar//org.mineacademy.chatcontrol.model.Channel.sendBungeeAndDiscord(Channel.java:683)
     at ChatControl-Red-10.12.1.jar//org.mineacademy.chatcontrol.model.Channel.lambda$sendMessage$1(Channel.java:614)
     at org.bukkit.craftbukkit.v1_19_R1.scheduler.CraftTask.run(CraftTask.java:101)
     at org.bukkit.craftbukkit.v1_19_R1.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:57)
     at com.destroystokyo.paper.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:22)
     at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
     at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
     at java.base/java.lang.Thread.run(Thread.java:833)
----------------------------------------------------------------------------------------------
kangarko commented 2 years ago

Thank you, I will fix that!