Ok at utils.py at line 21 I placed:
import shlex
and at the bottom of the file (linhe 424) I placed
def split(s):
return shlex.split(s, posix = (sys.platform != "win32"))
And I still got this error. Did I did something wrong?
On Mon, Oct 18, 2010 at 2:24 PM, Glynn Clements <[email protected]>wrote:
>
> Luis Lisboa wrote:
>
> > > No, but wxGUI's "command prompt" is using shlex.split(), which mimics
> > > a typical Unix shell:
> > >
> > > >>> shlex.split(r'C:\Data\L5216065_06520070405_B70.TIF')
> > > ['C:DataL5216065_06520070405_B70.TIF']
> > >
> > > I suspect that it should have "posix = False" on Windows:
> > >
> > > >>> shlex.split(r'C:\Data\L5216065_06520070405_B70.TIF', posix =
> > > False)
> > > ['C:\\Data\\L5216065_06520070405_B70.TIF']
> >
> > About this, What can i do to fix this? Or isn't anything I can do?
>
> I suggest filing a bug report via http://trac.osgeo.org/grass/
>
> In terms of a fix ... in gui_modules/utils.py, add:
>
> import shlex
>
> def split(s):
> return shlex.split(s, posix = (sys.platform != "win32"))
>
> The tricky part is deciding which occurrences of shlex.split() should
> be replaced. It's possible that some of them need to retain the POSIX
> syntax conventions (where a backslash quotes the following character).
> I suspect that those in prompt.py should be changed, but I'm not sure
> about the others.
>
> --
> Glynn Clements <[email protected]>
>
_______________________________________________
grass-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-dev