Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-03-01 Thread Christian Zagrodnick
On 2011-02-28 07:43:55 +0100, Christian Zagrodnick said: On 2011-02-25 21:56:49 +0100, David Glick said: On 2/20/11 1:32 AM, Christian Zagrodnick wrote: On 2011-02-19 17:17:44 +0100, Hanno Schlichting said: On Thu, Feb 17, 2011 at 8:27 AM, Christian Zagrodnickc...@gocept.com wrote: On

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-03-01 Thread David Glick
On 3/1/11 11:57 AM, Christian Zagrodnick wrote: This change introduces a regression when calling unicode on wrapped objects that implement __str__ but not __unicode__. Essentially it is now doing the equivalent of str(aq_base(obj)) ... __str__ used to get a wrapped object as 'self', but now it

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-27 Thread Christian Zagrodnick
On 2011-02-25 21:56:49 +0100, David Glick said: On 2/20/11 1:32 AM, Christian Zagrodnick wrote: On 2011-02-19 17:17:44 +0100, Hanno Schlichting said: On Thu, Feb 17, 2011 at 8:27 AM, Christian Zagrodnickc...@gocept.com wrote: On 2011-02-16 22:22:53 +0100, Hanno Schlichting said:

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-25 Thread David Glick
On 2/20/11 1:32 AM, Christian Zagrodnick wrote: On 2011-02-19 17:17:44 +0100, Hanno Schlichting said: On Thu, Feb 17, 2011 at 8:27 AM, Christian Zagrodnickc...@gocept.com wrote: On 2011-02-16 22:22:53 +0100, Hanno Schlichting said:

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-20 Thread Christian Zagrodnick
On 2011-02-19 17:17:44 +0100, Hanno Schlichting said: On Thu, Feb 17, 2011 at 8:27 AM, Christian Zagrodnick c...@gocept.com wrote: On 2011-02-16 22:22:53 +0100, Hanno Schlichting said: svn+ssh://svn.zope.org/repos/main/Acquisition/branches/zagy-unicode-should-be-called Sure. I'll review,

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-19 Thread Hanno Schlichting
On Thu, Feb 17, 2011 at 8:27 AM, Christian Zagrodnick c...@gocept.com wrote: On 2011-02-16 22:22:53 +0100, Hanno Schlichting said: svn+ssh://svn.zope.org/repos/main/Acquisition/branches/zagy-unicode-should-be-called Sure. I'll review, merge and release. Should be sometime this week, cannot

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-16 Thread Michael Howitz
Am 15.02.2011 um 14:35 schrieb Michael Howitz: [...] print unicode(a.__of__(app)) __str__ called [...] This happens for Python 2.6 and 2.7 on Zope 2.13.4. Zope 2.12.8 on Python 2.6 breaks the same way as 2.13. But Zope 2.11.7 on Python 2.5 works correctly. So either Python or Acquisition must

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-16 Thread Hanno Schlichting
On Wed, Feb 16, 2011 at 9:18 AM, Michael Howitz m...@gocept.com wrote: Zope 2.12.8 on Python 2.6 breaks the same way as 2.13. But Zope 2.11.7 on Python 2.5 works correctly. So either Python or Acquisition must have changed since than. Acquisition changed a lot from 2.11 to 2.12 - it got

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-16 Thread Christian Zagrodnick
On 2011-02-16 10:10:05 +0100, Hanno Schlichting said: On Wed, Feb 16, 2011 at 9:18 AM, Michael Howitz m...@gocept.com wrote: Zope 2.12.8 on Python 2.6 breaks the same way as 2.13. But Zope 2.11.7 on Python 2.5 works correctly. So either Python or Acquisition must have changed since than.

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-16 Thread Hanno Schlichting
On Wed, Feb 16, 2011 at 10:19 PM, Christian Zagrodnick c...@gocept.com wrote: I suspect a change in python (which I did not follow up after getting strange feelings when looking at PyObject_Unicode). Nevertheless I've fixed that on a branch:

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-16 Thread Christian Zagrodnick
On 2011-02-16 22:22:53 +0100, Hanno Schlichting said: On Wed, Feb 16, 2011 at 10:19 PM, Christian Zagrodnick c...@gocept.com wrote: I suspect a change in python (which I did not follow up after getting strange feelings when looking at PyObject_Unicode). Nevertheless I've fixed that on a

[Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-15 Thread Michael Howitz
Hi, When I have an acquisition wrapped object, e. g. my_object and call: unicode(my_object) The method __str__ of my_object is called even when it has an __unicode__ method. See the following bin/zopectl debug session: $ bin/zinstance debug Starting debugger (the name app is bound to the

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-15 Thread Hanno Schlichting
On Tue, Feb 15, 2011 at 2:35 PM, Michael Howitz m...@gocept.com wrote: When I have an acquisition wrapped object, e. g. my_object and call: unicode(my_object) The method __str__ of my_object is called even when it has an __unicode__ method. Acquisition wrappers only fill the tp_repr and

Re: [Zope-dev] Acquisition wrapped objects do not behave well on unicode call

2011-02-15 Thread Christian Zagrodnick
On 2011-02-15 15:26:28 +0100, Hanno Schlichting said: On Tue, Feb 15, 2011 at 2:35 PM, Michael Howitz m...@gocept.com wrote: When I have an acquisition wrapped object, e. g. my_object and call: unicode(my_object) The method __str__ of my_object is called even when it has an __unicode__