On Thu, 3 Sep 2009, alexandre villers wrote:

Dear members,

Roger Bivand advised me to post problems on the R / GRASS interface on this 
list.
I was using spgrass6 and R 2.9.2 with win GRASS 6.3.0 without much problems.
I downloaded winGRASS 6.4 and tried to run again old script and the initGRASS 
doesn't work.

loc<-initGRASS("C:/GRASS", home=tempdir(), override=T) #intialise GRASS dans un 
dossier de travail dans tempdir
Input is not proper UTF-8, indicate encoding !
Bytes: 0xE9 0x66 0x69 0x6E
Error : 1: Input is not proper UTF-8, indicate encoding !
Bytes: 0xE9 0x66 0x69 0x6E

Erreur dans parseGRASS(cmd) : g.region not parsed

Roger advised me this could come from file path problem so I also tried, instead of 
home=tempdir() home="C:/temp" and

loc<-initGRASS("C:/GRASS", home="C:/temp/", override=T) #intialise GRASS dans 
un dossier de travail dans tempdir
Input is not proper UTF-8, indicate encoding !
Bytes: 0xE9 0x66 0x69 0x6E
Error : 1: Input is not proper UTF-8, indicate encoding !
Bytes: 0xE9 0x66 0x69 0x6E

Erreur dans parseGRASS(cmd) : g.region not parsed

Stay with your previous working version of GRASS.

Next time, please include the output of traceback() run immediately after the error, and the output of sessionInfo().

My guess is that the error is occurring in the last, unimportant, line of initGRASS(), and that the location has been created successfully. What fails is attempting to read the XML produced by g.region(.exe) --interface-description, which appears to include invalid characters. I think that the error messages are coming from xmlTreeParse(), but don't know without traceback() output. This will likely affect other GRASS modules too.

As I wrote on R-sig-geo, I have tried to reproduce the problem with winGRASS 6.4.0 RC5 and R 2.9.2 without success - everything worked for me. If you can redirect the output of g.region(.exe) --interface-description to a file (with >) at the shell prompt, zip the file, and attach it to me off-list, I'll take a look.

The problem still looks locale-related. If GRASS was internationalised between RC4 and RC5 with reference to the contents of what --interface-description returns, and the contents are malformed, that would explain it. If this is the case (with apologies) make sure that your computer knows that it is not in a locale using non ACSII signs, or find the right locale for GRASS to match the one R is expecting.

Roger


Any idea ?

Alex


Alexandre Villers
PhD. Student
Team Biodiversity
CEBC CNRS
79360 Beauvoir sur Niort


__________ Information from ESET Mail Security, version of virus signature 
database 4392 (20090903) __________

The message was checked by ESET Mail Security.
http://www.eset.com




--
Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Helleveien 30, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43
e-mail: [email protected]

_______________________________________________
grass-stats mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-stats

Reply via email to