com.glide.script.RhinoEcmaError: Method "toString" called on incompatible object.
This content was last updated in 2022. It may still be useful, but could contain outdated information. Please confirm its accuracy before relying on it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-07-2022 10:54 PM
I am calling the script include from BR and getting the below error
com.glide.script.RhinoEcmaError: Method "toString" called on incompatible object.
Script:
(function executeRule(current, previous /*null when async*/ ) {
// Add your code here
//gs.info('DC DevOps Fire BR');
DevOpsLogger.log('DC DevOps Fire BR');
gs.addInfoMessage('DC DevOps Fire BR start');
//var lt = new sn_devops.DevOpsPipelineExecutionDAO();
var lt = new DevOpsPipelineExecutionDAO();
gs.addInfoMessage('DC DevOps Fire BR lt '+lt);
var taskExecutionSysId = 'ffb445511b77495477cf98a98b4bcb79'; //TE0001921
lt.updateLeadTime(taskExecutionSysId);
gs.info('DC DevOps Fire BR end');
gs.addInfoMessage('DC DevOps Fire BR end');
})(current, previous);
Please assist me to overcome this issue.
Thanks,
Dinesh C
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-11-2022 10:21 PM
Hi,
don't call from background script
try to add gs.info() at appropriate places and debug
Regards
Ankur
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-07-2022 11:19 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-14-2022 12:56 PM
I had this same error. I ran my script include code in a background script. Then I received a cross-scope access policy. The root cause was actually cross-scope access.