Solved Detect error in console [PeperSpigot 1.12+]

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.
Try to detect when / re reload config is given.
That is, if it is an INFO record.
You don't have to check the log level, you can also just check the message
 
The problem is how. I can not find the way, and in the documentation does not specify its use, nor an example. It's just a line and now.

Expression:
[the] log [message] level

Could it be used?
if log "[Skript]" is info:

I really do not understand, I've tried a lot and it does not work.
Skript-Logs will need a special version of Skript to work properly?
 
The problem is how. I can not find the way, and in the documentation does not specify its use, nor an example. It's just a line and now.

Expression:
[the] log [message] level

Could it be used?
if log "[Skript]" is info:

I really do not understand, I've tried a lot and it does not work.
Skript-Logs will need a special version of Skript to work properly?
You do NOT need to use log level. Use [the] log[ged] message to get the message. That's all you need to check
 
You do NOT need to use log level. Use [the] log[ged] message to get the message. That's all you need to check

It's what I understand about what you just told me.
Try the following but I do not think it's the right thing to do. And how could I do a conditional?

code_language.skript:
on log:
    the logged messange to ""
    # Code?

Error:
code_language.skript:
[10:16:09 ERROR]: Can't understand this condition/effect: the logged message to
"[Skript]" (Error.sk, line 2: the logged message to "[Skript]"')
 
It's what I understand about what you just told me.
Try the following but I do not think it's the right thing to do. And how could I do a conditional?

code_language.skript:
on log:
    the logged messange to ""
    # Code?

Error:
code_language.skript:
[10:16:09 ERROR]: Can't understand this condition/effect: the logged message to
"[Skript]" (Error.sk, line 2: the logged message to "[Skript]"')
Use something like this:
code_language.skript:
on log:
    logged message parsed as "java.lang.IllegalArgumentException: Team name '%text%' is already in use at org.apache.commons.lang.Validate.isTrue(Validate.java:136)" is set
    broadcast "error!"
 
Last edited:
Use something like this:
code_language.skript:
on log:
    logged message parsed as "java.lang.IllegalArgumentException: Team name '%text%' is already in use at org.apache.commons.lang.Validate.isTrue(Validate.java:136)"
    broadcast "error!"

I do not know if it's you or me but it keeps giving error. I copy the code as is and it does not work mark the following.

code_language.skript:
[23:05:04 ERROR]: Can't understand this condition/effect: logged message parsed
as "java.lang.IllegalArgumentException: Team name '%text%' is already in use at
org.apache.commons.lang.Validate.isTrue(Validate.java:136)" (Error.sk, line 2: l
ogged message parsed as "java.lang.IllegalArgumentException: Team name '%text%'
is already in use at org.apache.commons.lang.Validate.isTrue(Validate.java:136)"
')

After all, I do not know how to solve this, I'll have to try Java.
 
I do not know if it's you or me but it keeps giving error. I copy the code as is and it does not work mark the following.

code_language.skript:
[23:05:04 ERROR]: Can't understand this condition/effect: logged message parsed
as "java.lang.IllegalArgumentException: Team name '%text%' is already in use at
org.apache.commons.lang.Validate.isTrue(Validate.java:136)" (Error.sk, line 2: l
ogged message parsed as "java.lang.IllegalArgumentException: Team name '%text%'
is already in use at org.apache.commons.lang.Validate.isTrue(Validate.java:136)"
')

After all, I do not know how to solve this, I'll have to try Java.
Sorry, I forgot 2 words. I edited my message, try again
 
TPGamesNL said:
Sorry, I forgot 2 words. I edited my message, try again

I really know that it is very annoying. But I can not understand the proper functioning of ADDON Skriot-Logs.

Still causing error in the console:
code_language.skript:
[12:07:44] [Server thread/ERROR]: ': Team name '%text%' is already in use at org.apache.commons.lang.Validate.isTrue(Validate.java:136)"' is not a valid item data (Error.sk, line 2: logged message parsed as "java.lang.IllegalArgumentException: Team name '%text%' is already in use at org.apache.commons.lang.Validate.isTrue(Validate.java:136)" is set')

I do not try variants because I repeat, I do not understand the operation of the addon.
 
I really know that it is very annoying. But I can not understand the proper functioning of ADDON Skriot-Logs.

Still causing error in the console:
code_language.skript:
[12:07:44] [Server thread/ERROR]: ': Team name '%text%' is already in use at org.apache.commons.lang.Validate.isTrue(Validate.java:136)"' is not a valid item data (Error.sk, line 2: logged message parsed as "java.lang.IllegalArgumentException: Team name '%text%' is already in use at org.apache.commons.lang.Validate.isTrue(Validate.java:136)" is set')

I do not try variants because I repeat, I do not understand the operation of the addon.
Try
code_language.skript:
on log:
    set {_msg} to logged message
    set {_t::*} to {_msg} parsed as "java.lang.IllegalArgumentException: Team name %text% is already in use at org.apache.commons.lang.Validate.isTrue\(Validate.java:136\)"
    {_t::*} is set
    broadcast "error!"
 
Really, thank you very much for your help.
I already give up with Skript I do not see chances to detect errors.
I will try in some other way, or do you recommend to try with some specific Skript verification?

Show the console, so they can see if I have the required plugins.
Wla4TOr2T3WirQXLHwolZg.png
 
Okay last thing, I'll tag the creator of skript-logs hoping that he will look at the picture above and maybe he can help. @Blueyescat
 
These codes don't give any error with Skript 2.2-dev37c or 2.3.alpha5 with PaperSpigot 1.12.2-1.13.1. What Skript and server version you are using? (/ver and /ver skript) Anyway, you can't cancel the log event currently if you want to do. Already supressing that error wouldn't be a good idea, you should try to fix it.
 
Last edited:
  • Like
Reactions: sOxTw
Now I understand everything, I use PeperSpigot 1.8.x.
I do not try to suppress it, I only try to detect the eror to keep it in a variable and to know how many times it is executed per day.
Or restart the server if it is very recurrent.
The problem I'm having is that Spigot is in an old version for what I see.

The mime is happening to me with another problem with "% region at player%" It's as if I did not detect it.
For now I do not plan to update spigot because I'm doing well with compatibilities. Anyway, thank you very much for your help.
It is appreciated too.
A greeting.
 
Status
Not open for further replies.