Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Zope: Coders

Who owns the ZCatalog package?

 

 

Zope coders RSS feed   Index | Next | Previous | View Threaded


steve at cat-box

Sep 26, 2001, 10:26 AM

Post #1 of 4 (914 views)
Permalink
Who owns the ZCatalog package?

Hi folks,

I posted the following patch to Zope-Dev.

It fixes a bad interaction between some ZCatalog queries and dtml-in.
Sometimes, dtml-in only iterates through a part of the results.

The problem is that Catalog.py is giving a LazyCat instance the wrong
length for a concatenation of sequences; it is giving the number of
sequences rather than the sum of the lengths of the sequences.

Can I just check this in, or do I need to get approval from the owner of
the ZCatalog package?


*** lib/python/Products/ZCatalog/Catalog.py.original
--- lib/python/Products/ZCatalog/Catalog.py.patched
***************
*** 673,679 ****
if (type(so) is type('') and
lower(so) in ('reverse', 'descending')):
r.reverse()
! r=LazyCat(map(lambda i: i[1], r), len(r))

return r

--- 673,681 ----
if (type(so) is type('') and
lower(so) in ('reverse', 'descending')):
r.reverse()
! r=map(lambda i: i[1], r)
! r=LazyCat(r, reduce(lambda x,y: x+len(y), r, 0))
!

return r

--
Steve Alexander
Software Engineer
Cat-Box limited


chrism at zope

Sep 26, 2001, 10:55 AM

Post #2 of 4 (852 views)
Permalink
Re: Who owns the ZCatalog package? [In reply to]

Hi Steve,

I'm afraid you're going to find out that the boundaries of ownership are
pretty flexible as regards packages in Zope... ZCatalog especially!

As a person who worked on Catalog guts before, however, the patch looks good
to me... I'd document the reduce statement with a short note and check it
in.

Welcome!

- C


----- Original Message -----
From: "Steve Alexander" <steve [at] cat-box>
To: <zope-coders [at] zope>
Sent: Wednesday, September 26, 2001 1:26 PM
Subject: [Zope-Coders] Who owns the ZCatalog package?


> Hi folks,
>
> I posted the following patch to Zope-Dev.
>
> It fixes a bad interaction between some ZCatalog queries and dtml-in.
> Sometimes, dtml-in only iterates through a part of the results.
>
> The problem is that Catalog.py is giving a LazyCat instance the wrong
> length for a concatenation of sequences; it is giving the number of
> sequences rather than the sum of the lengths of the sequences.
>
> Can I just check this in, or do I need to get approval from the owner of
> the ZCatalog package?
>
>
> *** lib/python/Products/ZCatalog/Catalog.py.original
> --- lib/python/Products/ZCatalog/Catalog.py.patched
> ***************
> *** 673,679 ****
> if (type(so) is type('') and
> lower(so) in ('reverse', 'descending')):
> r.reverse()
> ! r=LazyCat(map(lambda i: i[1], r), len(r))
>
> return r
>
> --- 673,681 ----
> if (type(so) is type('') and
> lower(so) in ('reverse', 'descending')):
> r.reverse()
> ! r=map(lambda i: i[1], r)
> ! r=LazyCat(r, reduce(lambda x,y: x+len(y), r, 0))
> !
>
> return r
>
> --
> Steve Alexander
> Software Engineer
> Cat-Box limited
>
>
> _______________________________________________
> Zope-Coders mailing list
> Zope-Coders [at] zope
> http://lists.zope.org/mailman/listinfo/zope-coders
>


andreas at zope

Sep 26, 2001, 10:58 AM

Post #3 of 4 (859 views)
Permalink
Re: Who owns the ZCatalog package? [In reply to]

Steve,

I checked the patch into the trunk. But feel free to checkin the patch
on your own into the Zope-2_4-branch.

Andreas
----- Original Message -----
From: "Steve Alexander" <steve [at] cat-box>
To: <zope-coders [at] zope>
Sent: Wednesday, September 26, 2001 13:26
Subject: [Zope-Coders] Who owns the ZCatalog package?


> Hi folks,
>
> I posted the following patch to Zope-Dev.
>
> It fixes a bad interaction between some ZCatalog queries and dtml-in.
> Sometimes, dtml-in only iterates through a part of the results.
>
> The problem is that Catalog.py is giving a LazyCat instance the wrong
> length for a concatenation of sequences; it is giving the number of
> sequences rather than the sum of the lengths of the sequences.
>
> Can I just check this in, or do I need to get approval from the owner of
> the ZCatalog package?
>
>
> *** lib/python/Products/ZCatalog/Catalog.py.original
> --- lib/python/Products/ZCatalog/Catalog.py.patched
> ***************
> *** 673,679 ****
> if (type(so) is type('') and
> lower(so) in ('reverse', 'descending')):
> r.reverse()
> ! r=LazyCat(map(lambda i: i[1], r), len(r))
>
> return r
>
> --- 673,681 ----
> if (type(so) is type('') and
> lower(so) in ('reverse', 'descending')):
> r.reverse()
> ! r=map(lambda i: i[1], r)
> ! r=LazyCat(r, reduce(lambda x,y: x+len(y), r, 0))
> !
>
> return r
>
> --
> Steve Alexander
> Software Engineer
> Cat-Box limited
>
>
> _______________________________________________
> Zope-Coders mailing list
> Zope-Coders [at] zope
> http://lists.zope.org/mailman/listinfo/zope-coders
>


brian.lloyd at zope

Sep 26, 2001, 10:59 AM

Post #4 of 4 (853 views)
Permalink
RE: Who owns the ZCatalog package? [In reply to]

> I posted the following patch to Zope-Dev.
>
> It fixes a bad interaction between some ZCatalog queries and dtml-in.
> Sometimes, dtml-in only iterates through a part of the results.
>
> The problem is that Catalog.py is giving a LazyCat instance the wrong
> length for a concatenation of sequences; it is giving the number of
> sequences rather than the sum of the lengths of the sequences.
>
> Can I just check this in, or do I need to get approval from the owner of
> the ZCatalog package?

Andreas Jung (andreas [at] zope) is the de facto Catalog bubba
right now, so make sure to run the changes by him.

The committer / CVS info area on dev.zope.org has a page that
deals with this from a high level:

http://dev.zope.org/CVS/RepositoryProjects

...but doesn't note areas of responsibility within the large-grained
projects. We should put up (and keep up to date) a page that notes
who the bubba is for various aspects of the code.

Also, when you go to check this in, we need to make sure that the
fix goes in the trunk as well as the 2.4 branch (Zope-2_4-branch),
and that the CHANGES.txt in the 2.4 branch is updated.

I need to make sure that something on the dev site deals with this
as well. I think of it as a "checkin checklist" that should cover:

- what the next planned bug fix release is

- what the current bug-fix release branch is (where all bug
fixes, but not new features, should be checked in)

- what the next planned feature release is

- what the correct branch is to check in both bug fixes and
new features

- who to ask if its not clear what to do

I'll try to make some progress on these today.


Brian Lloyd brian [at] zope
Zope Corporation www.zope.com

Zope coders RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.