Project

General

Profile

Actions

Task #479

closed

Show more details on script execution exception

Added by Jan Helbich over 7 years ago. Updated about 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Ondrej Husník
Category:
Scripts
Target version:
Start date:
06/02/2017
Due date:
% Done:

100%

Estimated time:
Owner:

Description

Currently if groovy script fails its execution or throws an exception, the FE only shows something like:

GROOVY_SCRIPT_EXCEPTION (400:cde52b2a-9848-4e02-b340-62d8b03704bf)
Script has some errors: [Script has some errors: [eav attribute kodLdap is empty!]] (message:Script has some errors: [eav attribute kodLdap is empty!])

BE is not any better. Only exception message is shown, stacktrace is useless:

Caused by: eu.bcvsolutions.idm.core.api.exception.ResultCodeException: Script has some errors: [eav attribute *** is empty!]
        at eu.bcvsolutions.idm.core.model.service.impl.DefaultGroovyScriptService.evaluate(DefaultGroovyScriptService.java:70)
        at eu.bcvsolutions.idm.core.script.evaluator.AbstractScriptEvaluator.evaluate(AbstractScriptEvaluator.java:94)
        at eu.bcvsolutions.idm.core.script.evaluator.AbstractScriptEvaluator.evaluate(AbstractScriptEvaluator.java:114)
        at eu.bcvsolutions.idm.core.script.evaluator.AbstractScriptEvaluator$evaluate$0.call(Unknown Source)
        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)
        at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:150)
        at org.kohsuke.groovy.sandbox.GroovyInterceptor.onMethodCall(GroovyInterceptor.java:23)
        at org.kohsuke.groovy.sandbox.GroovyValueFilter.onMethodCall(GroovyValueFilter.java:58)
        at org.kohsuke.groovy.sandbox.impl.Checker$1.call(Checker.java:148)
        at org.kohsuke.groovy.sandbox.impl.Checker.checkedCall(Checker.java:145)

We need more info when script execution fails. Please provide:
  • script name if predefined script was used
  • line with error (if possible)
  • where was script applied, i.e. in what attribute transformation rule etc.

Related issues

Related to IdStory Identity Manager - Task #1719: Improve error messageClosedOndrej Husník06/12/2019

Actions
Actions #1

Updated by Jan Helbich over 7 years ago

  • Subject changed from Show more detail on script execution error to Show more details on script execution exception
Actions #2

Updated by Vít Švanda about 7 years ago

  • Target version deleted (Diamond (7.4.0))
Actions #3

Updated by Vladimír Kotýnek over 5 years ago

I beg for implementation of this feature. It would save us tens of hours of debuging!

Actions #4

Updated by Radek Tomiška over 4 years ago

  • Assignee changed from Vít Švanda to Ondrej Husník
Actions #5

Updated by Radek Tomiška over 4 years ago

  • Related to Task #1719: Improve error message added
Actions #6

Updated by Radek Tomiška about 4 years ago

  • Target version set to 10.6.0

I think, this ticket is solved by #1719, Ondra, can you check the requirement is implemented already, please?

Actions #7

Updated by Ondrej Husník about 4 years ago

This ticket is generalized form of #1719 where the rich error information was implemented for transformation scripts only. Other places with script areas (such as searching for tree roots during tree synchronization etc.) does not have this additional error information implemented. We decided, after consultation with Vitek, that other places does not need this rich error information.

Actions #8

Updated by Ondrej Husník about 4 years ago

  • Status changed from New to Resolved
  • % Done changed from 0 to 100
Actions #9

Updated by Radek Tomiška about 4 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF