[Tutor] Challenges with psycopg2 on Python 3.2
Alan Gauld
alan.gauld at yahoo.co.uk
Fri Jan 6 12:48:15 EST 2017
On 06/01/17 12:55, Admire Mutsikiwa wrote:
> it screams on the Python3.2 prompt, it gives
Hardly screaming, rather a polite complaint that you've
messed up your indentation.
>>>> import psycopg2
> File "<stdin>", line 1
> import psycopg2
> ^
> IndentationError: unexpected indent
I'll guess that you have a space or two in front of import.
Python is very fussy about spacing at the front of lines,
aka indentation.
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos
More information about the Tutor
mailing list