Re: (Was Re: [Framework-Team] Minutes: 8 August 2009)

2009-08-06 Thread Wichert Akkerman

On 2009-8-6 06:30, David Glick wrote:

Does anyone know the background or justification for
http://dev.plone.org/old/archetypes/changeset/9318 where the switch to
an IPublishTraverse adapter first happened? Wichert?


The reasoning behind that is a) we want to get rid of __bobo_traverse__ 
methods and b) this change transparently exposes all image where the 
original code only hardcoded exposure of a field with the name 'iage'.


I don't quite see what the problem is with that code; can someone 
explain that?


Wichert.


--
Wichert Akkerman wich...@wiggy.net   It is simple to make things.
http://www.wiggy.net/  It is hard to make things simple.

___
Framework-Team mailing list
Framework-Team@lists.plone.org
http://lists.plone.org/mailman/listinfo/framework-team


Re: (Was Re: [Framework-Team] Minutes: 8 August 2009)

2009-08-06 Thread Andreas Zeidler

On Aug 6, 2009, at 6:30 AM, David Glick wrote:

On Aug 5, 2009, at 1:45 PM, Alec Mitchell wrote:
On Wed, Aug 5, 2009 at 1:18 PM, David Glickdavidgl...@onenw.org  
wrote:
* IPublishTraverse is used where ITraverse should be; that's why  
some

linkintegrity tests are failing.


Actually they both need to be used.  And that's just a guess -- I  
haven't

actually looked at this yet.


It doesn't look like there's any way to override OFS traversal  
using a

component (other than a view of course).  Perhaps we should just be
using the existing custom __getitem__ that's already in
BaseObject/BaseFolder instead of traversal magic.


That seems like a decent idea to me, given that we need this to work  
for publish traversal, OFS traversal, and path expressions in order  
to avoid regressions.


i've just tested linkintegrity in a blob-enabled setup (in order to  
use the traversal adapter from `plone.app.imaging` in a known to work  
environment, i.e. plone 3.x) and it turns out that it still has 13  
failures — as opposed to the 25 currently seen in tests against plone  
4.0.  the remaining 12 failure are very likely due to the default  
mime-type issue (which in turn seems to be caused by the patch in https://bugs.launchpad.net/zope2/+bug/143948 
 — thanks to david for investigating, btw).


Does anyone know the background or justification for http://dev.plone.org/old/archetypes/changeset/9318 
 where the switch to an IPublishTraverse adapter first happened?   
Wichert?


since `p.a.blob` currently depends on `p.a.imaging`, which has the  
same traversal adapter as wichert introduced here, and image support  
will be required for the respective 4.0 plip, this needs to be fixed  
for linkintegrity to work again anyway.  iow, i'll try to look into it  
during the sprint...


Even if we use BaseObject's __getitem__, we probably ought to make  
the image scale lookup be adapter-based...I know that Andi has had  
plans to take advantage of the IPublishTraverse adapter in  
plone.app.imaging to override how scales are found (see http://svn.plone.org/svn/plone/plone.app.imaging/trunk/src/plone/app/imaging/traverse.py 
 -- but this ImageTraverser isn't actually registered anywhere yet).


those plans have long been carried out and the adapter is registered,  
in fact — see http://dev.plone.org/plone/changeset/27627 :)


cheers,


andi

--
zeidler it consulting - http://zitc.de/ - i...@zitc.de
friedelstraße 31 - 12047 berlin - telefon +49 30 25563779
pgp key at http://zitc.de/pgp - http://wwwkeys.de.pgp.net/
plone 3.3rc4 released! -- http://plone.org/products/plone/



PGP.sig
Description: This is a digitally signed message part
___
Framework-Team mailing list
Framework-Team@lists.plone.org
http://lists.plone.org/mailman/listinfo/framework-team


Re: (Was Re: [Framework-Team] Minutes: 8 August 2009)

2009-08-06 Thread Andreas Zeidler

On Aug 6, 2009, at 2:42 PM, Andreas Zeidler wrote:

On Aug 6, 2009, at 6:30 AM, David Glick wrote:

On Aug 5, 2009, at 1:45 PM, Alec Mitchell wrote:
On Wed, Aug 5, 2009 at 1:18 PM, David Glickdavidgl...@onenw.org  
wrote:
* IPublishTraverse is used where ITraverse should be; that's why  
some

linkintegrity tests are failing.


Actually they both need to be used.  And that's just a guess -- I  
haven't

actually looked at this yet.


It doesn't look like there's any way to override OFS traversal  
using a

component (other than a view of course).  Perhaps we should just be
using the existing custom __getitem__ that's already in
BaseObject/BaseFolder instead of traversal magic.


That seems like a decent idea to me, given that we need this to  
work for publish traversal, OFS traversal, and path expressions in  
order to avoid regressions.


i've just tested linkintegrity in a blob-enabled setup (in order to  
use the traversal adapter from `plone.app.imaging` in a known to  
work environment, i.e. plone 3.x) and it turns out that it still has  
13 failures [...]


btw, are there any other reasons/breakages besides the linkintegrity  
failures?  i suppose i could make the latter aware of the traversal  
adapter, too.  do we know of any (important) 3rd-party products that  
rely on being able to traverse to image scales the old way?



cheers,


andi


--
zeidler it consulting - http://zitc.de/ - i...@zitc.de
friedelstraße 31 - 12047 berlin - telefon +49 30 25563779
pgp key at http://zitc.de/pgp - http://wwwkeys.de.pgp.net/
plone 3.3rc4 released! -- http://plone.org/products/plone/



PGP.sig
Description: This is a digitally signed message part
___
Framework-Team mailing list
Framework-Team@lists.plone.org
http://lists.plone.org/mailman/listinfo/framework-team


Re: (Was Re: [Framework-Team] Minutes: 8 August 2009)

2009-08-05 Thread David Glick

On Aug 5, 2009, at 1:45 PM, Alec Mitchell wrote:
On Wed, Aug 5, 2009 at 1:18 PM, David Glickdavidgl...@onenw.org  
wrote:
* IPublishTraverse is used where ITraverse should be; that's why  
some

 linkintegrity tests are failing.


Actually they both need to be used.  And that's just a guess -- I  
haven't

actually looked at this yet.


It doesn't look like there's any way to override OFS traversal using a
component (other than a view of course).  Perhaps we should just be
using the existing custom __getitem__ that's already in
BaseObject/BaseFolder instead of traversal magic.



That seems like a decent idea to me, given that we need this to work  
for publish traversal, OFS traversal, and path expressions in order to  
avoid regressions.


Does anyone know the background or justification for http://dev.plone.org/old/archetypes/changeset/9318 
 where the switch to an IPublishTraverse adapter first happened?   
Wichert?


Even if we use BaseObject's __getitem__, we probably ought to make the  
image scale lookup be adapter-based...I know that Andi has had plans  
to take advantage of the IPublishTraverse adapter in plone.app.imaging  
to override how scales are found (see http://svn.plone.org/svn/plone/plone.app.imaging/trunk/src/plone/app/imaging/traverse.py 
 -- but this ImageTraverser isn't actually registered anywhere yet).



David Glick
Web Developer
ONE/Northwest

New tools and strategies for engaging people in protecting the  
environment


http://www.onenw.org
davidgl...@onenw.org
work: (206) 286-1235 x32
mobile: (206) 679-3833

Subscribe to ONEList, our email newsletter!
Practical advice for effective online engagement
http://www.onenw.org/full_signup





___
Framework-Team mailing list
Framework-Team@lists.plone.org
http://lists.plone.org/mailman/listinfo/framework-team