this seems to be a little strange. I am having some print statements in my python script which I run via Batch job.
The problem is with the print statements I tried every thing possible but its still throwing a Invalid Syntax error.
print STDERR 'Kapil >> BEFORE INSERT';
print STDERR 'Kapil tag_id >> $tag_id';
print STDERR 'Kapil Hostname >> $hostname';
I have to give STDERR to print the statements in job out file. Otherwise nothing is getting printed.
File "/d/home/aprun-prologue/aprun-prologue", line 169
print STDERR 'Kapil >> BEFORE INSERT \n';
^
SyntaxError: invalid syntax
Thanks, Kapil
import sys
print >>sys.stderr, 'Kapil >> BEFORE INSERT'
print >>sys.stderr, 'Kapil tag_id >> $tag_id'
print >>sys.stderr, 'Kapil Hostname >> $hostname'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With