Send grass-windows mailing list submissions to grass-windows@lists.osgeo.org
To subscribe or unsubscribe via the World Wide Web, visit http://lists.osgeo.org/mailman/listinfo/grass-windows or, via email, send a message with subject or body 'help' to grass-windows-requ...@lists.osgeo.org You can reach the person managing the list at grass-windows-ow...@lists.osgeo.org When replying, please edit your Subject line so it is more specific than "Re: Contents of grass-windows digest..." Today's Topics: 1. problem from python & grass64 on Win XP (Liu, Huili) 2. Re: problem from python & grass64 on Win XP (Glynn Clements) ---------------------------------------------------------------------- Message: 1 Date: Fri, 30 Sep 2011 12:05:49 -0400 From: "Liu, Huili" <h...@ap.org> Subject: [GRASS-windows] problem from python & grass64 on Win XP To: <grass-windows@lists.osgeo.org> Message-ID: <1b66071016731c4b913d744ea766779b19ca5...@nycxmb01.ap.org> Content-Type: text/plain; charset="us-ascii" Hello, I am trying to run a simple python script as below on Win XP but I got "Line too long or missing newline at line 56". I believe the problem comes from "grass.parser()". Any idea how I can resolve it? I have Grass64 and python26 in my Win XP desktop. ============== import sys from grass.script import core as grass def main(): ret = grass.run_command("g.region", rast="elevation") ret += grass.run_command("d.rast", "elevation") ret += grass.run_command("r.info", "elevation") sys.exit(ret) if __name__ == "__main__": options, flags = grass.parser() main() +++++++ Thanks, Willie The information contained in this communication is intended for the use of the designated recipients named above. If the reader of this communication is not the intended recipient, you are hereby notified that you have received this communication in error, and that any review, dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify The Associated Press immediately by telephone at +1-212-621-1898 and delete this e-mail. Thank you. [IP_US_DISC] msk dccc60c6d2c3a6438f0cf467d9a4938 ------------------------------ Message: 2 Date: Fri, 30 Sep 2011 18:55:18 +0100 From: Glynn Clements <gl...@gclements.plus.com> Subject: Re: [GRASS-windows] problem from python & grass64 on Win XP To: "Liu, Huili" <h...@ap.org> Cc: grass-windows@lists.osgeo.org Message-ID: <20102.646.300702.917...@cerise.gclements.plus.com> Content-Type: text/plain; charset=us-ascii Liu, Huili wrote: > I am trying to run a simple python script as below on Win XP but I got > "Line too long or missing newline at line 56". I believe the problem > comes from "grass.parser()". The last line of the script must be entirely blank, i.e. the last character of the script must be a newline. -- Glynn Clements <gl...@gclements.plus.com> ------------------------------ _______________________________________________ grass-windows mailing list grass-windows@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/grass-windows End of grass-windows Digest, Vol 60, Issue 1 ********************************************