M.E.Farmer wrote: > As I noted before shlex requires a file like object or a open file . > py> import shlex > py> a = shlex.shlex('fgfgfg dgfgfdgfdg') > py> a.get_token() > Traceback (most recent call last): > File "<input>", line 1, in ? > File ".\shlex.py", line 74, in get_token > raw = self.read_token() > File ".\shlex.py", line 100, in read_token > nextchar = self.instream.read(1) > AttributeError: 'str' object has no attribute 'read'
Which Python version are you using? The docs say that since Py2.3 strings are accepted. regards, Reinhold -- http://mail.python.org/mailman/listinfo/python-list