IRC log of #zope3-dev for Wednesday, 2005-09-07

*** _srichter has joined #zope3-dev00:00
*** sashav has quit IRC00:05
*** _strichter has joined #zope3-dev00:08
*** srichter has quit IRC00:09
*** _strichter is now known as srichter00:09
*** ChanServ sets mode: +o srichter00:09
*** _srichter was kicked by srichter (User terminated!)00:10
*** strichter was kicked by srichter (User terminated!)00:10
benji_yorksrichter, that'll teach you!00:11
srichterLOL :-)00:14
srichteryeah, I had to kick my other zombie selfs out00:15
*** sashav has joined #zope3-dev00:21
*** bradb is now known as bradb-away00:27
*** Alef has joined #zope3-dev00:28
*** projekt01 has joined #zope3-dev00:30
J1msrichter, are you aware that Tim wants advanced warning of z3 releases?00:41
srichterJ1m: yes, this is the reason I sent the message today00:44
srichterTim was also part of the discussion that will prompt the new RC00:44
srichterJ1m: I think we want DirectResult and StrResult be part of base.py00:45
*** Alef has quit IRC00:46
srichtersince the base response currently does not ensure that the passed in result is really a result object00:46
J1mI suppose.00:46
J1mIResult defines headers.00:46
J1mHeaders only make sense for HTTP.00:47
srichtermmh, true00:47
srichtermaybe it should not00:47
srichteror maybe it should00:47
J1mBut, really, the publisher only makes sense for HTTP. :)00:47
srichterok, I forgot that we are only dealing with HTTP right now00:47
srichterI have a feeling that eventually IResult will not have headers, but there will be an IHTTPResult that does00:48
J1mI have a hope that someday we stop trying to wedge every protocol into the publisher.00:48
srichterI would be even willing to implement this, but I do not see how this can be done for FTP00:49
J1mWhat "this" are you refering to?00:52
srichternot using the publisher for FTP00:52
srichterin Zope 3, no other protocols are using the publisher00:53
J1mIf I was starting over for FTP (and I probably wouldn't bother :), I would have a server-side object that represented the ftp session and had state that included the current position in the object system.00:54
J1mThis would obviously be stateful.00:54
J1mIn fact, we already do this, but we force this poor beast to go through the publisher for every operation.00:54
*** bradb-away is now known as bradb00:55
J1mNote that session object would become the "request".00:55
srichterand who would do the traversal?00:56
srichtera lot of machinery exists in the publisher that deals with finding an object in the path00:56
J1mThere would probably be some sort of FTP machine that did the traversal in much the way we do now.00:56
J1mOf coursem the traversal would be stateful.00:56
J1mActually, not that much.00:57
srichtermmh, keeping the current object around sounds interesting00:57
J1mIt could still use the publication model.00:57
srichterthis way cd .. is very easy00:57
srichter(to implement)00:57
*** GaryPoster has quit IRC00:58
srichter(I am asking all this since people will want to implement new protocols once twisted is integrated)00:58
J1mauthentication remains a tad tricky.00:58
srichterso I want to have a good answer around; maybe FTP could be used as some sort of test case00:58
*** benji_york has quit IRC01:23
*** jinty has joined #zope3-dev01:29
*** jinty has quit IRC01:47
*** yota has quit IRC01:55
*** stub has joined #zope3-dev01:58
*** J1m has quit IRC02:10
*** bradb has quit IRC02:59
*** bradb has joined #zope3-dev03:00
*** bradb has left #zope3-dev03:02
*** fdrake has left #zope3-dev03:15
*** sashav has joined #zope3-dev03:27
*** sashav has quit IRC03:44
*** tiredbones has joined #zope3-dev04:04
*** GaryPoster has joined #zope3-dev04:13
GaryPosterstub, ayt?04:14
GaryPostercool. :-)04:14
GaryPosterUm, so trying to explain the i18n problem that may or may not be related to pytz...04:15
GaryPosterLet's see.  The most informative mail thread is "Failing test, Zope 3 trunk, Windows"04:15
GaryPosterThe proximate cause for the ruckus is that the pytz check in you made on the trunk made a test fail in zope.i18n.  When we looked at the test that failed, we all saw that it was a bit insane.04:16
GaryPosterThat is, i18n was actually broken both in 3.1 and on the trunk, before your checkin, but we had a broken test hiding it.04:17
GaryPosterYour checkin made the test fail in a new way (sadly, it was still not correct).04:18
stuburg.. EST is a deprecated timezone name. It is probably an alias to US/Eastern04:18
GaryPosterI wondered about that.  I thought about changing the test to only use US/Eastern and puking if someone used EST.  That has a couple of problems...not least that it still doesn't explain why EST would be 5 hours and 20 minutes off from UTC.04:20
GaryPoster(Which it is now; it used to be 6 hours, which was also wrong)04:20
GaryPosterI looked briefly at the Olson data, and didn't see any reference to 5 hours and 20 minutes; just 5 hours.04:21
GaryPosterI said that puking on EST had another problem--the other problem is that the i18n database apparently still uses EST, so it would be nice if it were sane.04:22
GaryPosterTim's last email pointed most significantly at pytz for the oddity: see his last email in the "Failing test,..." thread04:24
GaryPoster(I'm about to have to go, btw)04:25
stubOk... so what is happening is that the EST zone contains two different periods. EST and CST. EST came into existance in 1908.04:25
stubAlso, when you construct a datetime in localtime using pytz, you need to use the localize() method as documented in the README04:27
GaryPosterAh, so the i18n code is using pytz incorrectly?04:27
stubIf localize() is called at the relevant points, the correct information for 2003 will be used and everything should be dandy04:28
stubI think that is the issue ;)04:28
GaryPosterAh ok.  Well, that's a lot more than I had to go on before. :-)04:28
GaryPosterOK, I need to run around and do some stuff.  Then I'll see if I can fix the i18n stuff (unless you are feeling particularly noble and full-of-vigor-and-free-time :-) )04:29
stubI was still considering the source api, and if I should accept the arguments or rant ;)04:30
GaryPosterheh, as you see fit :-)04:34
*** projekt01 has quit IRC04:35
*** bradb has joined #zope3-dev04:42
stubGaryPoster: I'll have a look at it actually04:45
GaryPosterAwesome!  My wife will thank you for it! :-)04:46
stubUrgh.... more issues. It is creating custom StaticTzInfo instances that I doubt will be picklable with the new code...04:48
GaryPosterThat's not a use case we have talked about yet, fwiw: we say "store your dates in UTC, display your dates in what you can guess the user wants, store timezones as generated from pytz.timezones"04:52
GaryPosterpytz.timezone I meant04:53
GaryPoster(But if it is fixable with changes to i18n, so that the dates are picklable, sounds good to me :-) ).  BTW, since Stephan is going to do an RC3 of 3.1, we can get the new pytz in 3.1, and ideally also get the improved locale timezones in the i18n locale.04:56
*** dman13 has quit IRC05:46
*** dman13 has joined #zope3-dev05:49
*** roym has quit IRC06:20
*** GaryPoster has quit IRC06:25
*** sashav has joined #zope3-dev07:44
*** stu1 has joined #zope3-dev07:57
*** stub has quit IRC07:57
*** sashav has quit IRC08:23
*** stu1 has quit IRC09:03
*** j-w has joined #zope3-dev09:06
*** sashav has joined #zope3-dev09:31
*** yota has joined #zope3-dev09:36
*** tiredbones has quit IRC09:36
*** hdima has joined #zope3-dev09:39
bob2are sources ready to replace vocabularies?09:41
bob2trying to generate a vocabulary for a workflow seems to be harder than I thought09:41
*** MJ has quit IRC09:45
*** Alef has joined #zope3-dev10:32
*** jhauser has joined #zope3-dev10:44
*** BjornT has quit IRC10:49
*** stub has joined #zope3-dev10:56
*** MJ has joined #zope3-dev11:04
*** mgedmin has joined #zope3-dev11:06
*** projekt01 has joined #zope3-dev11:13
bob2is it reasonable to use a view on one object to affect another?11:13
mgedminif it makes sense from the end-user's point of view11:15
mgedminand you don't introduce unnecessary dependencies between components11:15
bob2I'm sort of conceptually lost11:16
bob2I have a component, which has a bunch of metadata11:16
bob2handled through various adapters11:16
bob2but I'd like to present a view which lets you twiddle them all at once11:16
mgedminperhaps pagelets/portlets would be a solution?11:17
bob2they don't seem to be mentioned in either of the Books11:18
mgedminI personally haven't used them yet, BTW, so I might be talking nonsense11:18
mgedmintake a look at
mgedminI think that would work fine if your single big page can be modularized (e.g. a bunch of boxes, one for each adapter)11:19
mgedminotoh if your big page is mix-n-match (this input box here is IFoo(context).foo, the next one is just, the third one is again IFoo(context).baz)11:20
mgedminthen hardcoding everything in a single view might be the only option11:20
*** Alef has quit IRC11:23
bob2perhaps that's a solution to my "how to have a container view that modifies all the containees" problem, too11:24
projekt01bob2, it's a base concept to use views in views or even in templates directly11:27
projekt01bob2, see also the addform concept there is a view called on a view11:27
projekt01bob2, or the @@absolute_url is a view where is designed to be called in a template11:28
*** vlado has joined #zope3-dev11:29
projekt01bob2, in your case grep for "getMultiAdapter" and you will find views where call other views.11:30
bob2this is complicated :|11:30
mgedminis it?11:30
mgedminrender a named view on a subobject in a page template:11:30
mgedmin<div tal:replace="structure some_subobject/@@view_name">...</div>11:30
mgedmincall some helper function of a named view on a subobject in a page template:11:31
*** j-w has quit IRC11:31
mgedmin<span tal:replace="some_subobject/@@view_name/function">...</span>11:31
mgedminor do that more than once11:31
mgedmin<div tal:define="helper_view nocall:some_subobject/@@view_name">11:31
mgedmin  <span tal:replace="helper_view/foo">...</span>11:31
mgedmin  <span tal:replace="helper_view/bar">...</span>11:31
mgedminok, in view code it gets slightly more complicated11:32
mgedmindef some_view_function(self):11:32
mgedmin    ...11:32
bob2this doesn't seem too bad, for displaying things11:32
bob2handling edits sounds harder11:32
projekt01bob2, btw, don't be confused about imagine what is a view. Think about a view is just a non persistent python instance where can have views.11:32
mgedmin    helper_view = zapi.getMultiAdapter((some_subobject, self_request), name='view_name')11:32
mgedmin    helper_view.update_from_form_data()11:33
mgedminactually, if your view expects other views to have some named methods (e.g. to handle form updates)11:35
mgedminit would be cleander to get views by interface rather than by name11:35
mgedminzapi.getMultiAdapter((some_subobject, self.request), ISomeKindaView)11:35
bob2zope3 gets a lot more complicated once you move beyond having single pages editing single objects11:36
*** j-w has joined #zope3-dev11:37
mgedminwell, the problem gets more complicated11:37
bob2oh, I know11:38
projekt01mgedmin, you also can use in this case. It's more reusable if needed.11:38
SteveAi know jim would like to make this read simpler with ISomeKindaView(some_subobject, self.request)11:38
mgedminI'd love to see a nice, simple solution for complex pages editing many objects, in any web framework11:38
SteveAbut, it is hard to allow that11:38
mgedminthen I could reimplement it in zope 3 ;)11:38
bob2SteveA: maybe accept a tuple of both as the first argument?11:38
bob2I think my real problem is that neither of the Books go into this sort of complicated scenario11:39
mgedminbob2, here's you chance to write a third book and become famous forever!11:40
bob2is formlib something that could help wit hthis?11:49
*** bradb has quit IRC12:01
*** bradb has joined #zope3-dev12:01
*** vlado has quit IRC12:22
*** vlado has joined #zope3-dev12:23
projekt01bob2, yes12:28
bob2it looks interesting12:28
bob2but running some of the code from form.txt gives me this:12:28
bob2zope.component.interfaces.ComponentLookupError: ((<zope.schema._bootstrapfields.Int object at 0xb750a14c>, <zope.publisher.browser.TestRequest instance URL=>), <InterfaceClass>, u'')12:28
*** vlado has quit IRC12:35
mgedminrunning it how?12:35
mgedminin an interactive Python session?  in a unit test?12:35
mgedminbob2, that error indicates missing component registrations12:35
bob2by cutting and pasting from it to a python file12:35
mgedminit should never happen in real life or in a functional test12:36
mgedminit will always happen otherwise, unless you register widgets yourself12:36
mgedminlook for provideAdapter calls at the top of form.txt, I guess12:36
mgedminhere's what I do in unit tests, if I want to make sure I can render a page template that contains a form12:36
mgedminztapi.browserView(Interface, 'form_macros', FormMacros)12:37
mgedminztapi.browserView(Interface, 'widget_macros',12:37
mgedmin                          SimpleViewClass('',12:37
mgedmin                              os.path.dirname(
mgedminztapi.browserViewProviding(ITextLine, TextWidget, IInputWidget)12:37
mgedminztapi.browserViewProviding(IInt, IntWidget, IInputWidget)12:37
mgedminztapi.browserView(IWidgetInputError, '', WidgetInputErrorView,12:37
mgedmin                          providing=IWidgetInputErrorView)12:37
mgedmin# the actual set of widgets that I register depend on which ones are used in my test/page template12:38
mgedmin# when I get an error, I grep for a corresponding zcml directive in, and then convert it to Python code12:39
bob2oh, wow12:39
mgedminI am not entirely convinced rendering page templates in unit tests is a good idea12:39
bob2I'm trying to get a feel for formlib, more than anything12:40
bob2before I strap it into the system12:40
mgedminit helps when your PT contains logic that you want to unit-test, and that would be hard to test in a functional test12:40
mgedminbob2, in that case it might be simpler to play with zopectl debug -- it will load the zcml for you, I think12:40
mgedminor just load the site.zcml file yoursel at the top of your python script12:40
bob2is this similar to using Debugger?12:41
mgedminmaybe -- I haven't used either much12:41
*** sashav has quit IRC12:53
*** bob2 has quit IRC12:53
*** Hellfried has quit IRC12:53
*** sashav has joined #zope3-dev12:53
*** bob2 has joined #zope3-dev12:53
*** Hellfried has joined #zope3-dev12:53
bob2hm, where does FormMacros come from?12:58
mgedminuse the tags, luke13:01
*** ignas has joined #zope3-dev13:09
*** stub has quit IRC13:20
*** stub has joined #zope3-dev13:21
*** BjornT has joined #zope3-dev13:31
bob2now I'm down to:13:37
bob2zope.component.interfaces.ComponentLookupError: ((<zope.schema._bootstrapfields.Int object at 0xb7371bac>, <zope.publisher.browser.TestRequest instance URL=>), <InterfaceClass>, u'')13:37
mgedminso you didn't use the quick suggestion of loading the real zcml file?13:40
* mgedmin shrugs13:40
mgedminztapi.browserView(IInt, IntDisplayWidgetOrSomething, IDisplayWidget)13:40
mgedminyou'll have to figure out the name of the Int display widget class yourself13:40
bob2oh, I wasn't sure how to load the real zcml file13:41
mgedminisn't that like xmlconfig('filename')?13:41
mgedminI'd look for a .zcml file somewhere in a tests/ subdir, then grep for it in test_*.py13:41
*** vlado has joined #zope3-dev13:54
mgedminbob2, one way to do it:13:55
mgedminfrom zope.configuration.xmlconfig import XMLConfig13:55
mgedminI guess you want13:56
mgedminimport zope.app13:56
*** ignas has quit IRC13:57
bob2hm, thanks a lot (again)14:08
bob2if you're ever in .au, remind me to buy you a beer :)14:08
* mgedmin doesn't drink beer, but would accept a cup of tea ;)14:09
*** alga has joined #zope3-dev14:14
*** stub has quit IRC14:16
*** mgedmin has quit IRC14:17
*** efge has joined #zope3-dev14:17
*** ignas has joined #zope3-dev14:20
*** anguenot has joined #zope3-dev14:26
*** projekt01 has quit IRC14:26
*** projekt01 has joined #zope3-dev14:27
*** regebro has joined #zope3-dev14:44
*** regebro has quit IRC14:52
*** roym has joined #zope3-dev14:59
roymsorry to be asking the same thing over and over again - but how would I get the roles for a given principal?15:00
srichterlook at the permission maps of all objects in your object path15:01
*** faassen has joined #zope3-dev15:01
projekt01roym, grep for the method getRolesForPrincipal and use principal_id not principal as the argument for the principal15:02
*** vlado has quit IRC15:06
*** tiredbones has joined #zope3-dev15:27
*** MrTopf has joined #zope3-dev15:30
*** GaryPoster has joined #zope3-dev15:37
bob2when using formlib, __call__ on an instance of the class produces the output15:38
bob2how do I call that using TAL?15:38
*** regebro has joined #zope3-dev15:39
roymprojekt01: thanks for answering...15:39
bob2(normally I'd call a method on the instance)15:40
projekt01bob2, tal:define="myCalledView python:view()" if the view is already a instance15:42
bob2I don't think I can make an instance statically15:45
bob2since __init__ takes request and context15:46
SteveAhave you tried tal:replace="structure yourinstance" ?15:47
SteveAif that does not work, yourinstance/__call__ is ugly but ought to work15:47
* SteveA wonders about using a trailing / to indicate calling vs not calling behaviour in TALES15:48
*** benji_york has joined #zope3-dev15:48
bob2I can't quite see where yourinstance would be instantiated, tho15:49
projekt01Hm, I'm not sure if I got you right, if you call a view from a ZPT like: myObjectOrContext/@@myView you get the adapted view instance where you should able to call.15:49
*** Alef has joined #zope3-dev15:50
projekt01bob2, tal:define="yourinstance context/@@MyView"15:50
projekt01See also the breadcrumb concept e.g. context/@@absolute_url/breadcrumbs15:51
*** alga has quit IRC15:56
*** d2m has quit IRC15:57
*** J1m has joined #zope3-dev16:03
bob2this is rapidble spiraling out of comprehension16:36
GaryPosterbob2: you are using formlib.  What's the problem exactly?16:36
*** stub has joined #zope3-dev16:36
bob2GaryPoster: I'm not sure of the correct TAL and ZCML code to make use of a form.Form derivative, it seems16:37
GaryPosterOK.  The zcml is most simply a browser:page directive.  It does some extra muck that you don't want, but it takes care of the security quickly and easily.16:38
bob2right, I have that16:39
GaryPosterOtherwise you can use a standard adapter element and configure the security as you need.16:39
GaryPosterSo what is the TAL problem?16:39
bob2(I'm just using the same sort of :page declaration I did with a BrowserView subclass)16:39
GaryPosterSure, should be fine16:39
bob2ComponentLookupError: (< object at 0xb3f79a8c>, <InterfaceClass zope.formlib.namedtemplate.INamedTemplate>, 'default')16:41
GaryPosterSo that means that you have not registered a NamedTemplate for the TestForm class or its interface.  If you are subclassing form.Form, that makes sense: the default templates are for the derivatives (edit and so on)16:43
bob2because I didn't setup the template correctly, I guess16:43
bob2perhaps a stupid question, but what's a NamedTemplate?16:43
GaryPoster:-) Not stupid.16:43
GaryPosterIt's also in formlib.  You can either ignore it, and slam a template attribute on your class that's an actual page template, or16:44
GaryPosterread about them in the namedtemplate.txt file in formlib16:45
bob2ah, thank you :)16:47
GaryPosternp :-)16:47
bob2right now my :page declaration points at a template, which then has TAL which calls the form.Form object16:47
bob2NamedTemplate lets you invert that and have the formlib object insert itself into a template?16:47
GaryPosterAh.  No, the page declaration should point to the formlib object as the class.  Don't specify a template.16:48
GaryPosterAlthough I wouldn't put it that way... :-)16:48
GaryPosterBut that's beside the point so I'm not going to get into it (if that's ok)16:49
bob2heh, np :)16:51
bob2  <page16:55
bob2    for=""16:55
bob2    name="test.html"16:55
bob2    permission="zope.View"16:55
bob2    class=""16:55
bob2  />16:56
bob2look reasonable if is a subclass of form.Form?16:56
*** vlado has joined #zope3-dev17:00
srichterJ1m: I just found a serious bug in our WSGI support17:02
srichterJ1m: can I pick your brain a bit?17:02
srichterin the WSGI support we get the response from the request before we publish it17:03
srichterwe do this because request.close() sets the response on the request to None17:04
srichterhowever, when a request is retried a completely new instance of the request is created in Request.retry()17:05
srichterthis means that the response we originally saved is not the one that is used after the retry17:06
srichterhere are a couple solutions:17:06
srichter* retry does not create a new instance, but simply cleans itself carefully17:07
srichter* publish returns the response object17:07
srichterI think the latter fits better our new model17:08
srichterbenji_york: GaryPoster: is Jim around?17:08
GaryPostersrichter: in meeting17:08
benji_yorkhe's in a meeting right now17:08
*** hdima has quit IRC17:09
GaryPosterbob2: yes, looks ok17:09
bob2GaryPoster: thanks a lot17:09
srichterGaryPoster: any idea when that will be over?17:09
GaryPostersrichter: none, sorry17:10
*** projekt01 has quit IRC17:10
*** sashav has quit IRC17:16
*** yota has quit IRC17:22
*** tiredbones has quit IRC17:22
*** __gotcha has quit IRC17:22
*** genconc has quit IRC17:22
*** SteveA has quit IRC17:22
*** vlado has quit IRC17:22
*** J1m has quit IRC17:22
*** MrTopf has quit IRC17:22
*** ignas has quit IRC17:22
*** lucia12345 has quit IRC17:22
*** VladDrac has quit IRC17:22
*** tav has quit IRC17:22
*** Jim7J1AJH has quit IRC17:22
*** Alef has quit IRC17:22
*** GaryPoster has quit IRC17:22
*** faassen has quit IRC17:22
*** anguenot has quit IRC17:22
*** MJ has quit IRC17:22
*** dman13 has quit IRC17:22
*** srichter has quit IRC17:22
*** tvon has quit IRC17:22
*** deo has quit IRC17:22
*** andrew_m has quit IRC17:22
*** jack-e has quit IRC17:22
*** FarcePest has quit IRC17:22
*** regebro has quit IRC17:23
*** roym has quit IRC17:23
*** efge has quit IRC17:23
*** BjornT has quit IRC17:23
*** Hellfried has quit IRC17:23
*** bob2 has quit IRC17:23
*** benji_york has quit IRC17:23
*** peaceman has quit IRC17:23
*** bradb has quit IRC17:23
*** j-w has quit IRC17:23
*** jhauser has quit IRC17:23
*** vinsci has quit IRC17:23
*** philiKON has quit IRC17:23
*** Theuni has quit IRC17:23
*** Aiste has quit IRC17:23
*** regebro has joined #zope3-dev17:26
*** roym has joined #zope3-dev17:26
*** efge has joined #zope3-dev17:26
*** BjornT has joined #zope3-dev17:26
*** bob2 has joined #zope3-dev17:26
*** Hellfried has joined #zope3-dev17:26
*** srichter has joined #zope3-dev17:27
*** genconc has joined #zope3-dev17:27
*** __gotcha has joined #zope3-dev17:27
*** segoave has joined #zope3-dev17:27
*** SteveA has joined #zope3-dev17:27
*** andrew_m has joined #zope3-dev17:27
*** FarcePest has joined #zope3-dev17:27
*** jack-e has joined #zope3-dev17:27
*** deo has joined #zope3-dev17:27
*** tvon has joined #zope3-dev17:27
*** dman13 has joined #zope3-dev17:27
*** MJ has joined #zope3-dev17:27
*** anguenot has joined #zope3-dev17:27
*** faassen has joined #zope3-dev17:27
*** GaryPoster has joined #zope3-dev17:27
*** Alef has joined #zope3-dev17:27
*** yota has joined #zope3-dev17:27
*** Jim7J1AJH has joined #zope3-dev17:27
*** lucia12345 has joined #zope3-dev17:27
*** VladDrac has joined #zope3-dev17:27
*** ignas has joined #zope3-dev17:27
*** MrTopf has joined #zope3-dev17:27
*** J1m has joined #zope3-dev17:27
*** vlado has joined #zope3-dev17:27
*** fdrake has joined #zope3-dev17:27
*** tav has joined #zope3-dev17:27
*** sets mode: +oo srichter tav17:27
*** peaceman has joined #zope3-dev17:27
*** jhauser has joined #zope3-dev17:27
*** bradb has joined #zope3-dev17:27
*** vinsci has joined #zope3-dev17:27
*** philiKON has joined #zope3-dev17:27
*** Aiste has joined #zope3-dev17:27
*** tiredbones has joined #zope3-dev17:27
*** Theuni has joined #zope3-dev17:27
*** Jim7J1AJH has quit IRC17:28
*** yota has quit IRC17:28
*** yota has joined #zope3-dev17:30
*** benji_york has joined #zope3-dev17:31
*** j-w has joined #zope3-dev17:31
ignasa question - if i have two <a> tags in py template that have only one difference one of tham has no "href" attribute in it's tal:attributes17:34
*** peaceman has joined #zope3-dev17:34
ignasis ther a way to do it without <tal:if contition="foo"><a attrs="href foo; class some_class"></tal:if><tal:if contition="not:foo"><a attrs="class some_class"></tal:if>17:35
bob2shouldn't you be provindg the attribute, empty?17:35
ignaslike <a tal:attrbutes="href: empty; class some_class"> ?17:36
fdrakeonly provide <a href="..."> if you want it to be a link source17:36
ignasfdrake, ?17:37
fdrakelink source == clickable to follow the link17:37
fdrakeso you need the conditional17:37
fdrakebut lemme check something17:38
fdrakeugh; can't get to (www|dev).zope.org17:39
*** BjornT has quit IRC17:40
*** tvon has quit IRC17:41
fdrakeah; you should be able to use tal:attributes="href nothing"17:41
fdrakeif you're using a Python expression, you can use None for nothing17:42
*** Jim7J1AJH has joined #zope3-dev17:43
ignasoh, i see17:43
J1msrichter, pong17:43
srichterJ1m: did you get my explanation above?17:44
J1mI agree that we need to refactor this a bit.17:44
J1mThis is related to our discussions about "application boundary".17:44
J1mI think we need to revisit what request.close does.17:45
srichteractually I miswrote17:45
srichterits not even a request.close() issue17:45
J1mI see no reason why it has to lose the response.17:45
*** BjornT has joined #zope3-dev17:45
srichterthe issue is really that the publish() function can create new requests17:45
J1mlemme look ...17:46
srichterwhen a retry occurs a new request is created17:46
J1mok17:46 line 15717:46
J1mI agree that, in the new world, publish should return the request with the response intact.17:47
J1mwrt reset, it *is* being used, not *not* for retry.17:47
J1mIt is used for error handling.17:47
srichteryeah, I saw this after I wrote the message17:48
J1mwrt reset, it *is* being used, but *not* for retry.17:48
srichteron the other hand, it seems strange to me that the publisher can create a new request17:49
srichterespecially since you pass one in17:49
J1mI also think we need to think a bit more about the response API.17:49
*** Jim7J1AJH has quit IRC17:50
J1mwell, the publisher is creating a new logical request.17:50
J1mI could live with a strategy of reusing the request.17:50
srichteryes, but we pass a logical request to the publisher17:50
J1mYes, and it creates a new one.17:50
J1mI'm OK with either approach.17:50
srichterright, I think people would not expect this17:50
srichtermmh, I wish you would have a stronger opinion :-)17:51
J1msorry :)17:51
srichterchanging retry to using reset might be the quickest solution, but might cause unwanted side effects17:52
J1mwrt the response, I'm not too happy that client (esp test code) gets response.result.body.17:52
srichterright, I agree that this seems unclean17:52
J1mI'm inclined to suggest that the response should be private, but I'm not really sure.17:52
srichterwow, that would be a big change17:53
J1msrichter, again I don't have a strong aopinion about retry vs reset.17:53
J1mI'm not sure it would be a big change.17:53
J1mI'm also not sure it would be a desireable change. :)17:53
srichterbecause a lot of code uses response.*Header* and response.redirect()17:53
srichterI personally don't mind response to be public17:54
J1mNot response, response.result.17:54
J1mresponse should be public.17:54
faassenphew. :)17:54
* faassen was about to rip all response.redirect() from his codebase. :)17:54
srichterok, you had a typo above then17:54
J1mI was suggesting that the result (response.result) might not be public.17:54
srichterI think this might be a good idea17:55
J1moh, sorry17:55
*** Jim7J1AJH has joined #zope3-dev17:55
srichterso we would need to expose the body access in the response somehow17:55
srichterand then this would be for the HTTP requests too17:56
J1msomething like:17:56
J1mthe later gets a string17:56
J1mNote that "bodies" are HTTP specific.17:56
srichterwill the latter return the headers as well?17:56
srichtergood point17:57
J1mThis gets back to the discussion we had yesterday.17:57
srichterwhich aspect?17:57
J1mIt might be much cleaner if the publisher was only about HTTP.17:57
srichterthat we should rip out the FTP support?17:57
J1mOr provide the FTP support with a more FTP-oriented publisher.17:57
srichterright, that's what I meant17:58
J1mCGI isn't a good model for FTP. :)17:58
J1mBut, of course, traversal, paths, etc. are relevent to both.17:58
J1mI would expect many concepts and possibly frameworks (e.g. publication) to be shared.17:59
srichteryes, so I wonder whether the concept of publications could be reused17:59
J1manyway, I wouldn't suggest doing this for 3.2.17:59
J1mWe are running out of time.17:59
srichteryep, right now I just want to get all tests fixed on the branch18:00
J1mI'd like to get what we started at the sprint, along, of course, with the twisted work, wrapped up in time for 3.2.18:00
srichterso that we can implement the BB correctly and switch to the new code18:00
srichterI think it will be about a day of work once all tests are passing18:01
srichter(there are only two left, both of which will be fixed by fixing the discussed issue)18:01
srichterok, here is the simplest solution:18:01
J1mI also think that someone will want to leverage this and ZODB blobs to make the large file story better.18:01
srichterhave publish() return request, response18:02
srichterthis will be least intrusive18:02
SteveAi was having a discussion with marius over lunch, about some issues with the default Zope security policy.  it expects __parent__ attributes, but does not demand that the objects provide an interface that says "IHaveAParentAttribute".  We discussed why an interface is not demanded.  The answer seems to be that this would be too much of an imposition on application developers, to make almost every object provide this interface.  Unfortunately, this leaves18:02
SteveA an implicit dependency on __parent__.18:02
J1mhave it return request.18:02
J1mhave request retain the response attr.18:02
*** Alef has quit IRC18:02
srichterJ1m: ok18:03
*** ignas has quit IRC18:03
SteveA(implicit dependencies on attributes are *so* zope2)18:03
J1mSteveA, we don't check the interface for performance reasons.18:03
J1mIt's a tradeoff.18:03
SteveAnot even when in debug mode.  not even when running tests.18:03
* srichter always dreamed of making a change in the publish() function; seems very important! :-)18:03
J1mThe vast majority of objects that have __parent__ provide ILocation.18:04
J1mSteveA, I'm +1 on adding an interface check in devel/debug mode.18:04
J1mThen, of course, we need to be prepared to run tests *both* in debug and non-debug mode, at least on the buildbot.18:05
J1mBTW, I wonder if we bother to pass -O to python when running in production mode.18:05
SteveAmake the code that runs in debug mode try both checking the interface and looking for the attribute.18:05
SteveAif the results differ, that's an error18:05
J1mProbably not, since we don't really have explicit devel and production modes.18:06
SteveAiow, it is an error to provide __parent__ without providing ILocation18:06
srichterJ1m: see my devmode proposal18:06
SteveAthat statement makes me queasy18:06
J1msrichter, k18:06
SteveAan interface should not put requirements on things that don't provide it18:06
J1mSteveA, I'm not so sure about that.18:06
SteveAseems to me to be a consequence of the optimisation of not checking the interface18:07
J1mBut an object should be free to have an attribute that it doesn't promise to provide.18:07
SteveAyes, of course18:07
* SteveA needs to get back to debuging some authentication / virtual host issues18:08
J1mBTW, we will be releasing a security policy that makes much less use of __parent__.18:09
J1mThis policy is much simpler than the default Z3 policy.18:09
J1mIt also provides an example of what's rquired to write an alternative policy.18:10
SteveAhurrah.  i use one that makes no use of __parent__, btw.  but then, my objects aren't arranged in a hierarchy like in many zodb applications.18:10
SteveAi'm pretty sure i can release mine at some point soon.18:11
srichterJ1m: all tests are passing now18:26
*** MrTopf has quit IRC18:34
*** alga has joined #zope3-dev18:39
*** tvon has joined #zope3-dev18:40
*** vlado has quit IRC18:44
srichterJ1m: btw, we also need to write the mail to the WSGI group18:49
srichterwe need an answer (at least preliminary) for Zope 3.218:49
*** mgedmin has joined #zope3-dev18:50
srichterJ1m: do you want me to implement body and iterbody for HTTP requests?19:04
*** vlado has joined #zope3-dev19:13
*** ignas has joined #zope3-dev19:14
*** j-w has quit IRC19:25
J1msrichter, I assume that the email you are refering to is wrt auth user19:29
srichterJ1m: because currently the zserver does not log the auth user, which it did before19:30
J1mYup, I think we should send that email.19:31
J1mwrt body and iterBody, I think that would be good, if you agree,19:32
srichteryeah, I think this sounds fine, though only one can be called once19:32
srichteralso, should body return the headers as well? I guess not19:32
J1mReally, they both can be called only once.19:32
GaryPostersrichter: I have an APIdoc bug I'd like to chat with you about.  Do you want me to chat with you at the same time as Jim, or can you ping me when you are available?  Ideally we'd chat within the next half hour, but if that's not possible that's ok19:34
srichterwrt the auth user, should be make a specific suggestion, like: We need an additional wsgi env variable called XXX19:34
srichteror do we just want to raise the issue19:34
J1mI think we should make a specific proposal.19:34
srichterGaryPoster: contact me privately19:35
GaryPosterOK will do19:35
srichterJ1m: do you think that it will suffice to add a new env var called "wsgi.authuser" or should we address logging more generally19:35
srichteri.e. env['wsgi.loginfo'] = {}19:36
srichterand then define the keys that can be in this dictionary19:36
*** Aiste has quit IRC19:37
J1mI *think* that authuser is the only field the app is responsible for.19:42
J1mI would stay specific.19:42
J1mMaybe "wsgi.commonlog.authuser", but whatever you think is best.19:42
srichterok, sounds good19:51
srichteradding the commonlog namespace makes sense19:51
*** BjornT_ has joined #zope3-dev19:54
*** BjornT_ has quit IRC19:56
*** yota has quit IRC20:11
*** BjornT has quit IRC20:11
*** bradb has quit IRC20:11
*** fdrake has quit IRC20:11
*** J1m has quit IRC20:11
*** lucia12345 has quit IRC20:11
*** genconc has quit IRC20:11
*** VladDrac has quit IRC20:11
*** __gotcha has quit IRC20:11
*** tav has quit IRC20:11
*** vlado has quit IRC20:11
*** mgedmin has quit IRC20:11
*** tvon has quit IRC20:11
*** alga has quit IRC20:11
*** Theuni has quit IRC20:11
*** segoave has quit IRC20:11
*** GaryPoster has quit IRC20:11
*** andrew_m has quit IRC20:11
*** dman13 has quit IRC20:11
*** faassen has quit IRC20:11
*** MJ has quit IRC20:11
*** anguenot has quit IRC20:11
*** FarcePest has quit IRC20:11
*** srichter has quit IRC20:11
*** jack-e has quit IRC20:11
*** SteveA has quit IRC20:11
*** deo has quit IRC20:11
*** genconc has joined #zope3-dev20:11
*** alga has joined #zope3-dev20:11
*** mgedmin has joined #zope3-dev20:11
*** VladDrac has joined #zope3-dev20:11
*** BjornT has joined #zope3-dev20:11
*** vlado has joined #zope3-dev20:11
*** segoave has joined #zope3-dev20:11
*** andrew_m has joined #zope3-dev20:11
*** faassen has joined #zope3-dev20:11
*** tav has joined #zope3-dev20:11
*** anguenot has joined #zope3-dev20:11
*** bradb has joined #zope3-dev20:12
*** srichter has joined #zope3-dev20:12
*** fdrake has joined #zope3-dev20:12
*** J1m has joined #zope3-dev20:12
*** Theuni has joined #zope3-dev20:12
*** MJ has joined #zope3-dev20:12
*** __gotcha__ has joined #zope3-dev20:12
*** lucia12345 has joined #zope3-dev20:12
*** ChanServ sets mode: +o srichter20:12
*** __gotcha__ is now known as __gotcha20:12
*** GaryPoster has joined #zope3-dev20:12
*** FarcePest has joined #zope3-dev20:12
*** SteveA has joined #zope3-dev20:12
*** tvon has joined #zope3-dev20:12
*** Aiste has joined #zope3-dev20:13
*** yota has joined #zope3-dev20:17
srichterJ1m: do you want body and iterbody to be attributes of functions? (I am for the former)20:31
J1mI am for the later.20:37
J1mPerhaps: getBody and iterBody.20:37
J1mThey are unlike attributes because you can call them only once.20:37
srichterok, good point20:38
faassenif you can call them only once, you might want to use 'useBody'?20:43
faassenif I understand it correctly.20:43
srichterit is more a retrieval20:44
srichterI guess that name would work too20:44
faassenuse sort of implies it's used up. :)20:44
faassenI've been using it in a few places.20:44
srichtersomeone can change this later20:45
srichterI really want to get done wioth the branch20:45
J1m+1 on use.20:45
J1mThis is an important semantic.20:45
J1m(or consumeBody)20:46
J1m(consumeBodyIter :)20:46
SteveAhow deliciously zombie20:46
srichterJ1m: btw, how can a BaseResponse get to its result once result is private?20:46
J1mNight of the living read?20:46
faassenconsume is also nice. :)20:47
benji_yorkconsumeBrains.... consumeBrains.....20:47
*** xenru has joined #zope3-dev20:47
srichterwe have tests that get the result from a BaseResponse isntance20:47
J1msrichter, it could be protected (single _)20:47
srichterok, so I just use response._result in the tests?20:48
J1msrichter, you can keep "result" in the implementation and not include it in the interface -- if you don't want to change the tests.20:48
faassensee you all.20:50
*** faassen has quit IRC20:50
srichterJ1m: I am already changing the tests ;-)20:50
*** bob2 has quit IRC20:51
*** bob2 has joined #zope3-dev20:51
*** efge has quit IRC20:53
*** projekt01 has joined #zope3-dev21:01
*** projekt01 has joined #zope3-dev21:01
srichterJ1m: so what name do we want to use?21:01
srichterconsumeBosy and consumeBodyIter?21:02
J1mMartijn should pick. ;)21:02
J1m\These sound fine (with obvioud corrections :) to me.21:02
*** philiKON has quit IRC21:06
*** douglasc has joined #zope3-dev21:09
projekt01GaryPoster and benji_york, are you there?21:20
projekt01Did you take a look at the pagelets?21:21
projekt01Doesn't this fit the requirements for additional CSS/JS rendering21:22
GaryPosterNo. :-(  Jim mentioned we needed to look at that today.  Does the resourcelibrary stuff overlap?21:22
srichterI think the pagelet code needs a simpler example21:23
srichterlike a simplest possible case21:23
projekt01It's exactly what you describe in the mail21:23
*** anguenot has quit IRC21:23
projekt01Yup, a simple example whould help,21:23
projekt01Just a small abstratct...21:24
projekt01... it isn't that easy to describe shortly.21:26
projekt01What kind of sample would be useful?21:26
GaryPosterDarn.  OK, we'll look at that ASAP.  We thought it was more like little pages, rather than being useful for JS and CSS.21:26
srichterExample is easy21:27
srichterI have some code that wants to insert a CSS file above, when used21:27
srichterexactely the widget use case21:27
GaryPosterOK, good. :-)  Hard to ask for an example for something you don't know. :-)21:27
projekt01Yes, something like little pages where can be registred on "context-, view- and slot - interfaces".21:27
srichterJ1m: I am done with the branch; it is ready to be merged21:28
GaryPosterHe's away from the computer21:28
projekt01btw, the skin makes havy use of fill javascript and CSS slots with pagelets.21:28
GaryPoster(I'm his IM bot, apparently ;-) )21:28
GaryPosterI'm looking at the pagelet readme21:30
*** vlado has quit IRC21:30
projekt01GaryPoster, pagelets are also like dynamic fill-slot component, where the slot is the key for get dynamicly the registred pagelet (little views)21:30
*** vlado has joined #zope3-dev21:31
projekt01a pagelet get rendered together with the page template at once and not before you include them.21:32
GaryPosterI wonder if it could use something like the resourcelibrary as a client--the pagelet stuff starts out with a model that I guess you have to follow.  The resourcelibrary doesn't require much of a model--it's just a simple API.  Talking with Jim...21:33
projekt01if you use a python class for register a pagelet (like in the page directive), you have the scope of context and view in this pagelet class21:33
srichterGaryPoster: I am not particularly in favor of resource library21:33
srichterin my books it is a hack :-)21:34
srichterif you want piping you should do it the right way using XSLT21:34
projekt01You only need to define a interface for the pagelet slot and call this in the page templage like
projekt01then you can register <pagelet slot="" ...> there is nothing more needed.21:35
projekt01but the same concept can be used for allmost everything else.21:36
projekt01I like this, that pagelets can solve so many problems with just one concept.21:36
srichterGaryPoster: btw, you probably want to look at
projekt01GaryPoster, I'm not really sure if I get the use case of register JS libraries right. Are you mean the include of <script langauge="javascript" src="..." />21:38
projekt01or register nested folders of large javascript libraries as resources?21:38
GaryPostersrichter, projekt01: back.21:38
J1msrichter, wrt the branch: Yay!21:39
srichterJ1m: are we ready to merge?21:39
srichteror do we need to do more?21:39
*** sashav has joined #zope3-dev21:39
J1msrichter, I'd like to chat with you using a higher-bandwidth medium. :)21:40
* J1m wonders if dialog is working in srichter's irc client.21:41
srichterneed my phone number?21:41
GaryPostersrichter, yes, already acknowledged that current implementation is not ideal; the idea is to expose the API, which means we can have other implementations.  XSLT Is fine, but not required to do what we need.  In the absence of an XSLT processor, we did something simple and effective.  Jim is talking about a pipeline between the request and the response: that sounds like it would work great for what we want.21:41
J1mYes, feel free to dialog me if you don't want to share it with the world.21:41
*** MJ has quit IRC21:43
GaryPosterprojekt01: yes, I need to look up some examples.  What you describe sounds a lot simpler than the start of the pagelet README looks. :-)  It also really doesn't look like what we are doing.  We are not including parts of a page, we are including javascript libraries: pdlib, prototype, etc.  The resourcelibrary does both of what you list.21:46
projekt01GaryPoster, do I get it right, that you don't have to declare something in the ZPT, this happens hidden and appends the right tags in the page header?21:48
* mgedmin wonders if there's a zodb tool for opening a read-only Data.fs, and copying the most recent records of all objects into a new Data.fs -- IOW nondestructive packing of a live data.fs21:49
projekt01Ok, then I like your concept and think that' much better then using pagelets for this.21:50
projekt01GaryPoster, can we enhance and use this concept for inject other parts as javascript and CSS tags?21:51
srichtermgedmin: copy, pack?21:53
benji_yorkprojekt01, what do you have in mind?21:54
srichterbenji_york: projekt01: oh, we are going down this slippery road of inventing our own pipelining technology21:54
GaryPosterprojekt01: Cool!  But I've already been assigned the task of grokking pagelets, I think, so I'll get into them more. :-)21:55
*** Alef has joined #zope3-dev21:55
projekt01benji_york, nothing special, just see find out the limit of inject something without to define it in ZPT.21:56
srichterJ1m: task.write is non-blocking21:56
srichterthough it puts everything in an output buffer, so probably it takes up the memory21:57
srichterJ1m: actually, I think it does the right thing21:58
srichterit uses zope.server.buffers.OverflowableBuffer, which seems to create a temp file, when output is large21:59
GaryPosterWe can inject anything in theory; but I agree with Stephan (at least in part) that what we are doing here is a hack, waiting for a real pipeline hook.  I don't agree that a real pipeline hook (or two, since Jim is talking about both WSGI pipeline and a pipeline between request and response) must be XSLT to not be a hack.  I want the hook we've forced in with resourcelibrary to be as constrained in scope as possible.22:01
*** vlado_ has joined #zope3-dev22:02
benji_yorkprojekt01, also you don't *have* to trigger the insertion via ZPT, you can also programmatically trigger the inclusion22:04
projekt01benji_york, that's cool, but in general I'm not this happy with pipelines. I can't imagine that graphic people can handle this part and I don't like to do their job in the future too.22:06
projekt01but perhaps it's easier then I can think about right now ;-)22:07
benji_yorkprojekt01, I'm afraid I don't understand, but no matter :)22:07
*** Alef has quit IRC22:08
projekt01benji_york, I like to outsource the ZPT work to graphic peoples in the future and I have some fear that this would be not understandable with XSLT pipelines.22:09
J1mmgedmin, you can do that now using a symbolic link.22:10
J1mMake a symbolic link, open it read only and pack it.22:10
J1m(Test this to be sure, but I'm 94% sure this works.)22:11
J1mwrt pipelines:22:11
J1m- I agree that they don't have to be xslt. For example, the xslt-based Cocoon uses lots of non-xslt pipeline segments.22:12
J1m- I think that pipelines are not the only model that can be used here. If transformations are independent, they could be performed by subscribers, rather than in a pipeline.22:13
projekt01btw, I like the idea to have a kind of pipeline for the javascript and CCS injection part in the header area of a page.22:13
J1mOf course, a pipeline could be used even where ordering isn't necessary.22:13
J1mBut, I suspect that avoiding oprdering when it's not necessary will make things more pluggable.22:14
projekt01J1m, javascript tags must follow a ordered if you write it object oriented and split they in libraries.22:14
GaryPosterBut if there is a single subscriber for the resourcelibrary, it can handle the ordering.22:15
projekt01what does it mean a single subscriber?22:16
J1mThe idea is that the resource library accumulates needed JS and CSS dirubf the request.22:17
J1mAt the end, it then inserts this accumulated material into the page.22:17
J1mThis last step can be done by a single subscriber.22:18
srichterwill the hook be sensible to content types?22:19
*** MJ has joined #zope3-dev22:19
srichteri.e. we do not want to inspect an image22:19
projekt01Does this mean we can register such JS/CSS combination as libraries. But the javascript files can be located in different packages?22:20
* J1m really needs to read the cocoon book again22:20
*** vlado has quit IRC22:20
J1mI'm most interested in using pipelines for post-processing results of calling published objects.22:22
projekt01J1m, can you describe a use case?22:22
J1mOf course, pipelines can be puplished directly (e.g. used to implement views).22:22
J1mSure. I can describe a couple (probably several if I put my mind to it. :)22:23
J1m1. Add needed JS and CSS resources to a page after it is rendered.22:23
J1m2. Add a standard look and feel. (aka "o wrap") to a page.22:24
*** segoave has left #zope3-dev22:24
J1mI don't think page macros have worked very well for controlling look and feel.22:25
J1mI'd like to remove the responsibility from a view designer for producing standard look and feel.22:25
projekt01I agree, the (1.) should be implemented for 3.2. It's a feature we really need. Other things are nice to have in the future.22:27
*** douglasc has quit IRC22:30
projekt01J1m, Yes, views contains to much layout relevant tags right now. btw, I really like to cleanup and replace some tags in views which makes it hard to apply different layouts.22:30
* J1m GaryPoster and benji_york discuss pipelines ... :)22:41
projekt01J1m, btw, is there a relevant roadmap for zope3?22:42
*** alga has quit IRC22:43
*** mgedmin has quit IRC22:47
jhauseras a supplement to pipelines was there ever a discussion about an application context for views?23:02
jhauserI mean an application which controls the o-wrap23:03
*** dman13 has joined #zope3-dev23:03
srichterJ1m: merge complete23:04
J1mprojekt01, no roadmap for z3.23:07
J1mIMO, roadmaps are less important when: 1. we have time-based releases, and 2. we have little control over what people will work on.23:07
*** jinty has joined #zope3-dev23:07
J1mStill, some sort of planning document would be nice, where people could at least note what they want or are working on.23:08
J1mjhauser, I don't know what you mean.23:08
srichterJ1m: would you prefer that I merge the twisted stuff in as soon as it works, but before we finish all other deisred tasks?23:09
J1mThe new rule is: don't merge unless you think it's releasable.23:09
jhauserI mean that the descisions, what would appear on a page beside the main content is controlled by an application23:09
J1mjhauser, which application?23:09
srichterJ1m: it will be releasable but not contain all goodies we are planning23:10
fdrakesrichter: GMail truncated your merge message ;-)23:10
J1msrichter, then yes.23:10
srichterJ1m: ok, I try to get this done in the next weeks then23:10
jhausergenerally it would mainly be a place were different components can register themself23:10
jhauserthe view of the content would register itself for the main part of the application23:11
jhauserperhaps I understand pipelines not enough, but they mainly transform, what's already there23:12
jhauserfor example a portalpage has many bits which have a high overall application logic23:13
jhauser"show the loginbox if not logged in, else show the userinfo, taken from somewhere"23:13
jhauserto do this in a pipeline, the parts of the pipeline need to go back to something to ask, should I show the login box"23:14
jhauserthey need to reach back so to speak23:15
*** xenru has quit IRC23:16
J1mjhauser, right.23:16
J1mThe idea is to do composition at the presentation layer in some sort of loose way.23:17
J1mI'm not sure I understand pipelines well either.23:17
J1mIn any case, I think it would be fairly non-controversial to use a pipeline (or pipeline-like thing) to post process something returned by calling objects.23:18
J1mBut pipeline advocates would also advocate pipelines for implementing the orginal view.23:18
jhauserright, my understanding up to now is that the get all the information they need and are fairly self sustained23:19
J1mA very simple case that I think has merit is to separate information production from page production.23:19
J1mThis is the ClearSilver approach that I think could be done as well with ZPT.23:20
jhauserok, that I understand23:20
jhauserbut that leaves the logic in the information production step23:20
jhausermainly to decide what information is displayed23:21
jhauserand this is also part of the o-wrap23:21
J1mOf course, the XML/XSLT zealots would implement *that* as a pipeline too. :)23:21
J1mwell, yes and no, depending on what you consider the o-wrap to be.23:22
J1mIn Cocoon, the o-wrap is implemented as an XSLT template that effectively invokes pipelines (if I remember correctly).23:23
jhauserthese pipelines are data centric23:23
jhauserthey mangle data packed in xml23:24
J1mtoo bad Paul and Martijn aren't here23:24
jhauserthis does not solve the question where should responsibilities be placed23:24
projekt01jhauser, pagelets are a concept where you can assemble such selective "little views" to one page. But the each page template has to define define its slots explicit.23:24
jhauserand this is undestood as a hinderence to easy customization, right?23:26
jhauserlayout customization I mean23:26
projekt01jhauser, I don't understand what do you mean with layout?23:29
jhauserif the slots need to be defined in a pagetemplate is becomes more complicated, and as such it becomes harder to simply change the layout.23:30
jhauserharder for a non programmer23:31
projekt01Pagelets are used for add additional content to a existing pagelets dependent on registration via ZCML (this means you can render content where is not defined in the ZPT explicit)23:32
jhauserI'm not against or for something, I only want to see clearer what get's solved with the various proposed approaches23:32
jhauserso the ZPT defines places where parts can be placed with ZCML23:33
projekt01jhauser, Pagelets can not solve layout problems ;-(23:33
projekt01Yes, exactly23:34
jhauserare you using them in tiks?23:34
projekt01I use most the time a layout pagelet which is called as a pagelet from the data pagelet.23:35
projekt01Yes, extensive23:35
projekt01The boston skin in uses also pagelets23:35
jhauserah ok23:36
projekt01But, I would be happy to see a good concept for the layout part. This isn't the scope of pagelets.23:37
projekt01Perhaps I have to think about that again and take a look at the pipeline stuff too. Would be nice if we could use one concept for wrap layout and inject content at once.23:38
projekt01But I like to implement the MVC patter 2.0 first before other things. I really run again and again into problems to control my object instance because of the MVC 1.5 pattern where we use in z3.23:42
jhauseryes it would be good to have one general concept23:42
jhauserMVC has versions ?23:42
projekt01Hope to show a concept where we really be able to control a instance and all its menus, views etc23:42
projekt01Yes, but the are just two concepts 1.5 (used in z3) and 2.0 where has a additional controller for a model23:43
projekt01the MVC 1.5 has views on a context but no controller where controls the access fro views.23:44
jhauserwe have tried to use something like an appcontrol behind the view23:45
jhauserthat's the application I meant before23:45
jhausera general controller for the page23:45
projekt01Are you comming to the sprint?23:45
jhauserbut it's rather hard to keep this thing simple and non redundant23:45
jhauserin k├Âthen?23:46
projekt01I mean a controller for the model which is the object instance e.g. context23:47
projekt01No, Neckar23:47
jhauserah no not planed23:47
jhauserit's in the beginning of october, right23:47
projekt01yes, October 6-9, 200523:48
projekt01jhauser, what was your target for develop a controller?23:49
jhauserwe wanted the view methods to be simple, provide only the data, which is central to the page23:50
jhauserand we didn't want that the pagetemplate reaches back to get navigation, rightboxes and so on23:50
jhauserso the object view places itself in the in something like the mainview, which is just a datastructure provided by the application context23:51
projekt01Imagine a controller on a context where provides a API. Right now this is implemented in the view class.23:52
jhauserright, we have relativ simple view classes23:52
projekt01A controller could split the data and view part for use in simply views.23:52
jhauserbut the appcontroller does not know which object it publishes23:53
jhauseror not really23:53
jhauserwe change controllers for special parts of a page23:53
projekt01A controller could provide a API for all widgets and a different API on the controller could serve the data for the widgets.23:54
jhauserfor example a discussion forum woul get it's own controller23:54
jhauserdo you think of an API like boxprovider23:55
projekt01I mean the controller could be a adapter for the context where you can call IController(yourForum)23:55
projekt01what do you mean with a boxprovider?23:55
jhauserthe controller collects objects, which are already in the presentation stage23:56
jhauserso you can call a box and put things into it, then the box is placed in slots of the controller23:56
jhauserI mean this kind of API23:57
projekt01That does the pagelet concept right now.23:57
projekt01The controller is only a API on the context where can be used if you need to get information from a object.23:58
jhauserna it's better if I try to sketch this down and provide it before your sprint, as third party example23:58
jhauserour stuff is far from clean, although it grew from general idea23:59
*** vlado_ has quit IRC23:59
projekt01e.g. a controller is the API used in the view, This means a controller will adapt your context/object and enhance the object with methods where the object doesn't provide23:59
projekt01Ok, would be cool to see different ideas23:59

Generated by 2.15.1 by Marius Gedminas - find it at!