Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #62980 > unrolled thread
| Started by | raj kumar <rajkumar84730@gmail.com> |
|---|---|
| First post | 2014-01-02 22:01 +0530 |
| Last post | 2014-01-02 19:47 -0800 |
| Articles | 2 — 2 participants |
Back to article view | Back to comp.lang.python
About some problem raj kumar <rajkumar84730@gmail.com> - 2014-01-02 22:01 +0530
Re: About some problem Larry Hudson <orgnut@yahoo.com> - 2014-01-02 19:47 -0800
| From | raj kumar <rajkumar84730@gmail.com> |
|---|---|
| Date | 2014-01-02 22:01 +0530 |
| Subject | About some problem |
| Message-ID | <mailman.4790.1388681067.18130.python-list@python.org> |
[Multipart message — attachments visible in raw view] — view raw
Hello, I am beginner to python and i am writing following code
from pytesser import *
and i am getting an error as follow
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Python33\lib\site-packages\pytesser.py", line 61
print text
^
SyntaxError: invalid syntax
How to resolve it ? Give me all steps to resolve it.
[toc] | [next] | [standalone]
| From | Larry Hudson <orgnut@yahoo.com> |
|---|---|
| Date | 2014-01-02 19:47 -0800 |
| Message-ID | <Goidnew2N9dFr1vPnZ2dnUVZ_sCdnZ2d@giganews.com> |
| In reply to | #62980 |
On 01/02/2014 08:31 AM, raj kumar wrote:
> Hello, I am beginner to python and i am writing following code
>
> from pytesser import *
>
> and i am getting an error as follow
>
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> File "C:\Python33\lib\site-packages\pytesser.py", line 61
> print text
> ^
> SyntaxError: invalid syntax
>
From your traceback:
File "C:\Python33\lib\site-packages\pytesser.py", line 61
^
You are using Python 3.3, but the line "print text" is Python 2 syntax.
Python 3 requires parentheses: print(text)
Obviously the pytesser.py file is written for Python 2 and it is an error to be installed with
your Python 3 packages.
>
> How to resolve it ? Give me all steps to resolve it.
>
It would be nicer if you would request help rather than demand it. However, it seems to be some
sort of installation error. Without knowing anything about your system we can't help with that.
You'll have to figure it out for yourself, or give us more information: where you got it, how
you installed it, anything else relevant.
(We do appreciate full tracebacks, however. Thank you for that. Many people summarize or
paraphrase error messages, which is not as helpful.)
-=- Larry -=-
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.python
csiph-web