The Jacl statement upvar n X translates to the following meaning: use the variable X from n stack frames up. The Jacl upvar command has no equivalent syntax in Jython scripting language. The Jacl2Jython program converts Jacl upvar commands to global variables in the preliminary converted Jython scripts. This transformation might not be a syntactically equivalent conversion and can cause unexpected behaviors in the runtime of the preliminary converted Jython scripts. You need to manually verify and perhaps modify the preliminary conversion of the Jacl upvar commands to ensure the intended runtime results are maintained in the Jython scripts.
JACL: upvar x ==> JYTHON: global x #?PROBLEM? (jacl 123) UPVAR_RELATIVE_STACK is always \ converted as #0 global.You need to verify there are no existing global variables with the same variable name as specified in the upvar command. If there is such a case, the preliminary converted Jython script might not run as originally intended and you need to manually modify the preliminary converted Jython script to function as originally intended.
JACL: upvar #0 x ==> JYTHON: global x