I have a function(say method1) imports hashmap  in a python file (say file1.py) and it invokes another method (say method2) in another py file (file2.py) not having the import but method2 uses hashmap. When method1 is invoked inside WLST.sh, no problem. But when I invoke it as $MW_HOME/oracle_common/bin/wlst.sh file1.py
NameError: HashMap
Note: I can't modify file2.py as it already shipped to customer.
Thanks,
Ashok
When the name of the variable used to do something like print or use in some other expression without assigning the value for the variable before it was defined then WLST/Python will raises NameError.
Check that your HashMap varialbe assigned with value and then sent for other Python script.
Package importing issue in jython file