Re: [Zope3-dev] namechooser : object deleted instead of being renamed

2007-07-02 Thread Marius Gedminas
On Mon, Jun 18, 2007 at 07:22:20PM +0300, Marius Gedminas wrote: > On Mon, Jun 18, 2007 at 12:20:57PM +0200, Christophe Combelles wrote: > > Hi, > > > > I've experienced a dangerous behaviour with namechoosers : > > > > If the namechooser computes a name which is the same as the current name, > >

[Zope3-dev] two small bugs in zc.relationship

2007-07-02 Thread Markus Kemmerling
Hi, I discovered two smalll bugs in `zc.relationship`. The first is just a typo in the `ManyToOneRelationship` convenience class of the `shared`module: @@ -149,7 +149,7 @@ interface.implements(interfaces.IManyToOneRelationship) def __init__(self, sources, target): -super(

Re: [Zope3-dev] two small bugs in zc.relationship

2007-07-02 Thread Benji York
Markus Kemmerling wrote: But I wouldn't have expected a non built-in type, that *also* supports the mapping API, to be considered as `False` as long as the mapping is empty ... Built-in or otherwise, empty containers are almost universally "false" in Python. -- Benji York Senior Software E

Re: [Zope3-dev] two small bugs in zc.relationship

2007-07-02 Thread Stefan H. Holek
As a general rule you should avoid taking the boolean value of objects. You never know what the result will be and how expensive the underlying operations are (e.g. computing the length of a BTree can be *very* expensive). Stefan On 2. Jul 2007, at 14:24, Markus Kemmerling wrote: But I w

Re: [Zope3-dev] two small bugs in zc.relationship

2007-07-02 Thread Markus Kemmerling
Certainly true. I just wanted the bug fix to stay in sync with the package author's coding style. He already used logical operator magic to mimic the '?:' ternary operator in a similar method. I myself prefer boring if ... else constructs. Markus Kemmerling Am 02.07.2007 um 14:51 schrieb S

Re: [Zope3-dev] two small bugs in zc.relationship

2007-07-02 Thread Gary Poster
On Jul 2, 2007, at 3:24 PM, Markus Kemmerling wrote: Hi, I discovered two smalll bugs in `zc.relationship`. Thanks, I'll get those in 24 hours or so. FWIW, generally, tests would be appreciated too, particularly of the index. I'll make one for the index: I use that heavily and the tests

Re: [Zope3-dev] package branches

2007-07-02 Thread Jim Fulton
On Jun 27, 2007, at 11:36 AM, Gary Poster wrote: On Jun 27, 2007, at 2:30 AM, Bernd Dorn wrote: On 26.06.2007, at 21:44, Gary Poster wrote: On Jun 26, 2007, at 3:29 PM, Bernd Dorn wrote: i think as long the package has a dev dependency like ZODB 3.9 it should at least have alpha or beta st

RFC: versioning proposal Re: [Zope3-dev] Specifying upper limits in dependencies

2007-07-02 Thread Jim Fulton
See me response to Gary's note. Here's what I propose: 1. We adopt the policy that a distribution's version number must be of less or equal maturity than all of it's dependencies, where maturity is based on it's position in the release cycle. dev is less mature than alpha is less mature t

Re: [Zope3-dev] Re: using utilities/sites from threads in zope3

2007-07-02 Thread Jim Fulton
What Tres said. :) Jim On Jun 29, 2007, at 8:54 AM, Tres Seaver wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Tim Stebbing wrote: G'day, I've recently ran into a bit of a problem attempting to use threads in zope 3.2.1, hooks.getSite() returns None, and any attempt to get a utilit

Re: RFC: versioning proposal Re: [Zope3-dev] Specifying upper limits in dependencies

2007-07-02 Thread Jodok Batlogg
On 02.07.2007, at 20:54, Jim Fulton wrote: See me response to Gary's note. Here's what I propose: 1. We adopt the policy that a distribution's version number must be of less or equal maturity than all of it's dependencies, where maturity is based on it's position in the release cycle. de

Re: [Zope3-dev] package branches

2007-07-02 Thread Gary Poster
On Jul 2, 2007, at 9:42 PM, Jim Fulton wrote: Thanks for reply. quick notes: I think that in *technically* depending on a newer version introduces a backward incompatibility. (It's like strengthening a precondition of a method.) This is especially a problem if people are specifying uppe

Re: [Zope3-dev] package branches

2007-07-02 Thread Benji York
Gary Poster wrote: In that case, would what I released (except that I used "-dev" rather than "dev") be correct? Yep. And those that only want final releases would be required to say so when invoking setuptools (or buildout). -- Benji York Senior Software Engineer Zope Corporation

Re: [Zope3-dev] two small bugs in zc.relationship

2007-07-02 Thread Gary Poster
On Jul 2, 2007, at 6:19 PM, Gary Poster wrote: On Jul 2, 2007, at 3:24 PM, Markus Kemmerling wrote: Hi, I discovered two smalll bugs in `zc.relationship`. Thanks, I'll get those in 24 hours or so. FWIW, generally, tests would be appreciated too, particularly of the index. I'll make on

Re: [Zope3-dev] How to debug zope3 if it completely hangs?

2007-07-02 Thread Jim Fulton
On Jul 1, 2007, at 4:01 PM, Benji York wrote: Fabio Tranchitella wrote: My question is easy: I don't know how to investigate the problem when my Zope instance is not responsive anymore. I tried to use PDB, GDB and friends but without success. One of GDB's friends is strace. It can be ve

Re: [Zope3-dev] package branches

2007-07-02 Thread Jim Fulton
On Jul 2, 2007, at 3:07 PM, Gary Poster wrote: ... Bernd has suggested a policy that I think we should adopt, which is that a package's release status should be no higher than the status of it's dependencies. So, for example, if A depends on a dev version of B, then the version of A that ha

Re: [Zope3-dev] Re: using utilities/sites from threads in zope3

2007-07-02 Thread Tim Stebbing
Thanks Tres, I've ended up with a threadHelper.py module that seems to be working well, I'll post it as its small and might be useful for people googling in the future. """Helper utilities for working with threads.""" from ZODB.interfaces import IDatabase from zope.app import zapi from zope.app.