Hi everyone, I found out that logs in Script Editor have duplicated records.
So logs look like that for every record:
2025-09-01 16:16:39,012 WARN [Project.ScriptName]: record name
2025-09-01 16:16:39,012 WARN [Project.ScriptName]: record name
The same problem occurs for every script located in Script Editor.
On the other hand if I run script via Script Console, I don't have this issue.
Is there any way to fix it? Unfortunately I could not find the solution on my own.
assuming you are using Scriptrunner Plugin it would be helpful to have some more details about it in order to find the real problem/solution:
Thanks in advance.
Best
Stefan
Hi @Stefan Salzl
I found this issue at postfunctions and jobs. And it is definitely reproduced for several scripts, so there's no dependency between scripts and so on.
How does it look for job log:
Recently Jira restart occurred but I doubt that it could be a reason for the issue.
Please let me know if any additional info is required.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Could you please describe the use case where your script is used and show more relateable details of logs and also the description what it is doing.
I have a similar behaviour in my environment and figured out why:
eg. I had a post-function (that writes a log) but also updates the issue with some "scripted fields". These scripted fields also have some log-actions and on update they all occured within the log of the activation (post-function).
Therefore my questions and requests of detailed information.
Best
Stefan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
further question:
are you using any custom logger? see the following documentation:
https://docs.adaptavist.com/sr4js/8.8.1/best-practices/logging/advanced-logging
and following forum entry:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Stefan Salzl
So I found this issue at two different post-function script written by me, both are located between "Add a comment to an issue if one is entered during a transition" and "Update change history for an issue and store the issue in the database" options, Also same bug was found at one of Jobs.
I dont have any scripted fields, First postfunction updates Assets field value and second one assigns an issue to specific user if some conditions passed.
So it is reproduced for quite different cases.
To be honest I don't know how logs could be helpful in this case, nothing changed, any log is recorded twice, please take a look at one more example
2025-09-02 10:03:41,564 WARN [Project.DataToSet]: It's a wrong group, stop
2025-09-02 10:03:41,564 WARN [Project.DataToSet]: It's a wrong group, stop
And yes, I use custom logger and it worked perfectly couple if weeks ago
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Do you have sysadmin permission to the server?
It´s not only to set on the script level. If I got the documentation right it´s about when the system is configured to write scriptrunner actions/logs in a separate file (not the common atlassian.log)
The things described in the documentation needs to be configured on the server.
The logger is configured in your log4j.properties file. This file can be found by default at WEB-INF/classes path within your JIRA_HOME directory
Best
Stefan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Stefan Salzl
I guess this link will be helpful for me, but I am not sure when approximately file can be edited because I have to approve Jira restart in advance so currently I even don't know when I can try it.
So I will definitely reply you but I don't know when exactly :)
Regards,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
awesome. At least it seems we got a step forward.
Looking forward to your reply.
Best
Stefan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.