MRAB wrote:
Python Newsgroup wrote:
Gotcha, I got started from the telnet example listed in the docs. The
linux install was via yum and installed 2.x instead. That explains it.
Althought print (tn.read_all () ) runs in 2.x on linux.
I have another problem maybe you cna help me with. My telnet
Python Newsgroup wrote:
Gotcha, I got started from the telnet example listed in the docs. The
linux install was via yum and installed 2.x instead. That explains it.
Althought print (tn.read_all () ) runs in 2.x on linux.
I have another problem maybe you cna help me with. My telnet output
jibb
Gotcha, I got started from the telnet example listed in the docs. The linux
install was via yum and installed 2.x instead. That explains it. Althought
print (tn.read_all () ) runs in 2.x on linux.
I have another problem maybe you cna help me with. My telnet output
jibberish in windows: I cna p
Thats newbe experience for ya ;-) thanks. Its seems to work and leads to
another question. whether running the script or stepping thru the process at
the command line I get what looks like hex
C:\Python30>python \Python30\scripts\telnet-tftp1.py
b'\x1b[24;1H\x1b[24;31H\x1b[24;1H\x1b[?25h\x1b[24
Python Newsgroup wrote:
I'm a total newbe to scripting not to mention python. However I was able
to successfully create a telnet script to initiate login, initiate tftp,
exit, exit, confirm and close session. Frustrated, possibly causing my
own misery. I replace the sript the script with the st
Python Newsgroup wrote:
I'm a total newbe to scripting not to mention python. However I was
able to successfully create a telnet script to initiate login,
initiate tftp, exit, exit, confirm and close session. Frustrated,
possibly causing my own misery. I replace the sript the script with
the s
ronrsr wrote:
> the exact code that is triggering the error message is:
>
> zc = zsql.connect()
Don't give us one line; give us the whole of the imported module plus
the calling script (at least up to the place where it gets the error).
That way we can see what is really going on, and someone wit
ronrsr wrote:
> the syntax error comes in the main program, in any line that follows
> the import statement.
>
in which case, don't you think it might be the "import" statement that's
causing the problem. What is stopping you from showing us the whole
source? Or at least the import statement as
"ronrsr" <[EMAIL PROTECTED]> wrote:
> the exact code that is triggering the error message is:
>
> zc = zsql.connect()
individual statements don't "trigger" syntax errors; they're compiler
errors, and only
appear when do something that causes code to be compiled.
> exact error message: SyntaxEr
the syntax error comes in the main program, in any line that follows
the import statement.
ronrsr wrote:
> the exact code that is triggering the error message is:
>
> zc = zsql.connect()
>
>
> exact error message: SyntaxError: Invalid Syntax
>
>
> but any statement that follows the import state
the exact code that is triggering the error message is:
zc = zsql.connect()
exact error message: SyntaxError: Invalid Syntax
but any statement that follows the import statement will trigger it.
bests,
r-sr-
Roberto Bonvallet wrote:
> ronrsr wrote:
> > thanks for the speedy answer. wha
ronrsr wrote:
> thanks for the speedy answer. what i meant was:
>
> return MySQLdb.connect (host = "db91b.pair.com",
> user = "homebase",
>passwd = "Newspaper2",
>db = "homebase_zingers"
> );
thanks for the speedy answer. what i meant was:
return MySQLdb.connect (host = "db91b.pair.com",
user = "homebase",
passwd = "Newspaper2",
db = "homebase_zingers"
);
but even when I have
In <[EMAIL PROTECTED]>, ronrsr wrote:
> def connect():
>
>
>return = MySQLdb.connect (host = "db91x..com",
^
You can't assign to a keyword. Just leave this ``=`` out.
Ciao,
Marc 'BlackJack' Rintsch
--
http://mail.python.org/mailman/listinfo/python-list
here's some of the surrounding code from the main program:
querystring = querystring + " ORDER BY keywords ";
#SQL
import zsql
zc = zsql.connect()
print("return from open")
zq = zc.query(querystring).dictresult()
ronrsr wrote:
> no matter where I place this imported file,the statement
ronrsr wrote:
> return = MySQLdb.connect (host = "db91x..com",
> user = "",
>passwd = "x",
>db = "homebase_zingers"
> );
return is a reserved keyword. You cannot have a variable
On Tue, 27 Dec 2005 09:32:18 GMT
"DIBS" <[EMAIL PROTECTED]> wrote:
> >>> python sudoku.py
> File "", line 1
>python sudoku.py
> ^
>
> >>>SyntaxError: invalid syntax
>
> Thanks for your help.
> The above is the extact message.
Based on the ">>>" prompt, I'd say you
"DIBS" <[EMAIL PROTECTED]> wrote:
> >>> python sudoku.py
> File "", line 1
>python sudoku.py
> ^
>
> >>>SyntaxError: invalid syntax
> Thanks for your help.
> The above is the extact message.
that looks like the Python interpreter window, not the Windows command-
l
>>> python sudoku.py
File "", line 1
python sudoku.py
^
>>>SyntaxError: invalid syntax
Thanks for your help.
The above is the extact message.
DIBS
"Steven D'Aprano" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> On Tue, 27 Dec 2005 07:40:12 +
Steven D'Aprano wrote:
> Please post the *full* traceback of the error, not just the last
> description.
>
> For example, something like this:
>
> >>> x = x+*9
> File "", line 1
> x = x+*9
> ^
> SyntaxError: invalid syntax
>
> Just "SyntaxError" on its own is not enough to tell wha
On Tue, 27 Dec 2005 07:40:12 +, DIBS wrote:
> I'm new to Python and I don't understand what I'm doing wrong.
>
> I'm running windows xp.
>
> In the command line window, I type:
> Python Sudoku.py
>
> and I get the response"
>
> SyntaxError: invalid syntax
>
> If anyone cane help me I'd be
21 matches
Mail list logo