I monitor changes to the Wikipedia doctest page, and so noticed a
change in the Ruby implementation of doctest.
Scooting around their implementation I found that they have an !!!
special directive that says drop into the interpreter at this point
when testing allowing debugging in context.
Your problem is that open(...,'w') is not locked.
Use something like:
lockf = open('aaa', 'a')
fnctl.flock(lockf,fnctl.LOCK_EX)
file = open('aaa', 'w')
file.write('asdf')
file.close()
lockf.close()
[EMAIL PROTECTED] wrote:
I ran following 2 programs (lock1, lock2) at almost same time,
to write
Michael Torrie [EMAIL PROTECTED]:
[EMAIL PROTECTED] wrote:
2) The Qt vs. .NET API. I have no experience with Qt's API and a
rudimentary experience with the .NET API (seems powerfull but also big
and complex).
Qt's API is very very good. Easy to use and extremely powerful. Note
that in
I'm trying to limit a value stored by object (either int or float):
class Limited(object):
def __init__(self, value, min, max):
self.min, self.max = min, max
self.n = value
def set_n(self,value):
if value self.min: # boundary check
self.n = self.min
On Sun, Jun 22, 2008 at 11:44 AM, Josip [EMAIL PROTECTED] wrote:
I'm trying to limit a value stored by object (either int or float):
class Limited(object):
def __init__(self, value, min, max):
self.min, self.max = min, max
self.n = value
def set_n(self,value):
if
Not with normal vars, because = is a rebinding operator in Python,
rather than assignment.
You can do (close to) the above with object properties.
David.
Yes, but it's done with built-in types like int and float. I suspect I could
subclass from them and implement limits, but I would have
Hi all,
I'm looking to learn Python (as my first programming language) and I'm
pretty sure I'd be more successful doing this with a group of other
people.
I've currently got one other person to learn with me, and we plan to
work remotely over the net using tools such as IM/VoiP/Gobby/WIkis
etc.
I'm a beginner, too.But python wasn't my first programming language.
On Sun, Jun 22, 2008 at 6:43 PM, Jonathan Roberts [EMAIL PROTECTED]
wrote:
Hi all,
I'm looking to learn Python (as my first programming language) and I'm
pretty sure I'd be more successful doing this with a group of other
On Sun, Jun 22, 2008 at 12:24 PM, Josip [EMAIL PROTECTED] wrote:
Not with normal vars, because = is a rebinding operator in Python,
rather than assignment.
You can do (close to) the above with object properties.
David.
Yes, but it's done with built-in types like int and float. I suspect I
2008/6/21 Val-Amart [EMAIL PROTECTED]:
Use PyQt. You will gain great portability +all the functionality built
in qt.
You can try PyGTK also, though i wont recommend it.
Why would you not recommend it? I've been using it for a mall project, and
would like to know if there's some pit waiting
On Sun, Jun 22, 2008 at 12:43 PM, Jonathan Roberts
[EMAIL PROTECTED] wrote:
Hi all,
I'm looking to learn Python (as my first programming language) and I'm
pretty sure I'd be more successful doing this with a group of other
people.
I've currently got one other person to learn with me, and we
In theory you could hack Python's internal locals or globals
dictionary so that it did something unusual while looking up your
object. But in practice this doesn't work, because the returned
objects (when you call globals() or locals()) attributes are readonly.
Probably because those internal
If you want people to meet with you (in person) as a mentor you should
probably ask on your local Python or Linux users group mailing list.
We're not really too worried about doing it in person - mostly because
the people doing it so far are all at least 1000 miles away from each
other :)
On Sun, Jun 22, 2008 at 1:52 PM, Jonathan Roberts
[EMAIL PROTECTED] wrote:
If you want people to meet with you (in person) as a mentor you should
probably ask on your local Python or Linux users group mailing list.
We're not really too worried about doing it in person - mostly because
the
On Jun 22, 5:44 am, Josip [EMAIL PROTECTED] wrote:
I'm trying to limit a value stored by object (either int or float):
class Limited(object):
def __init__(self, value, min, max):
self.min, self.max = min, max
self.n = value
def set_n(self,value):
if value
macoovacany wrote:
http://macoovacany.wordpress.com/
When I tried to run it, I got all kinds of syntax errors because of
non-ASCII characters; namely, you have fancy left and right single
and double quotes. Once I replaced these with the ASCII equivalents,
it worked fine. I suggest you use a
Josip wrote:
I'm trying to limit a value stored by object (either int or float):
class Limited(object):
def __init__(self, value, min, max):
self.min, self.max = min, max
self.n = value
def set_n(self,value):
if value self.min: # boundary check
Hi,
I'm making a project into my first package, mainly for organization, but
also to learn how to do it. I have a number of data files, both
experimental results and PNG files. My project is organized as a root
directory, with two subdirectories, src and data, and directory trees
below
hi every one.
I have program which uses this pyHook lib, and when I try to compile
it using py2exe the pyhook don't work. it gives me no error. the
program works fine beside the function of this lib.
why does it append ?
is their any solution?
I would be glad to know if anyone ever experienced
On Jun 22, 6:45 am, Tim Roberts [EMAIL PROTECTED] wrote:
dominique [EMAIL PROTECTED] wrote:
On Jun 21, 1:37 pm, John Machin [EMAIL PROTECTED] wrote:
Look at the operator module. In your above example:
return {
'': operator.gt,
'=': operator.eq,
'': operator.lt,
Ciao a tutti,
ho un QTableWidget che ho reso non editabile settando editTriggers a
NoEditTriggers.
Il problema è che adesso non posso selezionare una cela e copiarne il
contenuto nella clipboard.
Come posso risolvere il problema?
Grazie in anticipo
antonio
--
The pyodb module doesn't implement this behavior. You would have to create
a dictionary of column positions and column names in advance.
On Sat, Jun 21, 2008 at 3:52 PM, Chris [EMAIL PROTECTED] wrote:
On Jun 21, 3:58 pm, [EMAIL PROTECTED] wrote:
Is there any way to retrieve column names from
On 22 Giu, 17:11, Antonio Valentino [EMAIL PROTECTED]
wrote:
Ciao a tutti,
ho un QTableWidget che ho reso non editabile settando editTriggers a
NoEditTriggers.
Il problema è che adesso non posso selezionare una cela e copiarne il
contenuto nella clipboard.
Come posso risolvere il problema?
On Sun, Jun 22, 2008 at 4:07 PM, Saul Spatz [EMAIL PROTECTED] wrote:
Hi,
I'm making a project into my first package, mainly for organization, but
also to learn how to do it. I have a number of data files, both
experimental results and PNG files. My project is organized as a root
directory,
Le Sunday 22 June 2008 16:07:37 Saul Spatz, vous avez écrit :
Hi,
I'm making a project into my first package, mainly for organization, but
also to learn how to do it. I have a number of data files, both
experimental results and PNG files. My project is organized as a root
directory, with
John Machin wrote:
On Jun 22, 9:05 am, [EMAIL PROTECTED] wrote:
I downloaded Mark Pilgrims's feedparser.py in a zipfile to my Windows
machine, unzipped it and tried to install it to no avail.
Eggs are part of a new experimental package distribution scheme. Don't
worry about it.
Yes.
I'm sure that many (myself included) would be happy to help out, but
due to timezone differences, working hours, etc you may only get
responses up to 24 hours (or more) later.
Awesome, heh I'm sure we'll have questions for the list in good time :)
What needs does your (non-face-to-face)
On Jun 13, 1:26 am, Chuck Rhode [EMAIL PROTECTED] wrote:
On Mon, 09 Jun 2008 10:48:03 -0700, disappearedng wrote:
I knowPythonbut notPerl, and I am interested in knowing which of
these two are a better choice.
I'm partial to *Python*, but, the last time I looked, *urllib2* didn't
provide a
On Jun 22, 3:43 am, Jonathan Roberts [EMAIL PROTECTED]
wrote:
Hi all,
I'm looking to learn Python (as my first programming language) and I'm
pretty sure I'd be more successful doing this with a group of other
people.
hi Jon, I'm in the same situation as you and think a co-op method of
I might be interested in joining your group. I'm trying to learn
python, too, but tend to get frustrated by the isolation. can you
send me, or post, some details?
- O
--
http://mail.python.org/mailman/listinfo/python-list
If string `source_code` contains Python source code, how can I execute
that code, and bind it to some name? I tried compiling with:
code_object = compile(source_code, 'errorfile', 'exec')
but then what to do with `code_object`?
P.S.
If my intentions aren't that clear, this is what I'm
Why not make it a function?
function assignLimited(value, vmin, vmax):
value = max(vmin, value)
value = min(vmax, value)
return value
a = assignLimited(7, 0, 10)
Seems like it solves your problem relatively cleanly.
Note: I also removed min/max variables because they would
Why not make it a function?
function assignLimited(value, vmin, vmax):
value = max(vmin, value)
value = min(vmax, value)
return value
a = assignLimited(7, 0, 10)
Seems like it solves your problem relatively cleanly.
Note: I also removed min/max variables because they would
On Saturday 21 June 2008 13:28, Herman wrote:
I want to install it in
vistahttp://www.daniweb.com/forums/thread130469.htm
l#, but i get this message in the process:
could not create... py2exe-py2.5
I forwarded your question but you may want to ask again
at the link below.
[EMAIL PROTECTED]
What is the expected result of -1/2 in python?
--
http://mail.python.org/mailman/listinfo/python-list
If string `source_code` contains Python source code, how can I execute
that code, and bind it to some name? I tried compiling with:
code_object = compile(source_code, 'errorfile', 'exec')
but then what to do with `code_object`?
P.S.
If my intentions aren't that clear, this is
On Sunday 22 June 2008 10:40, Gandalf wrote:
hi every one.
I have program which uses this pyHook lib, and when
I try to compile it using py2exe the pyhook don't
work. it gives me no error. the program works fine
beside the function of this lib. why does it append
?
is their any solution?
I bet you didn't even try this, unless your definition of works
includes a RuntimeError: maximum recursion depth exceeded. Here's a
a working version:
Actually, the version I'm using is somewhat bigger. I removed docstrings and
recklessly stripped away some methods to make it shorter concise
Martin v. Löwis [EMAIL PROTECTED] wrote in
news:[EMAIL PROTECTED]:
d = {}
exec source_code in d
some_name = d['some_name']
This works quite well! I can't believe after googling for half on hour I
didn't notice this exec ... in ... syntax.
One more thing though, is there a way to access
Serve Lau wrote:
What is the expected result of -1/2 in python?
0
Christian
--
http://mail.python.org/mailman/listinfo/python-list
Serve Lau wrote:
What is the expected result of -1/2 in python?
--
http://mail.python.org/mailman/listinfo/python-list
From the manual:
The result is always rounded towards minus infinity: 1/2 is 0, (-1)/2 is
-1, 1/(-2) is -1, and (-1)/(-2) is 0.
Gary Herron
--
Christian Heimes wrote:
Serve Lau wrote:
What is the expected result of -1/2 in python?
0
No. That's not right. (It would be in C/C++ and many other languages.)
See my other response for the correct answer.
Gary Herron
Christian
--
I'm running Python 2.3 and calling pyTTS. I've had it working forever.
Today, I ran out of disk space. After deleting some of my personal files,
for no apparent reason, pyTTS no longer runs.
For the statement
tts = pyTTS.Create()
I get the error message:
ValueError: SAPI not
I'm was wanting to format a positive integer in binary,
and not finding it--to my surprise--I rolled my own version.
Is this already in python, or have I missed it somewhere?
I have Googled around a bit, and found a few threads on
the subject, but they all seem to fizzle out.
(e.g. : INPUT 35,
[EMAIL PROTECTED] wrote:
On 20 juin, 21:44, eliben [EMAIL PROTECTED] wrote:
...
The generic version has to make a lot of decisions at runtime, based
on the format specification.
Extract the offset from the spec, extract the length.
... example with lists of operations...
Just my 2 cents.
On Jun 21, 11:34 pm, Terry Reedy [EMAIL PROTECTED] wrote:
joamag wrote:
Is there any possible way to unblock the sys.stdin.readline() call
from a different thread.
If you want the thread to do something 'else' when no input is
available, would this work? Put readline in a thread that puts
I don't know if you found this example:
http://www.daniweb.com/code/snippet285.html
--
I'm was wanting to format a positive integer in binary,
and not finding it--to my surprise--I rolled my own version.
Is this already in python, or have I missed it somewhere?
I have Googled around a
d = {}
exec source_code in d
some_name = d['some_name']
This works quite well! I can't believe after googling for half on hour I
didn't notice this exec ... in ... syntax.
One more thing though, is there a way to access some_name as a
attribute, instead as a dictionary:
some_name =
I would like to be a part of this if enough people are able to join
up, I nabbed python less than two days ago, and have been trying to
absorb as much as I can out of websites and practice projects.
Learning this together would speed up the process slightly because we
could share tips and such,
Please i need help with this. I just started using python and i hace
run into several issues. The on that i can't tackle is the issue of no
being able to compile the python code using PyQt4 application
It gives the error
ImportError: cannot import name QtCore.
.
I tries the trunk from the snv, but
weheh wrote:
I don't know if you found this example:
http://www.daniweb.com/code/snippet285.html
Thanks for that. The offerings are very similar to the
algorithms I wrote myself.
It wasn't the solution I was after,really; that's
easy. It was whether anything had found its way into
the
Hello everyone.
I'm having a problem when extracting data from HTML with regular
expressions.
This is the source code:
You are ready in the nextbr /span id=counter_jt_minutes
style=display: inline;span id=counter_jt_minutes_value12/
spanM/span span id=counter_jt_seconds style=display:
Thanks Chris and John. Chris, this worked perfectly with the ODBC
module that ships with Python Win32:
column_names = [d[0] for d in cursor.description]
John, I've never heard of pyodbc but I'll have to look into it.
Thanks again.
Dana
--
http://mail.python.org/mailman/listinfo/python-list
when i rightclick in python idle i get set breakpoint or something.
n options i dont find a way to change to the normal copy/paste options.
--
http://mail.python.org/mailman/listinfo/python-list
[a+b for a,b in zip(xrange(1,51), xrange(50,0,-1))]
[51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51]
i want to add all the elemtns a s well. can
On Jun 22, 6:32 pm, cirfu [EMAIL PROTECTED] wrote:
[a+b for a,b in zip(xrange(1,51), xrange(50,0,-1))]
[51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
On Jun 23, 10:32 am, cirfu [EMAIL PROTECTED] wrote:
[a+b for a,b in zip(xrange(1,51), xrange(50,0,-1))]
[51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
On Jun 23, 9:23 am, Paul Hankin [EMAIL PROTECTED] wrote:
On Jun 23, 10:32 am, cirfu [EMAIL PROTECTED] wrote:
[a+b for a,b in zip(xrange(1,51), xrange(50,0,-1))]
[51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
On Sun, 22 Jun 2008 08:44:25 -0500, Saul Spatz wrote:
macoovacany wrote:
http://macoovacany.wordpress.com/
When I tried to run it, I got all kinds of syntax errors because of
non-ASCII characters; namely, you have fancy left and right single and
double quotes.
That's probably WordPress'
On Jun 22, 4:07�pm, Ken Starks [EMAIL PROTECTED] wrote:
weheh wrote:
I don't know if you found this example:
http://www.daniweb.com/code/snippet285.html
Thanks for that. The offerings are very similar to the
algorithms I wrote myself.
It wasn't the solution I was after,really; that's
On Jun 22, 2:32 pm, Serve Lau [EMAIL PROTECTED] wrote:
What is the expected result of -1/2 in python?
I would say -1, but it depends on whether the - is a unary minus.
-1/2
-1
3 -1/2
3
--
http://mail.python.org/mailman/listinfo/python-list
Pete Kirkham wrote:
2008/6/21 Val-Amart [EMAIL PROTECTED]:
Use PyQt. You will gain great portability +all the functionality built
in qt.
You can try PyGTK also, though i wont recommend it.
Why would you not recommend it? I've been using it for a mall project, and
would like to know if
On Fri, 20 Jun 2008 13:41:35 -0300, Guilherme Polo [EMAIL PROTECTED] wrote:
On Fri, Jun 20, 2008 at 1:11 PM, Peter Pearson [EMAIL PROTECTED] wrote:
Tkinter makes it very easy to drag jpeg images around on a
canvas, but I would like to have a target change color when
the cursor dragging an
On Jun 19, 9:03 pm, John Machin [EMAIL PROTECTED] wrote:
On Jun 20, 10:45 am, Chris [EMAIL PROTECTED] wrote:
On Jun 17, 1:09 pm, [EMAIL PROTECTED] wrote:
Kirk Strauser:
Hint: recursion. Your general algorithm will be something like:
Another solution is to use a better (different)
Fair enough. To help you understand the method I used, I'll give you
this hint. It's true that regex on works on strings. However, is there
any way to convert arbitrarily complex data structures to string
representations? You don't need to be an experienced Python user to
answer to this ;)
You can count me in too.I've been into python for sometime now.
I agree that a collaborative learning makes it fun and helps you reach
your goal faster.
--
http://mail.python.org/mailman/listinfo/python-list
Thanks for all the replies in this post. Just to conclude, I want to
post a piece of code I wrote to encapsulate function creation in this
way:
def create_function(code):
Create and return the function defined in code.
m = re.match('\s*def\s+([a-zA-Z_]\w*)\s*\(', code)
if m:
On Jun 22, 7:41 pm, Peter Pearson [EMAIL PROTECTED] wrote:
On Fri, 20 Jun 2008 13:41:35 -0300, Guilherme Polo [EMAIL PROTECTED] wrote:
On Fri, Jun 20, 2008 at 1:11 PM, Peter Pearson [EMAIL PROTECTED] wrote:
Tkinter makes it very easy to drag jpeg images around on a
canvas, but I would like
class D:pass
d = D()
exec source_code in d.__dict__
print d.some_name
Notice that this will also give you d.__builtins__, which you might
want to del afterwards.
If you want to mimic an import you can also do this:
import types
D = types.ModuleType('D')
exec source_code in D.__dict__
print
On Jun 22, 5:43�am, Jonathan Roberts [EMAIL PROTECTED]
wrote:
Hi all,
I'm looking to learn Python (as my first programming language) and I'm
pretty sure I'd be more successful doing this with a group of other
people.
I've currently got one other person to learn with me, and we plan to
work
Hi,
While using poplib to fetch mails from my gmail account, I am getting
the following error:
Exception is POP3_SSL instance has no attribute 'sslobj'
Can anyone tell me what this error means.
Thanks and Regards
Roopesh
--
http://mail.python.org/mailman/listinfo/python-list
when i rightclick in python idle i get set breakpoint or something.
n options i dont find a way to change to the normal copy/paste options.
Under Preferences ... menu you'll find Keys tab, there you can
change the keys bindings to whatever you want.
HTH,
--
Miki [EMAIL PROTECTED]
Cédric Lucantis wrote:
Le Sunday 22 June 2008 16:07:37 Saul Spatz, vous avez écrit :
Hi,
I'm making a project into my first package, mainly for organization, but
also to learn how to do it. I have a number of data files, both
experimental results and PNG files. My project is organized as a
Adam Olsen [EMAIL PROTECTED] added the comment:
* cause/context cycles should be avoided. Naive traceback printing
could become confused, and I can't think of any accidental way to
provoke it (besides the problem mentioned here.)
* I suspect PyErr_Display handled string exceptions in 2.x, and
Mark Dickinson [EMAIL PROTECTED] added the comment:
I'll take a look.
--
assignee: - marketdickinson
nosy: +marketdickinson
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3167
___
Changes by Mark Dickinson [EMAIL PROTECTED]:
--
assignee: - marketdickinson
nosy: +marketdickinson
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3168
___
Mark Dickinson [EMAIL PROTECTED] added the comment:
Could you tell me what
import math
math.log(float('-inf'))
gives instead of the expected ValueError?
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3167
Facundo Batista [EMAIL PROTECTED] added the comment:
Went for the malloc only patch. Just fixed a small detail (weird corner
case if malloc returned NULL first time, res will be unassigned).
The test could be better (no necessity of using a recursive function, it
could be done with a while),
A.M. Kuchling [EMAIL PROTECTED] added the comment:
This bug was fixed in 2.5 and 2.6, in rev. 60118 and 60119. Thanks for
your bug report!
--
assignee: - akuchling
nosy: +akuchling
resolution: - fixed
status: open - closed
___
Python tracker
Antoine Pitrou [EMAIL PROTECTED] added the comment:
Le dimanche 22 juin 2008 à 07:04 +, Adam Olsen a écrit :
Adam Olsen [EMAIL PROTECTED] added the comment:
* cause/context cycles should be avoided. Naive traceback printing
could become confused, and I can't think of any accidental way
Facundo Batista [EMAIL PROTECTED] added the comment:
What is this fixing? Could you please provide a test cases that fails
without this patch?
Thank you!!
--
nosy: +facundobatista
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3165
Chris Withers [EMAIL PROTECTED] added the comment:
Andi, I'm in total agreement with you :-)
(so if this bug could get fixed, both issues could get closed)
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1974
Adam Olsen [EMAIL PROTECTED] added the comment:
On Sun, Jun 22, 2008 at 8:07 AM, Antoine Pitrou [EMAIL PROTECTED] wrote:
You mean they should be detected when the exception is set? I was afraid
that it may make exception raising slower. Reporting is not performance
sensitive in comparison to
Georg Brandl [EMAIL PROTECTED] added the comment:
Fixed in r64461. Thanks!
--
resolution: - fixed
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3085
___
Georg Brandl [EMAIL PROTECTED] added the comment:
I fixed the docstring in r64463 (2.5 branch, already fixed in trunk) and
expanded the connect() docstring in r64464.
--
resolution: - fixed
status: open - closed
___
Python tracker [EMAIL PROTECTED]
Manuel Kaufmann [EMAIL PROTECTED] added the comment:
This bug was reported on Python 2.5 version and was applied on 2.6
branch. That's correct?
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3085
___
Georg Brandl [EMAIL PROTECTED] added the comment:
Thanks, should be fixed with Sphinx r64465.
--
resolution: - fixed
status: open - closed
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3146
___
Georg Brandl [EMAIL PROTECTED] added the comment:
I don't maintain the 2.5 docs anymore, at least for such minor bugs.
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3085
___
Adam Olsen [EMAIL PROTECTED] added the comment:
On Sun, Jun 22, 2008 at 1:04 PM, Antoine Pitrou [EMAIL PROTECTED] wrote:
Antoine Pitrou [EMAIL PROTECTED] added the comment:
Le dimanche 22 juin 2008 à 17:17 +, Adam Olsen a écrit :
I meant only that trivial cycles should be detected.
Facundo Batista [EMAIL PROTECTED] added the comment:
In Linux, it seems to be the behaviour of the underlying C function 'fread'.
Do you think it's ok to add the following line in the read() documentation?
As this function depends of the underlying C function :cfunc:`fread`,
inheritates its
Antoine Pitrou [EMAIL PROTECTED] added the comment:
Le dimanche 22 juin 2008 à 19:23 +, Adam Olsen a écrit :
For this behaviour, this is the most natural way to write it.
Conceptually, there shouldn't be a cycle
I agree your example is not far-fetched. How about avoiding cycles for
Adam Olsen [EMAIL PROTECTED] added the comment:
On Sun, Jun 22, 2008 at 1:48 PM, Antoine Pitrou [EMAIL PROTECTED] wrote:
Antoine Pitrou [EMAIL PROTECTED] added the comment:
Le dimanche 22 juin 2008 à 19:23 +, Adam Olsen a écrit :
For this behaviour, this is the most natural way to write
Antoine Pitrou [EMAIL PROTECTED] added the comment:
Le dimanche 22 juin 2008 à 19:57 +, Adam Olsen a écrit :
That's still O(n). I'm not so easily convinced it's cheap enough.
O(n) when n will almost never be greater than 5 (and very often equal to
1 or 2), and when the unit is the cost of
Adam Olsen [EMAIL PROTECTED] added the comment:
On Sun, Jun 22, 2008 at 2:20 PM, Antoine Pitrou [EMAIL PROTECTED] wrote:
Antoine Pitrou [EMAIL PROTECTED] added the comment:
Le dimanche 22 juin 2008 à 19:57 +, Adam Olsen a écrit :
That's still O(n). I'm not so easily convinced it's
Antoine Pitrou [EMAIL PROTECTED] added the comment:
Le dimanche 22 juin 2008 à 20:40 +, Adam Olsen a écrit :
How do you duplicate an instance of an user-defined exception? Using
an
equivalent of copy.deepcopy()? It will probably end up much more
expensive than the above-mentioned O(n)
Facundo Batista [EMAIL PROTECTED] added the comment:
Hasan, are you still interested in this or wants to drop this request?
Passing almost two years without comments it's no good if you'll be the
package maintainer.
Thanks!
--
nosy: +facundobatista
Facundo Batista [EMAIL PROTECTED] added the comment:
Skip, don't you think it's better to raise this kind of generic question
in the python-dev list?
This should probably lay down here for ever before a discussion raises
to decide this.
--
nosy: +facundobatista
Facundo Batista [EMAIL PROTECTED] added the comment:
Walter, the import mechanisms changed by a big rework from Brett Cannon
in the last months.
Do you think still have a use case that should be fulfilled? Do you want
to update your patch?
Thank you!
--
nosy: +facundobatista
Changes by Raymond Hettinger [EMAIL PROTECTED]:
--
status: open - closed
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3051
___
___
Python-bugs-list
Changes by Raymond Hettinger [EMAIL PROTECTED]:
--
status: open - closed
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3069
___
___
Python-bugs-list
1 - 100 of 131 matches
Mail list logo