Yes, you can read a file within a STAX job <script> element using Python 
file read methods or Java file read methods.  Or, you can get the contents 
of a file on the local or remote machine using the STAF FS GET service via 
a <stafcmd> element. 

--------------------------------------------------------------
Sharon Lucas
IBM Austin,   [EMAIL PROTECTED]
(512) 838-8347 or Tieline 678-8347




"Chi Wang" <[EMAIL PROTECTED]> 
Sent by: [EMAIL PROTECTED]
06/26/2008 01:54 PM

To
Sharon Lucas/Austin/[EMAIL PROTECTED]
cc
staf-users@lists.sourceforge.net
Subject
Re: [staf-users] Error on "from configobj import ConfigObj" in stax






Thanks, Sharon! Is there any other way to read config file in stax?
 
Thanks,
Chi
 

From: Sharon Lucas [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 26, 2008 11:46 AM
To: Chi Wang
Cc: staf-users@lists.sourceforge.net
Subject: Re: [staf-users] Error on "from configobj import ConfigObj" in 
stax
 

STAX uses Jython 2.1 (which is based on Python 2.1), as documented in the 
STAX User's Guide. 
ConfigObj requires Python 2.2 or later, thus, it does not work with Jython 
2.1.

--------------------------------------------------------------
Sharon Lucas
IBM Austin,   [EMAIL PROTECTED]
(512) 838-8347 or Tieline 678-8347



"Chi Wang" <[EMAIL PROTECTED]> 
Sent by: [EMAIL PROTECTED] 
06/26/2008 01:30 PM 


To
<staf-users@lists.sourceforge.net> 
cc
 
Subject
[staf-users] Error on "from configobj import ConfigObj" in stax
 


 
 




I want to read configuration file in stax and downloaded configobj module 
from web. Here is my code. I have configobj in my c drive. 
  
************************************************************ 
import sys 
sys.path.append('c:/') 
  
from configobj import ConfigObj 
  
************************************************************ 
The error message is: 
  
 ? com.ibm.staf.service.stx.STAXPythonEvaluationException: 
   Traceback (innermost last): 
            File ?<pyExec string>?,line 22, in ? 
    SyntaxError: (?invalid sybtax?, (?c:\\configobj.py?, 112,19,? yield I, 
item?)) 
  
Thanks, 
Chi
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php_______________________________________________

staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users

Reply via email to