running programs from within python

James Stroud jstroud at mbi.ucla.edu
Wed Mar 9 14:41:35 EST 2005


You should

import os

On Wednesday 09 March 2005 10:06 am, M.N.A.Smadi wrote:
> this is the full error
>
>
> Traceback (most recent call last):
>   File "./plugin.py", line 60, in ?
>     main()
>   File "./plugin.py", line 40, in main
>     os.system("/root/tmp/bibutils_3.14/isi2xml " + isi_file + " >
> tmp_isi_xml.xml")
> NameError: global name 'os' is not defined
>
> smadi
>
> Steven Bethard wrote:
> > M.N.A.Smadi wrote:
> >> am getting an error in the script as follows:
> >>
> >> NameError: global name 'os' is not defined
> >>
> >> however i dont get the same error when running from the python CLI.
> >> (and yes i am importing the os module)
> >
> > Can you give the full exception message (i.e. copy-paste it from the
> > output)?
> >
> > STeVe

-- 
James Stroud, Ph.D.
UCLA-DOE Institute for Genomics and Proteomics
Box 951570
Los Angeles, CA 90095



More information about the Python-list mailing list