The interpreter has to be located on the machine where the Agent is located.
At the end it is just a command line call of a temporarily created Script file.
You may use the ':
attach_res' function to copy the necessary (pyhon) interpreter file on the agent machine just before the script get executed.
This is an example with the Javascript interpreter:
:attach_res store.js, "*", "T", "N"
:set &cache_path
CLASSPATH=.:$CLASSPATH:&cache_path
export CLASSPATH
:BEGIN_EXT_INT JS
var name = "var1";
var value = "value";
: register_variable name, value
:END_EXT_INT JS
------------------------------
Sr. Solution Architect
Broadcom
------------------------------
Original Message:
Sent: 02-24-2020 03:18 AM
From: Dan Korsgaard Petersen
Subject: BEGIN_EXT_INT PYTHON
Thank you Carsten,
That helped (should have spotted that myself).
The grey-out was caused by the bang (!) in the print statement, apparently that's not allowed.
BTW. where should the ext interpreter, Python in this case, reside? On engine servers or on the server chosen for the Windows or Unix job?
Br. Dan
Original Message:
Sent: 02-21-2020 10:33 AM
From: Carsten Schmitz
Subject: BEGIN_EXT_INT PYTHON
Hey,
As per the manual, it's BEGIN_EXT_INTERPRETER (edit: typo) and END_EXT_INTERPRETER (singular, not plural).
I wonder if that has any effect on your greyed-out syntax woes?
Br,
Carsten
------------------------------
These contain very good advise on asking questions and describing supposed bugs (no, you do not need to go to StackExchange for Automic questions, but yes, the parts on asking detailed, useful questions ARE usually relevant):
http://www.catb.org/~esr/faqs/smart-questions.html
https://www.chiark.greenend.org.uk/~sgtatham/bugs.html
I will not respond to PM asking for help unless there's an actual reason to keep the discussion off of the public forums.
Original Message:
Sent: 02-21-2020 10:29 AM
From: Dan Korsgaard Petersen
Subject: BEGIN_EXT_INT PYTHON
Hi,
I'm trying to test the use of f.ex. Python external interpreter in v12.3, but I fail miserably.
I have added both Python and PHP as interpreters in UC_EXT_INTERPRETERS_WINDOWS in client 0.
Running this code in the process tab of a Windows job:
produces below error:
U02000254 Error found on completing data for task '2048838130', reason: '5 - Access is denied.'.
I note that the AWI for some reason cannot recognize :END_EXT_INTERPRETERS as a valid script command (it is greyed out) as opposed to the :BEGIN_EXT_INTERRETERS command.
When I comment line 3 out, line 5 is recognized as a command, but job now fails due to missing Python commands between BEGIN and END.
Any suggestions?
------------------------------
Kind regards,
Dan Petersen, aka Don P
------------------------------