IRC log of #zope3-dev for Thursday, 2006-05-18

*** rocky has quit IRC00:15
*** dobee has joined #zope3-dev00:20
*** dobee has quit IRC00:38
*** rocky has joined #zope3-dev00:43
*** gumpa has left #zope3-dev00:48
rockyis there a decent doc someplace detailing the new way of registering and querying a utility based on j1m's local component changes ?00:54
j1mLook at zope/component/registry.txt00:55
* rocky looks00:55
j1mbasically you get the site manager and call registry methods on it.00:56
rockythis seems strange to me "components = registry.Components('comps')"01:01
*** sashav has quit IRC01:11
*** rocky is now known as rocky|zzz01:44
*** yota has quit IRC02:02
*** zbir` has quit IRC02:27
*** zbir` has joined #zope3-dev02:35
*** rocky|zzz has quit IRC03:03
*** RaFromBRC has quit IRC03:09
*** nathany has quit IRC03:24
*** zbir` has quit IRC03:35
*** andrew_m has quit IRC03:52
*** tonico has quit IRC03:52
*** andrew_m has joined #zope3-dev03:52
*** tonico has joined #zope3-dev03:53
*** stub has joined #zope3-dev03:59
*** stub has quit IRC04:11
*** stub has joined #zope3-dev04:11
*** stub has quit IRC05:02
*** whit has quit IRC05:19
*** alecm has quit IRC05:21
*** alecm has joined #zope3-dev05:33
*** alecm has quit IRC05:34
*** projekt01 has left #zope3-dev05:38
*** niemeyer has quit IRC06:12
*** stub has joined #zope3-dev07:37
*** stub has joined #zope3-dev07:38
*** eins has joined #zope3-dev08:06
einshi08:06
*** BjornT_ has quit IRC08:23
*** sashav has joined #zope3-dev08:27
*** BjornT has joined #zope3-dev08:28
*** zopePloneConsult has joined #zope3-dev08:31
*** BjornT has joined #zope3-dev08:33
*** dobee has joined #zope3-dev08:37
*** BjornT has quit IRC08:37
*** BjornT has joined #zope3-dev08:38
*** BjornT has quit IRC08:41
*** sashav has quit IRC08:41
*** dlk has joined #zope3-dev08:49
*** BjornT has joined #zope3-dev08:50
*** hdima has joined #zope3-dev09:06
*** dunny has quit IRC09:11
*** sashav has joined #zope3-dev10:01
*** thehippo has quit IRC10:05
*** BjornT has quit IRC10:05
*** tarek has joined #zope3-dev10:09
*** MJ has quit IRC10:09
*** agroszer has joined #zope3-dev10:27
*** BjornT has joined #zope3-dev11:04
*** efrerich has joined #zope3-dev11:05
*** MJ has joined #zope3-dev11:14
*** MJ has quit IRC11:14
efrerichagroszer:ayt?11:14
agroszeryep11:15
efrerichThank you for the pyds11:15
agroszerwelcome11:15
*** MJ has joined #zope3-dev11:15
agroszerI missed the 'publish' state, hope you can download it...11:16
*** regebro has joined #zope3-dev11:16
*** volvox has joined #zope3-dev11:22
efrerichyes - I could (you put the revision number in the name - that is nice)11:22
agroszeryep, otherwise it would be a mess11:23
efrerichI'll install them in the next minutes11:23
agroszerI'm sure it will work11:25
*** jinty has joined #zope3-dev11:26
efrerichan instance from the trunk with your pyds is running11:32
agroszercool11:33
*** dunny has joined #zope3-dev11:37
*** Theuni has joined #zope3-dev11:39
*** zagy has joined #zope3-dev11:43
volvox    children = List(title=u'Children', [...]11:55
volvoxin my invariant checkChildren, I use len(obj.children)11:55
*** faassen has joined #zope3-dev11:55
volvoxbut it raises unsized... obj.__len__() works as intended11:55
volvoxi thought len() used .__len__(), isn't it so?11:55
volvoxehm, obj.children.__len(), of course, vs len(obj.children)11:56
volvoxthe first works, the second raises an exception.11:57
*** BjornT has quit IRC12:06
*** Theuni has quit IRC12:13
*** Theuni has joined #zope3-dev12:14
*** BjornT has joined #zope3-dev12:14
*** philiKON has quit IRC12:20
*** philiKON has joined #zope3-dev12:21
volvoxsorry. im a moron12:22
*** volvox has quit IRC12:29
*** volvox has joined #zope3-dev12:29
*** BjornT has quit IRC12:47
*** BjornT has joined #zope3-dev12:55
*** Theuni has quit IRC13:05
*** Theuni has joined #zope3-dev13:07
*** efrerich has quit IRC13:22
*** oferw has joined #zope3-dev13:23
*** dunny has quit IRC13:32
*** BjornT has quit IRC13:39
*** zagy has quit IRC13:41
*** gintas has joined #zope3-dev13:44
*** BjornT has joined #zope3-dev13:45
*** BjornT has quit IRC13:49
*** regebro has joined #zope3-dev13:50
*** mkerrin has joined #zope3-dev13:53
*** tonico has quit IRC13:54
*** BjornT has joined #zope3-dev13:56
*** zagy has joined #zope3-dev13:59
*** ignas has joined #zope3-dev14:10
*** mgedmin has joined #zope3-dev14:14
*** zagy_ has joined #zope3-dev14:30
*** zagy has quit IRC14:33
*** BjornT has quit IRC14:48
*** oferw has quit IRC14:56
*** BjornT has joined #zope3-dev14:56
*** baijum has joined #zope3-dev15:12
*** tonico has joined #zope3-dev15:18
baijumHello, what is alternative of "from zope.i18n import MessageIDFactory" in 3.3 ?15:19
regebrofrom zope.i18n import MessageFactory15:20
regebrono sorry15:20
regebrono, I changed my mind again, I think that's correct.15:21
regebro:) I don'15:21
baijumthanks :)15:21
regebro't have a 3.3 to play with here. :)15:21
baijumBTW, why 'ID' droped, just beautification?15:22
*** tiredbones has joined #zope3-dev15:26
*** ignas_ has joined #zope3-dev15:29
mgedminbaijum: different class15:30
mgedminMessageIDFactory was mutablr15:30
mgedminMessageIDFactory was mutable15:30
mgedminMessageID isn't15:30
*** ignas_ has quit IRC15:30
mgedminyou used to be able to do things like15:30
mgedminmsgid = _('$foo: $bar')15:30
mgedminmsgid.mapping = {'foo': 'Lalala', 'bar': 'lorem ipsum etc.'}15:31
mgedminnow you must do15:31
mgedminmsgid = _('$foo: $bar', mapping={'foo': 'Lalala', 'bar': 'lorem ipsum etc.'})15:31
baijummgedmin: ok, got it, thanks :)15:32
baijumBut, why MessageIDFactory dropped in 3.3, was it deprecated from 3.1 onwards?15:33
guruz_what is the reason the session credentials plugin does not work with the zope.Manager user? the basic http auth plugin does.15:33
guruz_(3.2.0)15:33
*** MrTopf has joined #zope3-dev15:35
MrTopfHi15:35
*** Theuni has quit IRC15:35
*** niemeyer has joined #zope3-dev15:36
d2mbaijum: are you trying to make wcsite run with z3.3 ?15:44
baijumd2m: no, I am trying run another internal app in 3.315:47
baijumany pointer to new alternatives of "zope.app.site" ?16:07
baijumespecially "zope.app.site.interfaces.ISite"16:07
mgedminthere's zope.app.component.interfaces.ISite16:08
*** alga has joined #zope3-dev16:09
baijummgedmin: thanks again :)16:10
* mgedmin just knows how to use ctags16:10
baijumany documentation for important changes from 3.2 to 3.3?16:11
mgedmindoc/CHANGES.txt is the place to look16:11
baijumok, I have simply put the tips I got now here : https://wiki.ubuntu.com/LearningZope3/NotesAndTips16:16
srichtercool16:17
srichterthanks16:17
baijumhmm... something like AMK's what's new will be nice for Zope 3 :)16:18
philiKONbaijum, feel free to write it :)16:24
baijumI am not AMK, ok let me try :)16:26
baijumI was looking at http://docs.python.org/whatsnew/whatsnew24.html oh! it will be very usefull if Zope 3 has unique numbers for Propsals, it helps documentation very much, IMO16:31
philiKONbaijum, my point exactly!!16:32
philiKONa bit more formalized proposal process would help a lot already16:32
philiKON(e.g. a  standard template for proposals like PEPs have and numbering)16:32
baijumwhy not just assign numbers for Proposals (including existing one), a new propsal required for that? a template/format can be drafted slowly though.16:35
volvoxZEPs ?16:35
volvoxcould we not adapt PEPs format/lifecycle? :-)16:36
volvoxs/not//16:36
baijumZEP = Zope Enhancement Proposal, is it?16:36
philiKONi think most proposals in zope 3 already have a good structure16:36
volvoxyes16:36
philiKONzep, zip, zop, i don't care :)16:36
philiKONjust give 'em numbers :)16:37
volvoxas long as a neeb can understand what's obsolete... last time I looked I didn't16:37
baijumThere is already http://www.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/ProposalTemplate , is this sufficient ?16:41
srichterI think it is :-)16:42
srichterI think overformalizing the proposal process is counterproductive for a smlal community like this16:42
srichterPython is much larger than us, and they have to make sure they can manage all those crazy ideas16:43
*** andrew_m has quit IRC16:43
*** baijum has left #zope3-dev16:50
*** eins has quit IRC16:50
volvoxassert("Boston only works with 3.3")16:54
volvoxright? :-)16:54
volvoxyes, the ProposalTemplate is good but I think when I looked (some time ago) the web site had old information not marked as such. Hope it's better now16:55
*** dlk has quit IRC16:59
*** BjornT has quit IRC17:04
*** mexiKON has joined #zope3-dev17:09
*** Aiste has quit IRC17:10
*** j1m has quit IRC17:10
*** j1m has joined #zope3-dev17:10
*** BjornT has joined #zope3-dev17:12
*** BjornT has quit IRC17:15
zopePloneConsultbaijum: Why not use the zope.org wiki?17:19
*** philiKON has quit IRC17:20
*** andrew_m has joined #zope3-dev17:20
*** BjornT has joined #zope3-dev17:22
*** projekt01 has joined #zope3-dev17:29
*** Aiste has joined #zope3-dev17:36
*** hdima has quit IRC17:38
*** projekt01 has left #zope3-dev17:40
*** Aiste has quit IRC17:41
*** MrTopf has quit IRC17:41
*** natea has quit IRC17:41
*** wrobel has quit IRC17:41
*** dokai has quit IRC17:41
*** Aiste has joined #zope3-dev17:41
*** MrTopf has joined #zope3-dev17:41
*** natea has joined #zope3-dev17:41
*** wrobel has joined #zope3-dev17:41
*** dokai has joined #zope3-dev17:41
*** bradb has joined #zope3-dev17:59
*** BjornT has quit IRC18:10
*** dunny has joined #zope3-dev18:13
*** roym has joined #zope3-dev18:14
*** alga has quit IRC18:15
roymIs there a way to set an attribute in TestRequest directly.18:17
roymI find that I can do:18:17
roym  request.form['k'] = "value"18:17
roymbut not:18:17
roym  request['k'] = "value"18:17
roym18:17
roymHowever, when the view is invoked via the publisher like so:18:17
roym  @@myview?k=value18:17
roymrequest['k'] returns a valid value.18:17
*** sashav has quit IRC18:17
*** BjornT has joined #zope3-dev18:18
regebroroym: request['k'] will look in request.form and request.environment and something more.18:26
SteveAi think that's kinda ugly18:28
SteveAtoo implicit18:28
*** oferw has joined #zope3-dev18:34
*** zagy_ has quit IRC18:37
*** jukart has joined #zope3-dev18:44
*** whit has joined #zope3-dev18:48
*** jukart has left #zope3-dev18:53
*** gumpa has joined #zope3-dev19:03
*** alecm has joined #zope3-dev19:05
*** oferw has quit IRC19:06
*** tristil has joined #zope3-dev19:08
*** MJ has quit IRC19:10
*** BjornT has quit IRC19:14
*** genconc has quit IRC19:23
*** BjornT has joined #zope3-dev19:23
tristilI'm unclear on what zcml I would use to bring a content provider into a view. Is it an adapter?19:28
*** nathany has joined #zope3-dev19:40
*** dunny has quit IRC19:40
roymregebro: thanks for the clarification.19:41
volvoxhttp://www.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/FrontPage/Downloads19:47
volvoxis ancient, reports 3.2.0 as the latest release19:47
volvoxjust another thing where zope.org is often dated19:49
roymquestion: Is it possible to pass arguments to a page from within zpt?19:49
roymstring:${context/@@mypageview}?arg1=xx doesn't work.19:49
roymMy intent is to use the same view (w/different request arguments)19:49
roymmultiple times in a page.19:49
volvoxyou are in a template which is associated to a view class, right?19:51
volvoxso you should call methods on that view19:52
volvoxpython:view.method(arg='blabla')19:52
volvox(I guess it should work)19:52
roymvolvox: sounds reasonable, thanks.19:53
volvoxcontext refers to the content object, view is the instance of the view class (which then has self.context as the content object)19:53
*** drzoltron has joined #zope3-dev19:57
*** BjornT has quit IRC19:58
*** drzoltron has left #zope3-dev19:59
*** drzoltron has joined #zope3-dev20:00
*** ignas has quit IRC20:00
drzoltronmexiKON: could you help me with a Five issue ?20:00
*** faassen has quit IRC20:00
*** volvox has quit IRC20:01
*** ignas has joined #zope3-dev20:05
mexiKONdrzoltron, later, ok? gotta hit the shower20:09
drzoltronmexiKON: :) np have phun20:09
*** dobee has quit IRC20:10
*** MrTopf has quit IRC20:12
*** zopePloneConsult has left #zope3-dev20:20
*** BjornT has joined #zope3-dev20:22
drzoltronanybody else who wants to volunteer ? ;)20:22
whitdrzoltron: why don't you just ask?20:23
mexiKONdrzoltron, back20:23
mexiKONyeah, just ask20:23
drzoltroncool20:24
drzoltronmexiKON: should we move to #z3-base ?20:24
mexiKONsure20:24
drzoltroncool20:24
*** regebro has quit IRC20:34
*** RaFromBRC has joined #zope3-dev20:35
*** jukart has joined #zope3-dev20:35
tristilDoes someone have a practical example of how to use a content provider with zcml directives?20:37
*** ignas has quit IRC20:53
*** stub has quit IRC20:54
d2mwith z3.3b1 i'm getting a ComponentLookupError from zope.component.createObject(None, page.type, page.text) - page.type is one of SourceTypes21:05
mexiKONfirst argument to createObject shouldn't be None21:05
*** gintas has quit IRC21:06
mexiKONz.c.createObject(factory_name, ...)21:06
d2mah, ok -- i changed it from zapi.createObject(None, page.type, page.text)21:06
*** drzoltron has left #zope3-dev21:07
mexiKONd2m, zapi.createObject and z.c.createObject are the same function21:07
mexiKONstill, the first parameter to createObject (the context parameter) has been deprecated in zope 3.1 or 3.2?21:07
d2mwell, then 'page' just happend to work for z3.2 by chance21:07
mexiKONbut definitely for a long time21:08
mexiKONno idea what you mean by "'page' just happened to work"21:08
mexiKONas said, z.c.createObjecdt(factory_name, *args, **kw).21:08
mexiKONend of story :)21:08
tristilHow do I instantiate a contentprovider for use in a view? I'm looking at the docfile, but I'm not sure how to convert from the python code to zcml.21:08
mexiKONyou don't instantiate things in zcml21:09
mexiKONyou register them21:09
tristilRegister, yes.21:09
*** tarek has quit IRC21:10
tristilFor instance, it has adapts(Interface, IDefaultBrowserLayer, Interface) on the class body.21:10
mexiKONso, just use <adapter factory="..." />21:11
*** tarek has joined #zope3-dev21:11
*** jinty has quit IRC21:11
tristilSo yeah, I have <adapter for="IMySkin" provides="IMyContentProvider" factory="ContentProviderClass" />21:12
d2mmexiKON: just trying to get wcsite running on z3.321:13
tristilAnyone know the next step? How do I register the Content Provider so it can be looked up in the view?21:19
*** oferw has joined #zope3-dev21:20
*** mkerrin has quit IRC21:26
*** MJ has joined #zope3-dev21:28
*** agroszer has quit IRC21:36
*** jukart has left #zope3-dev21:45
*** dunny has joined #zope3-dev21:47
*** yota has joined #zope3-dev21:54
*** mgedmin has quit IRC21:55
*** whit is now known as whit|out21:57
*** oferw has quit IRC21:57
*** Aiste has quit IRC22:01
*** tristil has quit IRC22:02
*** oferw has joined #zope3-dev22:03
*** regebro has joined #zope3-dev22:18
*** RaFromBRC is now known as RaFromBRC|away22:20
*** sashav has joined #zope3-dev22:20
*** Aiste has joined #zope3-dev22:22
*** regebro has quit IRC22:26
*** dunny has quit IRC22:28
srichterJ1m: are you there?22:41
srichterI tried the following and it failed at the first write attempt:22:42
srichterDemoStorage('Testing', FileStorage('/path/to/testing.fs', read_only=True))22:42
srichterwasn't this the use case for demoing Zope/ZODB via a CD?22:43
*** bradb has left #zope3-dev22:44
*** tristil has joined #zope3-dev23:06
*** natea has quit IRC23:13
*** pcardune has quit IRC23:15
j1msrichter, yes.  DemoStorage gor broken somewhere along the way.23:17
j1mgot23:17
j1mI'll fix it at some point. :)23:17
j1mactually a change to FileStorage and basically all storages that subclass BaseStorage broke DemoStorage.23:18
srichterI see23:19
srichterok, I can live without opening it read only23:19
srichteras long as it does not modify the DB, which it does not23:19
srichterit keeps the changes in the demo storage23:19
j1mright, but it creates some files, including a lock file,23:20
srichterJ1m: btw, I use this in functional testing using a testing layer23:20
j1mso it won't work on a cd.23:20
srichtervery cool! :-)23:20
j1m:)23:20
srichteralso, does the layer know about the level it is running on?23:20
j1mno23:21
srichterbecause when I run on level 2 I would like the test DB to be generated instead of looked up from a file23:21
srichterok23:21
srichteris there any way that the level could influence the layer to be used?23:21
srichterso that I can say use MyLayer1 in level 1 and MyLayer2 in level 223:22
j1mnot directly.23:22
*** whit|out is now known as whit23:22
srichterI guess the test runner only pulls information from the test suite, right?23:22
j1myup23:22
srichterso how can that be done indirectly?23:22
srichtercan the suite somehow get to the runner instance to look at the running level?23:23
j1mWhen you create your tests, make sure all of the tests using layer 2 have level 1.23:23
srichterok23:24
j1mI suppose you could automate this with a special suite constructor,23:24
srichtermmh23:24
srichterI could do a frames hack, but this seems too brittle23:26
j1myup23:26
srichteroh well, this was a a nice to have anyways23:26
srichterwhat I am planning to do now is check for the existence of the DB file; if it was deleted, create a new one and use it23:27
srichterthis way I can delete the DB whenever I want  a new one to be generated23:27
j1mI don't have enough context for that to be meaningful.23:27
tristilI get a ForbiddenAttribute for __dict__ for a content provider. It worked previously, but it wasn't setting any values on itself, except for context and view.23:28
srichterbasically I have a testing DB that is generated using a sample generator23:28
srichtermuch like School23:28
srichtermuch like SchoolTool has23:28
srichter(actually we copied that code over ;-)23:29
srichterwhen the data changes, I really need to create a new testing.fs23:29
*** natea has joined #zope3-dev23:30
srichterhowever, creating a new testing.fs usually causes the tests to break, because of the random generator (we provided some provisions that this does not happen too often)23:30
srichterso it would be nice for me to test the new version of testing.fs by simply running the tests on level 2, instead of level 123:31
tristilDo I have to add permissions to access a content provider?23:37
*** projekt01 has joined #zope3-dev23:37
tristilSorry, its methods?23:37
srichtertristil: you have to have the permission to access a content provider23:37
srichterin other words, your user must have been granted the permission that you speicfied the content provider needs23:38
tristilIt's a ForbiddenAttribute for the content provider's __dict__.23:38
tristilThe permission to access the content provider itself is zope.Public23:39
srichtermmh, in this case you should not even get this error, because the content provider should not be even security proxied23:39
tristilYeah, and it's also trusted="True"23:40
tristilFor good measure.23:40
srichtermmh, I have no idea what's wrong23:40
srichteryou have to debug this yourself a bit23:40
*** jinty has joined #zope3-dev23:42
projekt01tristil, can you paste the provider call in the zpt somewhere and the code from the provider?23:44
tristilprojekt01, I will.23:44
*** natea_ has joined #zope3-dev23:45
tristilprojekt01, http://zope3.pastebin.com/72534223:48
*** RaFromBRC|away is now known as RaFromBRC23:49
projekt01it's not a new style class, use class TitleSnippet(object): instead of class TitleSnippet:23:50
projekt01and try again.23:51
projekt01tristil, if you use trusted="True", you have to define also a class in ZCML.23:53
tristilprojekt01, the trusted is to get access to the title annotation.23:54
*** alga has joined #zope3-dev23:54
projekt01IPageElement should define getTitle as a method.23:56
projekt01can you try it again and past the error if it's not working with this changes?23:57

Generated by irclog2html.py 2.15.1 by Marius Gedminas - find it at mg.pov.lt!