Hello,
At the moment, I place all the code of my project in a src/ directory,
and all the tests in a sibling tests/ directory, so for instance a
sample project can look like this:
doc/
...
src/
play.py
write.py
tests/
test_play.py
test_write.py
While this works fine, I have a couple of
On Aug 13, 8:46 am, Sion Arrowsmith <[EMAIL PROTECTED]>
wrote:
> Dave <[EMAIL PROTECTED]> wrote:
> >hitNum = 0
> >stopCnt = 6 + hitNum
> >offSet = 5
>
> >for i in range(0,10,1):
>
> The step argument to range defaults to 1: it's tidier to omit it.
> Similarly, the start argument defaults to 0, so
Gabriel Genellina wrote:
En Tue, 12 Aug 2008 13:04:05 -0300, Victor Subervi
<[EMAIL PROTECTED]> escribi�:
A couple of weeks ago I asked how to cut and paste multiple lines in the
Windows IDLE interface. I can only paste one line at a time!
Frustrating.
You can paste a multi-line statement
On Aug 14, 7:17 pm, Michael Tobis <[EMAIL PROTECTED]> wrote:
> On Aug 14, 6:01 pm, "Calvin Spealman" <[EMAIL PROTECTED]> wrote:
>
>
>
> > attribute access (foo.bar) binds more tightly than subscripting (foo[bar]).
>
> That certainly looks right, and in retrospect I wonder that I even
> doubted it.
Michael Tobis wrote:
On Aug 14, 6:01 pm, "Calvin Spealman" <[EMAIL PROTECTED]> wrote:
attribute access (foo.bar) binds more tightly than subscripting (foo[bar]).
That certainly looks right, and in retrospect I wonder that I even
doubted it. But even the official docs seem to me to specify
o
En Thu, 14 Aug 2008 18:29:41 -0300, belred <[EMAIL PROTECTED]> escribi�:
is there a way to dynamically get all the active loggers?
i currently have code like this in different areas of the program:
import logging
log = logging.getLogger('foo')
i would like to write a function that dynamicall
En Thu, 14 Aug 2008 17:10:26 -0300, <[EMAIL PROTECTED]>
escribi�:
I am looking for HTMLgen module but not to find this, the link
referenced in www.python.org it does not exist.
I have need to develop in cgi and would want to do it of the possible
traditional form but, i like any module for
On Aug 14, 4:01 pm, Paul Boddie <[EMAIL PROTECTED]> wrote:
> On 14 Aug, 22:44, '2+ <[EMAIL PROTECTED]> wrote:
>
> I'm not sure if I follow the question. I don't have much experience
> with making sound effects, preferring to compose and "pre-render" my
> music, but I imagine there are some tricks t
On Aug 14, 4:31 pm, Wojtek Walczak <[EMAIL PROTECTED]> wrote:
> On Thu, 14 Aug 2008 18:23:21 -0300, ariel ledesma wrote:
> > i see now, so i guess that's also why id() returns the same address for
> > them as well...
>
> It just have to work like this.
>
> a is b
>
> is actually equal to:
>
> id(a)
> Good day Mr. Guido, excuse my poor english.
>
> I am looking for HTMLgen module but not to find this, the link
> referenced in www.python.org it does not exist.
>
> I have need to develop in cgi and would want to do it of the possible
> traditional form but, i like any module for my help.
Since
En Tue, 12 Aug 2008 13:04:05 -0300, Victor Subervi
<[EMAIL PROTECTED]> escribi�:
A couple of weeks ago I asked how to cut and paste multiple lines in the
Windows IDLE interface. I can only paste one line at a time!
Frustrating. I
want it to work like my Linux interpreter. Why doesn´t it? Pl
On Thu 14 Aug 2008 11:19:06 AM EDT, Larry Bates wrote:
> eliben wrote:
>> Hello,
>>
>> I want to be able to do something like this:
>>
>> Employee = Struct(name, salary)
>>
>> And then:
>>
>> john = Employee('john doe', 34000)
>> print john.salary
I find something like this useful, especially
On Aug 15, 11:45 am, [EMAIL PROTECTED] wrote:
> by the way, iterating over bar will throw KeyError if that key does not exist
> in foo. to see that in action, simply set another key in bar after
> copy.deepcopy stmt in this example..
> bar['xtra'] = 0
> and re-run
My first posting in this th
by the way, iterating over bar will throw KeyError if that key does not exist
in foo. to see that in action, simply set another key in bar after
copy.deepcopy stmt in this example..
bar['xtra'] = 0
and re-run
fun learning with python...
Edwin
-Original Message-
From: Madari, Edwin
On Aug 15, 11:23 am, [EMAIL PROTECTED] wrote:
> if the values for any of the keys are None, both do not work as can be seen
> below!!.
>
If any of the values are None, nothing can work. The OP justifiably
(given his problem domain (bigram frequencies)) expects that all
values will be integers. If
if the values for any of the keys are None, both do not work as can be seen
below!!.
since both loops are iterating over keys(), 'get' method which would return a
'0' for non existing key does not encounter any non-existing keys.
impo
for someMethod(Field1 ArrayOf_xsd_string, other_parameters)
a call someMethod( ['str1', 'str2', 'str3'], other_parameters) *works for me*
with SOAPpy 0.12.0. yes sir it does.
in PERL, let alone array types, even for simple types it was hard for me with
all the '->', and '$' prefixing for obje
> (1) iterating over foo:
> for key in foo:
>foo[key] += bar.get(key, 0)
>
> (2) iterating over bar:
> for key in bar:
>foo[key] += bar[key]
>
> I (again) challenge you to say *why* you feel that the "iterating over
> bar" solution will not work.
Well if you're going to be clever enough
On Aug 15, 4:55 am, [EMAIL PROTECTED] wrote:
> #your thought is right.
> ===
> def sizes2fields(sizes):
>d = []
>begin = 0
>for i in sizes:
> if begin:
> end = begin + i
> else: end = i
> d.append((begin, end
John W Kennedy wrote:
Robert Maas, http://tinyurl.com/uh3t wrote:
John W Kennedy <[EMAIL PROTECTED]> wrote:
JWK> Into the 60s, indeed, there were still machines being made
JWK> that had no instruction comparable to the mainframe BASx/BALx
JWK> family, or to Intel's CALL. You had to do a subprogr
Hi,
I hope someone can help here. I have made lots of progress
implementing a gui application which at present uses the TableList
python wrapper to interface with Tcl TableList implemention.
http://tkinter.unpythonic.net/wiki/TableListTileWrapper,
http://tkinter.unpythonic.net/wiki/TableListWrapp
On Aug 14, 6:01 pm, "Calvin Spealman" <[EMAIL PROTECTED]> wrote:
>
> attribute access (foo.bar) binds more tightly than subscripting (foo[bar]).
That certainly looks right, and in retrospect I wonder that I even
doubted it. But even the official docs seem to me to specify
otherwise:
http://docs.
http://qualification.googlebong.com
Title: Norm Mabus GoogleBong
--
http://mail.python.org/mailman/listinfo/python-list
On Thu, Aug 14, 2008 at 6:46 PM, Michael Tobis <[EMAIL PROTECTED]> wrote:
> I wrote some code to test the precedence of getitem vs getattr; it
> shows that getitem binds tighter.
>
> I have been handed some code that relies on the observed behavior.
> However, the Nutshell precedence list claims th
I wrote some code to test the precedence of getitem vs getattr; it
shows that getitem binds tighter.
I have been handed some code that relies on the observed behavior.
However, the Nutshell precedence list claims the opposite. Is the
Nutshell wrong or am I missing something or is this a bug?
clas
Hi guys...
Got a question that I figured I'd ask before I reinvent the wheel.
A basic website has a form, or multiple forms. within the form, there might
be multiple elements (lists/select statements, etc...). each item would have
a varname, which would in turn be used as part of the form action
On Thu, 14 Aug 2008 10:54:25 -0700, korean_dave wrote:
> Well, here is the whole problem.
>
> It works perfectly.
I can see why that might be a problem. To solve it, open the source code
in a text editor and make random changes to the code.
--
Steven
--
http://mail.python.org/mailman/listin
Robert Maas, http://tinyurl.com/uh3t wrote:
John W Kennedy <[EMAIL PROTECTED]> wrote:
JWK> Into the 60s, indeed, there were still machines being made
JWK> that had no instruction comparable to the mainframe BASx/BALx
JWK> family, or to Intel's CALL. You had to do a subprogram call by
JWK> first o
On Thu, Aug 14, 2008 at 12:05 PM, Guilherme Polo <[EMAIL PROTECTED]> wrote:
> On Wed, Aug 13, 2008 at 2:10 PM, Mudcat <[EMAIL PROTECTED]> wrote:
>> So I haven't programmed much in Python the past couple of years and
>> have been catching up the last few days by reading the boards. I'll be
>> making
On Thu, 14 Aug 2008 18:23:21 -0300, ariel ledesma wrote:
> i see now, so i guess that's also why id() returns the same address for
> them as well...
It just have to work like this.
a is b
is actually equal to:
id(a) == id(b)
so there is no other way for id() in such case.
Hope this helps.
is there a way to dynamically get all the active loggers?
i currently have code like this in different areas of the program:
import logging
log = logging.getLogger('foo')
i would like to write a function that dynamically get a list of all
the logger names such as 'foo'. or get a list of the lo
When you ask the interpreter to create an immutable object with a
particular value, it may at its discretion, to conserve space and
possibly conserve time, return an existing object with that same value.
This is documented somewhere in the reference.
The result of comparing two 'different' o
Christian Heimes wrote:
You are getting the result because Python optimized small integers.
See http://svn.python.org/projects/python/trunk/Objects/intobject.c
Integers between -5 and +256 are singletons as are some other objects
like strings with one element or empty tuples. You must not rel
afraid not.. simple to create your own, NOTE that key words can be supplied
more than once. Hence...
import urllib
def urldecode(query):
d = {}
a = query.split('&')
for s in a:
if s.find('='):
k,v = map(urllib.unquote, s.split
On 14 Aug, 22:43, [EMAIL PROTECTED] wrote:
>
> Traceback (most recent call last):
> File "", line 1, in
> File "/sea/local/lib/python2.5/site-packages/libxml2.py", line 1, in
>
> import libxml2mod
> ImportError: ld.so.1: python: fatal: relocation error: file /usr/local/
> lib/python2.5/si
On 14 Aug, 22:44, '2+ <[EMAIL PROTECTED]> wrote:
> hey thanx
> maybe these days .. game-programmers are doing algo-comp
> without talking loud about it?
>
> is python running as backbones of some games?
Here's a link to a fairly reasonable summary of Python and games:
http://wiki.python.org/moin/
Hi,
I have this weird situation where on the same machine(solaris 8,
python 2.5), one user can do this with no problem:
>>> import libxml2
>>> libxml2
>>>
While the another one get this:
>>> import libxml2
Traceback (most recent call last):
File "", line 1, in
File "/sea/local/lib/python2
hey thanx
maybe these days .. game-programmers are doing algo-comp
without talking loud about it?
is python running as backbones of some games?
well ... maybe i'd simply want to start from writing a funny cute one
that can play strange sounds with pc-kbd ...
is it simple if is not about sound-fil
ariel ledesma wrote:
i read that 'is' compares if they are really the same object, but i
don't that's it because then why does -5 return True?
of course i could only use == to compare, but still, what am i missing
here?
Rule of thumb: Never use 'is' with any kind of string or numeric object.
On Aug 14, 1:18 pm, ariel ledesma <[EMAIL PROTECTED]> wrote:
> hello guys
>
> i just ran into this when comparing negative numbers, they start
> returning False from -6 down, but only when comparing with 'is'
>
> >>> m = -5
> >>> a = -5
> >>> m is a
> True
> >>> m = -6
> >>> a = -6
> >>> m is
kpd wrote:
Same thing here, would greatly appreciate a copy myself.
--
http://mail.python.org/mailman/listinfo/python-list
here you can find a copy:
http://code.google.com/p/pylab-works/downloads/list
cheers,
Stef
--
http://mail.python.org/mailman/listinfo/python-list
hello guys
i just ran into this when comparing negative numbers, they start
returning False from -6 down, but only when comparing with 'is'
>>> m = -5
>>> a = -5
>>> m is a
True
>>> m = -6
>>> a = -6
>>> m is a
False
>>> m == a
True
i read that 'is' compares if they are really the same object
Same thing here, would greatly appreciate a copy myself.
--
http://mail.python.org/mailman/listinfo/python-list
Good day Mr. Guido, excuse my poor english.
I am looking for HTMLgen module but not to find this, the link
referenced in www.python.org it does not exist.
I have need to develop in cgi and would want to do it of the possible
traditional form but, i like any module for my help.
Thank a lot,
Erne
On Aug 12, 7:46 pm, "Calvin Spealman" <[EMAIL PROTECTED]> wrote:
> The best answer is: Don't do that!
>
> That isn't how you test things. Write test scripts, probably using the
> unittest framework. You'll save yourself time and trouble having
> easily reproducible tests. Many people suggested relo
Eric Wertman wrote:
This means I could use this type of syntax?
sql = 'SELECT (date,time,name,size,count,stuff,flavor) FROM crazyTable
where monster=:1 and feet=:2 and price=:3'
cursor.execute(sql,('cookie','3',77.44))
?
That depends on which database and DB-API module you're using. Numeric
1. check out the Caveats for thread module:
http://docs.python.org/lib/module-thread.html
Threads interact strangely with interrupts: the KeyboardInterrupt exception
will be received by an arbitrary thread. (When the signal module is available,
interrupts always go to the main thread.)
i.e.,
#your thought is right.
===
def sizes2fields(sizes):
d = []
begin = 0
for i in sizes:
if begin:
end = begin + i
else: end = i
d.append((begin, end))
begin += i
return tuple(d)
def slicestring(s, field
On Aug 14, 3:30 am, "Mathieu Prevot" <[EMAIL PROTECTED]> wrote:
> 2008/8/13 Parimala <[EMAIL PROTECTED]>:
>
>
>
> > Hello,
>
> > I am using python2.5.1 version to run my test scripts. I want to use
> > 'threading' module in my tests. As a startup program, I had run the
> > following one.
>
>
Just to make sure I understand what you are showing me here:
> columns = ('tID', 'tNote')
> table_name = 'tmp'
> sql = 'select %s from %s where tID=:1' % ( ', '.join(columns), table_name)
> cursor.execute(sql, (1,))
>
> # sql is now 'select tID, tNote from tmp where tID=:1'
> # note the comma in a
db module properly formats arguments, if input arguments are separated from
table_name and colum_names.
columns = ('tID', 'tNote')
table_name = 'tmp'
sql = 'select %s from %s where tID=:1' % ( ', '.join(columns), table_name)
cursor.execute(sql, (1,))
# sql is now 'select tID, tNote from tmp
Larry Bates wrote:
While you are correct, that is not what the OP asked. There is no
reference to processing data prior to insertion into MySQL database.
Also the OP said they had a 1 day deadline.
Larry, having a bad day?
I'm confident that the OP is able to sort out *himself* what he need
Diez B. Roggisch wrote:
But that's a great deal more complicated! It requires merging, and while
this of course is possible, you should have mentioned it because
otherwise the OP might run into problems.
A lock doesn't do the job at all. ZODB supports clustering through ZEO.
Multiple ZEO clie
I also like to use escaped identifiers in cases like this:
sql = "select tID,tNote from %s where %s = %%s" % ("tmp","tID")
cursor.execute(sql,1)
should work fine.
--
http://mail.python.org/mailman/listinfo/python-list
Sorry, didn't get to finish my script. Have to figure out the deal
with gmail and the tab key someday.
myfile = '/somewhere/somefile.txt'
sizes = [16,4,8,8,8]
fd = open(myfile,r)
data = []
for line in fd.readlines() :
a = []
idx1 = 0
for l in sizes :
idx2 = idx1 + l
>> Well the othe day I was making a program to make a list
>> of all the songs in certian directorys but I got a problem,
>> only one of the directorys was added to the list.
>> Heres my code:
>>
>> import random
>> import os
>> import glob
>>
>> songs = glob.glob('C:\Documents and Settings\Adm
I have a machine (PLC) that is dumping its test results into a fixed-
length text file.
While it has nothing to do with python, I found that creating a MySQL
table with the proper fixed length char() fields and using 'load data
infile' was the easiest way to deal with that sort of scenario. T
On 12 Aug, 05:05, '2+ <[EMAIL PROTECTED]> wrote:
>
> oh .. am just curious who are the guys over here composing weird music with
> python
>
> as my self-introduction...
> this is the podcast am focusing on cs.py:
> http://www002.upp.so-net.ne.jp/buyobuyo/micro/rss.xml
> files of scripts i used to
Well, here is the whole problem.
It works perfectly. We are using a 3rd party automation program.
Basically instead of print() i used a test.log() command that feeds
into the 3rd party program and gives me output. I can sort output by
date, time, category, etc. As you've seen, the program runs fas
Dudeja, Rajat wrote:
So, now I've finally started using Eclipse and PyDev as an IDE for my
GUI Application. I just wrote some sample programs as an hands on.
Now I would like to take up Tkinter. I'm using Active State Python
version 2.5 and found that there is not Tkinter and Tk module in it.
T
[EMAIL PROTECTED] wrote:
Hi,
it's me again with tons of questions. I hava an input file structured
like this:
X XYData-1
1. 3.08333
2. 9.05526
3. 3.13581
Jean-Paul Calderone schrieb:
On Thu, 14 Aug 2008 16:15:11 +0200, "Diez B. Roggisch"
<[EMAIL PROTECTED]> wrote:
Jean-Paul Calderone wrote:
On Thu, 14 Aug 2008 05:22:35 -0700 (PDT), Phillip B Oldham
<[EMAIL PROTECTED]> wrote:
[snip]
How would one assign a unique ID to the root at that point?
Grant Edwards wrote:
If he's running Unix, he needs to replace the stdout file
descriptor (fd 1), with something that's connected to the
"write" end of a pipe. Then he needs to read the other
("read") end of the pipe in his application.
You do that using the dup2() system call:
It's dangerous
On Thu, Aug 14, 2008 at 1:20 PM, Russell E. Owen <[EMAIL PROTECTED]> wrote:
> In article <[EMAIL PROTECTED]>,
> "Dudeja, Rajat" <[EMAIL PROTECTED]> wrote:
>
>> Hi,
>>
>> So, now I've finally started using Eclipse and PyDev as an IDE for my
>> GUI Application. I just wrote some sample programs as a
On Aug 13, 5:52 pm, Clay Hobbs <[EMAIL PROTECTED]> wrote:
> I want to make an RPM (Redhat Package Manager) file to install a Python
> program (not a module). How is this done? Does it use Distutils, or
> something completely different? Thanks in advance.
>
> -- Ratfink
You first want to make su
On 2008-08-14, Larry Bates <[EMAIL PROTECTED]> wrote:
> Mathias Lorente wrote:
>> Hello all.
>>
>> I have a simple application (C++) that relies on shared libraries. It
>> works fine in console mode.
>> Lot of job is done into the shared library, so there is some calls to
>> 'std::cout' to infor
Michael Ströder wrote:
Larry Bates wrote:
[EMAIL PROTECTED] wrote:
I have a machine (PLC) that is dumping its test results into a fixed-
length text file. I need to pull this data into a database (MySQL
most likely) so that I can access it with Crystal Reports to create
daily reports for my en
Mathias Lorente wrote:
Hello all.
I have a simple application (C++) that relies on shared libraries. It
works fine in console mode.
Lot of job is done into the shared library, so there is some calls to
'std::cout' to inform the user in it.
Now, I would like to wrap everything into a GUI, rem
[EMAIL PROTECTED] wrote:
is there a function that does the opposite of urllib.urlencode?
for example
urldecode('Cat=1&by=down&start=1827')
returns a dictionary with {'Cat':1, 'by':'down','start':1827)
the cgi modules contains assorted stuff for parsing serialized HTTP
forms and query string
Il Wed, 13 Aug 2008 16:03:33 -0500, Larry Bates ha scritto:
> Actually those examples in Python for Win32 book are quite good and basically
> all services are built using the same framework shown there. If you run into
> a
> problem post something here or better yet on comp.python.windows grou
hi
is there a function that does the opposite of urllib.urlencode?
for example
urldecode('Cat=1&by=down&start=1827')
returns a dictionary with {'Cat':1, 'by':'down','start':1827)
thanks
--
http://mail.python.org/mailman/listinfo/python-list
Hello all.
I have a simple application (C++) that relies on shared libraries. It
works fine in console mode.
Lot of job is done into the shared library, so there is some calls to
'std::cout' to inform the user in it.
Now, I would like to wrap everything into a GUI, remove the application
and
In article <[EMAIL PROTECTED]>,
"Dudeja, Rajat" <[EMAIL PROTECTED]> wrote:
> Hi,
>
> So, now I've finally started using Eclipse and PyDev as an IDE for my
> GUI Application. I just wrote some sample programs as an hands on.
>
> Now I would like to take up Tkinter. I'm using Active State Python
Dudeja, Rajat wrote:
Hi,
So, now I've finally started using Eclipse and PyDev as an IDE for my
GUI Application. I just wrote some sample programs as an hands on.
Now I would like to take up Tkinter. I'm using Active State Python
version 2.5 and found that there is not Tkinter and Tk module in i
Hi,
In the article below you mention that you were succesful at doing this through
perl. Would it be possible to send me the perl code?
http://mail.python.org/pipermail/python-list/2007-January/423311.html
Thank You
Regards
Sid
--
http://mail.python.org/mailman/listinfo/python-l
On Wed, 13 Aug 2008, Christian Heimes wrote:
Tom Anderson wrote:
Secondly, do you really have to do this just to parse a date with a
timezone? If so, that's ridiculous.
No, you don't. :) Download the pytz package from the Python package
index. It's *the* tool for timezone handling in Python
korean_dave a écrit :
Still the same output...
"same" as what, with what ??? Do yourself (and the world) a favour :
learn to quote the posts you're answering to.
Here's the actual code...
for x in range(0,2):
for y in range(0,27):
for z in range(0,15):
On Thu, 14 Aug 2008 08:35:15 -0700 (PDT), korean_dave wrote:
> Still the same output...
>
> Here's the actual code...
>
> for x in range(0,2):
> for y in range(0,27):
> for z in range(0,15):
> print(str(x) + " " + str(y) + " " + str(z))
This code won't produ
hahah true.
Sorry folks. I am running a third party scripting machine that uses
python. It's the third-party program that is at fault. More detail
involved that you don't need to know, but it's not python's "fault".
Sorry for the inconvenience.
On Aug 14, 11:47 am, Fredrik Lundh <[EMAIL PROTECTE
Evan a écrit :
a simple problem but I do not know why...:(, could anyone help me?
MySQLdb nominally uses just the %s placeholder style, in my script, i
got error if you want to use placeholder(%s) for table name:
db-api placeholders won't work for table names - or for anything that
isn't supp
Hi all,
I do appreciate if any one can help me for my following problem:
I need to grab/parse numeric numbers such as app number from incoming
emails stored in Microsoft Outlook (Microsoft Exchange server) with
specified subject line.
Any help with the python script is highly appreciat
korean_dave wrote:
Still the same output...
>
Here's the actual code...
for x in range(0,2):
for y in range(0,27):
for z in range(0,15):
print(str(x) + " " + str(y) + " " + str(z))
umm. that's even less related to your original output than your earli
replace the name of table before calling *.execute.
s.dbptr.execute(str % (e[0]))
good luck.
Edwin
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
On Behalf Of Evan
Sent: Thursday, August 14, 2008 11:27 AM
To: python-list@python.org
Subject: a question about mysqldb
Evan wrote:
a simple problem but I do not know why...:(, could anyone help me?
MySQLdb nominally uses just the %s placeholder style, in my script, i
got error if you want to use placeholder(%s) for table name:
Placeholders are supposed to be used for *values*, not other parts of
the SQL stat
Hi,
So, now I've finally started using Eclipse and PyDev as an IDE for my
GUI Application. I just wrote some sample programs as an hands on.
Now I would like to take up Tkinter. I'm using Active State Python
version 2.5 and found that there is not Tkinter and Tk module in it.
To use Tkinter do I
Still the same output...
Here's the actual code...
for x in range(0,2):
for y in range(0,27):
for z in range(0,15):
print(str(x) + " " + str(y) + " " + str(z))
--
http://mail.python.org/mailman/listinfo/python-list
>>Fredrik Lundh wrote:
>> That's all there is; there's no header files or declaration files or
>> explicitly maintained object files etc; the program itself is just a
>> bunch of Python files.
>I would simply add that if your python script produces one or more
output files (for example a text
a simple problem but I do not know why...:(, could anyone help me?
MySQLdb nominally uses just the %s placeholder style, in my script, i
got error if you want to use placeholder(%s) for table name:
+
>>> str="select tID,tNote from %s wher
thanks, guys.
On Thu, Aug 14, 2008 at 7:35 AM, M.-A. Lemburg <[EMAIL PROTECTED]> wrote:
> On 2008-08-13 23:54, John Krukoff wrote:
>
>> On Wed, 2008-08-13 at 09:39 -0700, gjhames wrote:
>>
>>> I wish to replace several characters in my string to only one.
>>> Example, "-", "." and "/" to nothing
eliben wrote:
Hello,
I want to be able to do something like this:
Employee = Struct(name, salary)
And then:
john = Employee('john doe', 34000)
print john.salary
Basically, Employee = Struct(name, salary) should be equivalent to:
class Employee(object):
def __init__(self, name, salary):
[EMAIL PROTECTED] wrote:
hi
i want to play alarm sound when i press a particular key in
keyboard.so someone help me in doing it.
Thanks and Regards
Sasil.G
When you post to this list you need to give us more to go on than you have.
1) What have you tried that doesn't work?
2) What type of s
On Thu, 14 Aug 2008 16:41:57 +0200, Thomas Guettler <[EMAIL PROTECTED]> wrote:
auto increment:
Here's one way
class Sequence(Persistence):
def __init__(self):
self.current = 0
def next(self):
self.current += 1
return self.current
ticketSequ
korean_dave a écrit :
for y in range(0,iNumItems):
print(str(y))
How do i make the output go IN ORDER
0
1
2
3
4
5
6
etc.
instead of
0
1
10
11
12
13
14
2
3
4
5
6
7
8
9
Your code doesn't expose this problem:
[EMAIL PROTECTED]:~$ python
Python 2.5.1 (r251:54863, Mar 7 2008, 03:41:45)
[GCC 4.1
korean_dave wrote:
for y in range(0,iNumItems):
print(str(y))
How do i make the output go IN ORDER
0
1
2
3
4
5
6
etc.
instead of
0
1
10
11
12
13
14
2
3
4
5
6
7
8
9
That's not what it does on my system (Python 2.5.2 on Windows). Please post the
code that you are "actually" running.
>>> fo
here is a working code snippet to read from MySQL db.
python tutorial has examples of reading from files.
put them together to do your task.
===
import MySQLdb
con = MySQLdb.connect(host='127.0.0.1',
port=4321, user='joe', passwd='shmoe', db='t
On Wed, Aug 13, 2008 at 2:10 PM, Mudcat <[EMAIL PROTECTED]> wrote:
> So I haven't programmed much in Python the past couple of years and
> have been catching up the last few days by reading the boards. I'll be
> making commercial Python applications again and wanted to see what's
> new in the Gui d
Thank you very much. I did not know there was a python-excel group,
which I will certainly take note of in the future. The previous post
answered my question, but I wanted to clarify the difference between
xf.background.background_colour_index,
xf.background.pattern_colour_index, and book.colour_
for y in range(0,iNumItems):
print(str(y))
How do i make the output go IN ORDER
0
1
2
3
4
5
6
etc.
instead of
0
1
10
11
12
13
14
2
3
4
5
6
7
8
9
--
http://mail.python.org/mailman/listinfo/python-list
auto increment:
Here's one way
class Sequence(Persistence):
def __init__(self):
self.current = 0
def next(self):
self.current += 1
return self.current
ticketSequence = Sequence()
class Ticket(Persistence):
def __init__(self):
On Thu, 14 Aug 2008 16:15:11 +0200, "Diez B. Roggisch" <[EMAIL PROTECTED]>
wrote:
Jean-Paul Calderone wrote:
On Thu, 14 Aug 2008 05:22:35 -0700 (PDT), Phillip B Oldham
<[EMAIL PROTECTED]> wrote:
[snip]
How would one assign a unique ID to the root at that point?
Here's one way
class Se
1 - 100 of 152 matches
Mail list logo