Re: [Zope3-Users] Looking for the Z3C tutorial?

2008-10-10 Thread Roger Ineichen
Hi Betreff: Re: [Zope3-Users] Looking for the Z3C tutorial? On Oct 9, 2008, at 12:02 PM, Paul Carduner wrote: Hi everyone, My website that was hosting the z3c tutorial recently went down. I haven't had time to diagnose the problems and bring it back up. In the mean time, I

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Roger Ineichen
Hi Betreff: Re: [Zope3-Users] WrongContainedType [...] By reading the source code. Object field validation actually attempts to validate the schema (IObjectId in this case) of the object you're trying to store (the ObjectId object, in this case). If any of the fields cannot be

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Tim Cook
On Fri, 2008-10-10 at 11:07 +0200, Roger Ineichen wrote: What do you think about a validateSchema=True/False option or something like that? Maybe it's just a requirement to fix the code? The code at around line 466 in _field.py says errors = _validate_fields(self.schema, value)

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Roger Ineichen
Hi Tim Betreff: Re: [Zope3-Users] WrongContainedType On Fri, 2008-10-10 at 11:07 +0200, Roger Ineichen wrote: What do you think about a validateSchema=True/False option or something like that? Maybe it's just a requirement to fix the code? The code at around line 466 in _field.py

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Tim Cook
On Fri, 2008-10-10 at 12:38 -0300, Tim Cook wrote: Maybe it's just a requirement to fix the code? The code at around line 466 in _field.py says errors = _validate_fields(self.schema, value) if errors: raise WrongContainedType(errors) errors is an empty list

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Tim Cook
On Fri, 2008-10-10 at 17:46 +0200, Roger Ineichen wrote: I guess not, normaly such an error has an empty representation and the list is not empty. Try to do errors[0] or type(errors[0]) and you probably see something. If not I'm confused Well, I'm confused anyway, but that isn't difficult.

Re: [Zope3-Users] ZCML Layout Decision?

2008-10-10 Thread Tim Cook
On Thu, 2008-10-09 at 09:28 -0700, Marius Gedminas wrote: Have you considered Grok? I looked at Grok when I first started this project about a yer ago. I didn't really see much help there at the time so I used zopeproject to kickstart a foundation and started building from that. Well, at

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Roger Ineichen
Hi Tim Betreff: Re: AW: [Zope3-Users] WrongContainedType On Fri, 2008-10-10 at 17:46 +0200, Roger Ineichen wrote: I guess not, normaly such an error has an empty representation and the list is not empty. Try to do errors[0] or type(errors[0]) and you probably see something.

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Tim Cook
Thanks for your help Roger, On Fri, 2008-10-10 at 18:19 +0200, Roger Ineichen wrote: The error (probably, not sure) means that the object you like to store has a missing value. Can you check the schema of this object and set required=False in all fields? Did that in both schemas on my

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Marius Gedminas
On Fri, Oct 10, 2008 at 06:19:48PM +0200, Roger Ineichen wrote: Hi Tim Betreff: Re: AW: [Zope3-Users] WrongContainedType On Fri, 2008-10-10 at 17:46 +0200, Roger Ineichen wrote: I guess not, normaly such an error has an empty representation and the list is not empty. Try to

Re: [Zope3-Users] ZCML Layout Decision?

2008-10-10 Thread John de la Garza
Tim Cook wrote: Well, at your suggestion I have given Grok a new try. I think I can best express my opinion as: **GROK IS FRICKEN AWESOME!!*** I've been trying to get into using Zope for a while and was overwhelmed. I started using Grok about 3 weeks ago and was able to understand it.

[Zope3-Users] Grok and Permissions was: ZCML Layout Decision?

2008-10-10 Thread Tim Cook
On Fri, 2008-10-10 at 10:30 -0700, John de la Garza wrote: I much prefer configuring permissions outside of my python code and having the app server handle it than checking if a person is authenticated before a method's main body. Hmmm, It is my impression so far (and that isn't very far)

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Tim Cook
On Fri, 2008-10-10 at 14:01 -0300, Tim Cook wrote: The code for these are quite verbose and will certainly obscure the commentary so I hope it's okay that I post links to the SVN within the comments? Well, that isn't very helpful I just discovered that the svn servers will be down all

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Roger Ineichen
Hi Tim Betreff: Re: AW: AW: [Zope3-Users] WrongContainedType Thanks for your help Roger, On Fri, 2008-10-10 at 18:19 +0200, Roger Ineichen wrote: The error (probably, not sure) means that the object you like to store has a missing value. Can you check the schema of this object

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Tim Cook
On Fri, 2008-10-10 at 21:17 +0200, Roger Ineichen wrote: I do not fully understand what the codes does but this does not work: ontObj.parentArchetype = '' Because it will set an empty string but an IObjectRef is needed. Thats' not valid, just let it be, don't set anything else then an

Re: [Zope3-Users] WrongContainedType

2008-10-10 Thread Marius Gedminas
On Fri, Oct 10, 2008 at 09:17:08PM +0200, Roger Ineichen wrote: Also this doesn't work: terminologiesAvailable=List( title=_(uTerminologies), description=_(uList of terminologies in this ontology.), required=True, value_type=TextLine(), default=[], Ouch, careful!