Open RedCrafterHD opened 10 months ago
Can you please check your server logs for errors from the nameless plugin? And post those here?
Srry for the long wait, here:
16:14:12 [INFO] [RedCrafterHD] <-> ServerConnector [lobby] has connected
16:14:28 [WARNING] [NamelessMC] The website didn't return a valid json response. Run /nlpl last_error to retrieve the full stack trace.
16:15:02 [WARNING] [NamelessMC] com.namelessmc.plugin.lib.nameless-api.exception.NamelessException: Website returned invalid response with code 200.
Website response, after 219ms:
-----------------
ReportCreatedEvent::__construct(): Argument #1 ($username) must be of type string, null given, called in /var/www/homepage/core/classes/Misc/Report.php on line 62 in /var/www/homepage/modules/Core/classes/Events/ReportCreatedEvent.php on line 13
#0 /var/www/homepage/core/classes/Misc/Report.php(62): ReportCreatedEvent->__construct()
#1 /var/www/homepage/modules/Core/includes/endpoints/CreateReportEndpoint.php(83): Report::create()
#2 /var/www/homepage/core/classes/Endpoints/Endpoints.php(69): CreateReportEndpoint->execute()
#3 /var/www/homepage/modules/Core/classes/Misc/Nameless2API.php(52): Endpoints->handle()
#4 /var/www/homepage/modules/Core/pages/api/v2/index.php(23): Nameless2API->__construct()
#5 /var/www/homepage/index.php(133): require('...')
#6 {main}
at com.namelessmc.plugin.lib.nameless-api.RequestHandler.makeConnection(RequestHandler.java:219)
at com.namelessmc.plugin.lib.nameless-api.RequestHandler.post(RequestHandler.java:58)
at com.namelessmc.plugin.lib.nameless-api.NamelessUser.createReport(NamelessUser.java:286)
at com.namelessmc.plugin.common.command.ReportCommand.lambda$execute$0(ReportCommand.java:65)
at net.md_5.bungee.scheduler.BungeeTask.run(BungeeTask.java:63)
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:840)
Caused by: com.namelessmc.plugin.lib.gson.JsonSyntaxException: com.namelessmc.plugin.lib.gson.stream.MalformedJsonException: Use JsonReader.setLenient(true) to accept malformed JSON at line 1 column 20 path $
at com.namelessmc.plugin.lib.gson.JsonParser.parseReader(JsonParser.java:76)
at com.namelessmc.plugin.lib.gson.JsonParser.parseString(JsonParser.java:51)
at com.namelessmc.plugin.lib.nameless-api.RequestHandler.makeConnection(RequestHandler.java:187)
... 7 more
Caused by: com.namelessmc.plugin.lib.gson.stream.MalformedJsonException: Use JsonReader.setLenient(true) to accept malformed JSON at line 1 column 20 path $
at com.namelessmc.plugin.lib.gson.stream.JsonReader.syntaxError(JsonReader.java:1659)
at com.namelessmc.plugin.lib.gson.stream.JsonReader.checkLenient(JsonReader.java:1465)
at com.namelessmc.plugin.lib.gson.stream.JsonReader.doPeek(JsonReader.java:551)
at com.namelessmc.plugin.lib.gson.stream.JsonReader.peek(JsonReader.java:433)
at com.namelessmc.plugin.lib.gson.JsonParser.parseReader(JsonParser.java:71)
... 9 more
We also have the same error.
! [Thu 19:39:09 WARN NamelessMC] The website didn't return a valid json response. Run /nlpl last_error to retrieve the full stack trace.
[Thu 19:40:32 INFO Server/ServerGamePacketListenerImpl] KoalaServers issued server command: /nlpl last_error
[7:40 PM]
! [Thu 19:40:32 WARN NamelessMC] com.namelessmc.plugin.lib.nameless-api.exception.NamelessException: Website returned invalid response with code 200.
Website response, after 94ms:
-----------------
ReportCreatedEvent::__construct(): Argument #1 ($username) must be of type string, null given, called in /var/www/kingkoalanetwork.com/public_html/core/classes/Misc/Report.php on line 62 in /var/www/kingkoalanetwork.com/public_html/modules/Core/classes/Events/ReportCreatedEvent.php on line 13
#0 /var/www/kingkoalanetwork.com/public_html/core/classes/Misc/Report.php(62): ReportCreatedEvent->__construct()
#1 /var/www/kingkoalanetwork.com/public_html/modules/Core/includes/endpoints/CreateReportEndpoint.php(83): Report::create()
#2 /var/www/kingkoalanetwork.com/public_html/core/classes/Endpoints/Endpoints.php(69): CreateReportEndpoint->execute()
#3 /var/www/kingkoalanetwork.com/public_html/modules/Core/classes/Misc/Nameless2API.php(52): Endpoints->handle()
#4 /var/www/kingkoalanetwork.com/public_html/modules/Core/pages/api/v2/index.php(23): Nameless2API->__construct()
#5 /var/www/kingkoalanetwork.com/public_html/index.php(133): require('...')
#6 {main}
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.nameless-api.RequestHandler.makeConnection(RequestHandler.java:218)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.nameless-api.RequestHandler.post(RequestHandler.java:60)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.nameless-api.NamelessUser.createReport(NamelessUser.java:286)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.common.command.ReportCommand.lambda$execute$0(ReportCommand.java:65)
at org.bukkit.craftbukkit.scheduler.CraftTask.run(CraftTask.java:101)
at org.bukkit.craftbukkit.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:57)
at com.destroystokyo.paper.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:22)
at java.base/java.util.concurrent.ThreadPoolExecutor.r
[7:40 PM]
! [Thu 19:40:32 WARN NamelessMC] unWorker(ThreadPoolExecutor.java:1144)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
at java.base/java.lang.Thread.run(Thread.java:1583)
Caused by: com.namelessmc.plugin.lib.gson.JsonSyntaxException: com.namelessmc.plugin.lib.gson.stream.MalformedJsonException: Use JsonReader.setStrictness(Strictness.LENIENT) to accept malformed JSON at line 1 column 20 path $
See https://github.com/google/gson/blob/main/Troubleshooting.md#malformed-json
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.gson.JsonParser.parseReader(JsonParser.java:116)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.gson.JsonParser.parseString(JsonParser.java:92)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.nameless-api.RequestHandler.makeConnection(RequestHandler.java:186)
... 9 more
Caused by: com.namelessmc.plugin.lib.gson.stream.MalformedJsonException: Use JsonReader.setStrictness(Strictness.LENIENT) to accept malformed JSON at line 1 column 20 path $
See https://github.com/google/gson/blob/main/Troubleshooting.md#malformed-json
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.gson.stream.JsonReader.syntaxError(JsonReader.java:1754)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.gson.stream.JsonReader.checkLenient(JsonReader.java:1550)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.gson.stream.JsonReader.doPeek(JsonReader.java:625)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.gson.stream.JsonReader.peek(JsonReader.java:507)
at Nameless-Plugin-Spigot-3.4.1.jar//com.namelessmc.plugin.lib.gson.JsonParser.parseReader(JsonParser.java:111)
... 11 more
Describe the issue
Hey, i was testing some functions which at first worked fine, but when I tried /report i got an error in game but it was normally shown on the website.
NamelessMC Version
Development version
To Reproduce
I try to report someone and it works on the web end, but for some reason in MC i get "An error occured..."
Expected Behaviour
I was expection some kind of feedback, that i reported someone succsesfully
Screenshots
Additional Information
No response