Re: "Python" is not a good name, should rename to "Athon"

2007-12-06 Thread Hertha Steck
Boris Borcic wrote:

> Piet van Oostrum wrote:
>>> "Adrian Cherry" <[EMAIL PROTECTED]> (AC) wrote:
>> 
>>> AC> For that matter C# is no better, I thought that # was pronounced
>>> AC> hash, I still refer to C# as C-hash.
>> 
>> Are you musically illiterate?
> 
> Note that the notation for the note (!) isn't universal. French speakers
> for instance write that one do# and call it "do dièze". C# reads as
> unpronounceable linenoise to them.

In a german text it would be "Cis". And in real musical notation
the "sharpener" doesn't look like '#', only similar. 

-- 
http://mail.python.org/mailman/listinfo/python-list

Re: import pysqlite2 or import sqlite3?

2007-11-25 Thread Hertha Steck
Mike MacDonald wrote:

> On Nov 21, 3:02 pm, Hertha Steck <[EMAIL PROTECTED]> wrote:
>> Hello,
>>
>> I'm using Python 2.5.1, Pysqlite 2.3.5 and SQLite 3.4.1 on Gentoo Linux.
>> I've always imported pysqlite using
>>
>> from pysqlite2 import dbapi2
>>
>> and that works. If I try
>>

...
>> > Suppose I run the following program:
>> >  import sqlite3
>>
>> > conn = sqlite3.connect('example')
>>
>> ...
>>
>> And from the rest of the posting that import seems to work. Has that
>> module different names for different Linux distributions? Or what's the
>> matter here?
> 
> Make sure you built python with the "sqlite" USE flag.

That was it. I had used the "sqlite3" USE flag, but for python "sqlite" is
needed. And removing pysqlite didn't harm anything.

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: import pysqlite2 or import sqlite3?

2007-11-21 Thread Hertha Steck
Hertha Steck wrote:

> Hello,
> 
> I'm using Python 2.5.1, Pysqlite 2.3.5 and SQLite 3.4.1 on Gentoo Linux.
> I've always imported pysqlite using
> 
> from pysqlite2 import dbapi2
> 
> and that works. If I try
> 
> import sqlite3
> 
> I get
> 
> Traceback (most recent call last):
>   File "", line 1, in 
>   File "/usr/lib/python2.5/sqlite3/__init__.py", line 24, in 
> from dbapi2 import *
>   File "/usr/lib/python2.5/sqlite3/dbapi2.py", line 27, in 
> from _sqlite3 import *
> ImportError: No module named _sqlite3
> 
> And I thought that's normal, there is no Python module called sqlite3.
> 

After a second look at the error message: when I installed Gentoo, Python
2.4 was installed, I got the new version a little later. And I think I
installed Pysqlite 2.3.5 separately. 

Python 2.5 comes with pysqlite - should I uninstall my version?


-- 
http://mail.python.org/mailman/listinfo/python-list


import pysqlite2 or import sqlite3?

2007-11-21 Thread Hertha Steck
Hello,

I'm using Python 2.5.1, Pysqlite 2.3.5 and SQLite 3.4.1 on Gentoo Linux.
I've always imported pysqlite using

from pysqlite2 import dbapi2

and that works. If I try

import sqlite3

I get

Traceback (most recent call last):
  File "", line 1, in 
  File "/usr/lib/python2.5/sqlite3/__init__.py", line 24, in 
from dbapi2 import *
  File "/usr/lib/python2.5/sqlite3/dbapi2.py", line 27, in 
from _sqlite3 import *
ImportError: No module named _sqlite3

And I thought that's normal, there is no Python module called sqlite3. 

Then, after a discussion in the Gentoo forum, I saw this in the Python
library reference:

> To use the module, you must first create a Connection object that
represents the database. Here the data will be stored in the /tmp/example
file: 
> 
> conn = sqlite3.connect('/tmp/example')
> 

No import statement, though, so the module might have been renamed in that
statement. Possibly not a really good idea in the documentation. 

But now I see an old post to c.p.l:

> I'm using Ubuntu Feisty: 
>  * Python 2.5.1 (r251:54863, May  2 2007, 16:56:35) 
>  [GCC 4.1.2 (Ubuntu 4.1.2-0ubuntu4)] on linux2 
>  * SQLite version 3.3.13 
>  
> Suppose I run the following program: 
>  import sqlite3 
>  
> conn = sqlite3.connect('example') 
...

And from the rest of the posting that import seems to work. Has that module
different names for different Linux distributions? Or what's the matter
here?

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: TK-grid problem, please help

2007-04-23 Thread Hertha Steck
Hello,

Ray schrieb:
> Hi, Thanks for the help.
> 
> 
> I was trying to find a book "Python TK" something on last Friday.
> but didn't find it :-)
> 

There is only one printed book, all the details here:

http://wiki.python.org/moin/GuiBooks

HTH
Hertha
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: problem at installing phyton on windows

2007-03-25 Thread Hertha Steck
gslm schrieb:
> First, thaks a lot.
> But I'm sorry.I haven't understood what i must do for ruunnig phyton
> command.I delete path from proportiesof my computer.Then i open
> command line of phyton.But when i write phyton these view below:
> Traceback:
> File ""; line 1 in 
> NameError: name phyton is not defined

Such an answer comes from Python, I think you must already be in the 
interactive interpreter. Do you see something similar to this, with your 
cursor after the ">>>"?

Python 2.5 (r25:51908, Oct  6 2006, 15:22:41)
[GCC 4.1.2 20060928 (prerelease) (Ubuntu 4.1.1-13ubuntu4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
 >>>

At this point you can enter valid Python statements, but you can't call 
Python from Python (wouldn't make sense anyway).

I'd look at this page first:

http://www.python.org/about/gettingstarted/

HTH
Hertha
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: interacting with shell - another newbie question

2007-02-12 Thread Hertha Steck
James Stroud schrieb:
> 
> Yes, and finding ways to have employees pointlessly waste time is equal 
> to simply removing them.

Not as long as they are paid for the wasted time.
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Python Windows Editors

2007-01-24 Thread Hertha Steck
Am Mon, 22 Jan 2007 00:33:12 + schrieb W. Watson:

> [EMAIL PROTECTED] wrote:
>> W. Watson wrote:
>>> I downloaded python-2.5.msi and installed it. I believe its editor is IDE. I
>>> understand there's a Win editor called pythonwin. I believe it's in the
>>> download pywin32-210.win32-py2.5.exe, but I'm not sure if this exe file has
>>> just the editor or all of Python. Comments? If not how do I get the
>>> PythonWin editor by itself?

By "IDE" you mean IDLE, don't you?

>> 
>> Print your files from Notepad, after all, they're just text files.
>> But IDLE has more usefull Formatting options.
> Thanks. Already did it, but used Word. I can get line numbers in that way.

And you are absolutely certain you won't never, ever, detect a typo when
you have your script open in Word, correct it, save the file and try to
use the resulting mess as a Python script? Or does Word leave it as a text
file in such a case? I never dare to open source code in Word, so I'm not
really sure.

Hertha

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Roundtrip SQL data especially datetime

2006-12-17 Thread Hertha Steck
Am Sat, 16 Dec 2006 16:31:18 -0500 schrieb Carsten Haese:

> 
> This may come as a shock to you, but MySQL is not the only database
> engine on the planet. Your recommendation may apply to MySQL, but it is
> not true for all databases in general. I can name at least two examples
> (Informix and Oracle) of database engines that are supported under
> Python 2.5, and if I were less lazy I could probably find more.
> 

Interbase / Firebird:

http://sourceforge.net/project/showfiles.php?group_id=9913

All you need, Windows binaries, .src.tar.gz for Python 2.3 - 2.5, Firebird
1.0 - 2.0.


-- 
http://mail.python.org/mailman/listinfo/python-list


Re: How do I stop Python IDLE (GUI) from immediately exiting when I enter it?

2006-11-19 Thread Hertha Steck
Am Sat, 18 Nov 2006 23:24:08 -0800 schrieb John (Z R) L:

> Hi all, I am very new to programming, and I chose to study the Python
> language before C++. I am currently using the Wikibooks
> "Non-Programmer's Tutorial for Python", and am up to the section "Who
> goes there"?
> 
> http://en.wikibooks.org/wiki/Non-Programmer%27s_Tutorial_for_Python/Who_Goes_There%3F
> 
> But after clicking "run module" for
> "
> a = 1
> print a
> a = a + 1
> print a
> a = a * 2
> print a "
> 
> The results "1, 2, 4" didn't appear on the GUI screen, in fact nothing
> did. And I clicked twice again, this time, it exited the Python GUI
> program. I tried to enter back in, but it would quickly display
> 
> "1
> 2
> 4"
> 
> before exiting immediately within half a second. How do I stop the this
> exiting from occurring.
> 

All of this using IDLE as your GUI (not PythonWin and not the python
interpreter by itself), right?

You did all this as explained at the start of the tutorial: open a "New
window", type the code into this empty window, save it to a reasonable
place and then click "Run / Run module". Right? (Silly question: there is
no run menu in the interactive window. On the other hand, you never know.)

What about the examples before this one, did you type, save and run them
just like this one? And did they work as you expected?

What version of Python and of IDLE do you use?

If you have PythonWin (it's part of ActiveState Python, for example): what
happens, if you run your script using that? What happens if you open a
command window, go to the right directory and run your script from there?
(Don't try to start it by double clicking in the explorer: it will run,
but the window will close immediately afterwards, and you won't see
anything.)

> Another problem I have is firewall. On my old computer (Windows 98)
> when using Python GUI, it can't run modules because of some firewall.
> But I thought firewalls were for internet sites only?! How do I fix
> this??
> 

Do you mean this?


Personal firewall software may warn about the connection IDLE
makes to its subprocess using this computer's internal loopback
interface.  This connection is not visible on any external
interface and no data is sent to or received from the Internet.


This shouldn't keep any script from running. What exactly happens if you
try? 
-- 
http://mail.python.org/mailman/listinfo/python-list


PythonWin: error message and endless printing

2006-10-09 Thread Hertha Steck
Using Python 2.5 with pywin32 build 210 on Windows XP Home, first try with
PythonWin after installation of this version. Here are the header lines
from the interactive window:

PythonWin 2.5 (r25:51908, Sep 19 2006, 09:52:17) [MSC v.1310 32 bit (Intel)]
on win32.
Portions Copyright 1994-2006 Mark Hammond - see 'Help/About PythonWin' for
further copyright information.

If I try to print my script using the print button in the toolbar I get the
following warning:

>>> C
\Programme\Python25\Lib\site-packages\pythonwin\pywin\scintilla\view.py:641:
DeprecationWarning: 'L' format requires 0 <= number <= 4294967295
  fr = struct.pack('LLll', hdcRender, hdcFormat, rc[0], rc[1],
rc[2], rc[3], rc[0], rc[1], rc[2], rc[3], pageStart, lengthDoc)
>>>

And then the printer prints one page after another just with the header and
nothing else. The printer window shows 60 pages for the job - the script
hasn't even 60 lines. I didn't wait to see if it would stop after 60
pages ...

Printing from the print preview or from the print dialog called by the
"Print..." menu entry works faultlessly. Which is quite a good workaround,
but no long time solution.

Google didn't produce anything similar, so might it be something local? But
what? Not the printer itself, same problem with two different ones.

-- 
http://mail.python.org/mailman/listinfo/python-list