IRC log of #zope3-dev for Tuesday, 2008-06-10

*** yota has joined #zope3-dev00:02
*** dobee has quit IRC00:02
*** dobee has joined #zope3-dev00:07
*** regebro has quit IRC00:16
*** tarek has quit IRC00:33
*** dobee has quit IRC00:38
*** norro has quit IRC00:46
*** gberdyshev_ has quit IRC00:48
*** flox has joined #zope3-dev00:56
*** b52lap has quit IRC00:59
*** benji has quit IRC00:59
*** b52lap has joined #zope3-dev01:03
*** sp0cksbeard has quit IRC01:08
*** timte has quit IRC01:14
*** greenman has joined #zope3-dev01:15
*** aclark|away is now known as aclark01:21
*** greenman has quit IRC01:22
*** greenman has joined #zope3-dev01:23
*** flox has left #zope3-dev01:23
*** RaFromBRC is now known as RaFromBRC|lunch01:28
*** aclark is now known as aclark|dinner01:40
*** greenman has quit IRC01:47
*** jamur2 has quit IRC01:48
*** alga has joined #zope3-dev01:50
*** whit has quit IRC01:50
*** J1m has quit IRC01:52
*** lurkymclurkleton has quit IRC02:05
*** aclark|dinner is now known as aclark02:06
*** yota has quit IRC02:11
*** nathany has quit IRC02:16
*** tdoggette has joined #zope3-dev02:23
*** greenman has joined #zope3-dev02:26
*** malthe is now known as malthe|Zzz02:30
*** greenman_ has joined #zope3-dev02:35
*** whit has joined #zope3-dev02:43
*** greenman has quit IRC02:50
*** greenman_ has quit IRC02:53
*** greenman has joined #zope3-dev02:54
*** RaFromBRC|lunch is now known as RaFromBRC02:58
*** b52lap has quit IRC03:37
*** srichter has quit IRC03:46
*** deo has joined #zope3-dev03:46
*** whitmo has joined #zope3-dev04:15
*** whit has quit IRC04:29
*** greenman has quit IRC05:05
*** romanofs1i has joined #zope3-dev05:05
*** romanofski has quit IRC05:05
*** greenman has joined #zope3-dev05:06
*** pcardune has joined #zope3-dev05:18
*** hazmat has joined #zope3-dev05:24
*** ChanServ sets mode: +o hazmat05:24
*** greenman has quit IRC06:02
*** greenman has joined #zope3-dev06:03
*** whitmo has quit IRC06:18
*** pcardune has quit IRC06:35
*** greenman has quit IRC06:40
*** rcrafton has quit IRC06:41
*** greenman has joined #zope3-dev06:41
*** reco has quit IRC06:42
*** dobee has joined #zope3-dev06:54
*** dobee has quit IRC06:54
*** dobee has joined #zope3-dev06:55
*** stub has joined #zope3-dev07:02
*** srichter has joined #zope3-dev07:02
*** mcdonc has quit IRC07:03
*** tdoggette has quit IRC07:07
*** hazmat has quit IRC07:10
*** binseer has joined #zope3-dev07:18
*** greenman has quit IRC07:37
*** vimes656 has joined #zope3-dev07:53
*** hazmat has joined #zope3-dev08:16
*** ChanServ sets mode: +o hazmat08:16
*** kursor_ has joined #zope3-dev08:31
*** dobee has quit IRC08:32
*** jukart has joined #zope3-dev08:38
*** jayaraj has joined #zope3-dev08:38
*** RaFromBRC has quit IRC08:43
*** mcdonc has joined #zope3-dev08:43
*** jodok has joined #zope3-dev08:43
*** timte has joined #zope3-dev08:48
*** quodt has joined #zope3-dev08:57
*** sorindregan has joined #zope3-dev09:38
*** agroszer has joined #zope3-dev09:41
*** charith_para has joined #zope3-dev09:43
*** norro has joined #zope3-dev10:07
*** afd_ has joined #zope3-dev10:12
*** thruflo has joined #zope3-dev10:21
*** tarek has joined #zope3-dev10:32
*** menesis has joined #zope3-dev10:40
*** MJ has joined #zope3-dev10:42
*** menesis has quit IRC10:43
*** menesis has joined #zope3-dev10:43
*** stub has quit IRC10:47
*** seletz has joined #zope3-dev10:49
*** flox has joined #zope3-dev10:51
*** bigkevmcd has joined #zope3-dev10:56
*** flox has quit IRC10:59
*** flox has joined #zope3-dev10:59
*** stub has joined #zope3-dev11:03
*** vimes656 has quit IRC11:03
*** romanofs1i is now known as romanofski11:04
*** jayaraj has quit IRC11:05
*** vimes656 has joined #zope3-dev11:06
*** markusleist has quit IRC11:06
*** jayaraj has joined #zope3-dev11:07
*** stub has quit IRC11:10
*** yotaff has joined #zope3-dev11:11
*** b52laptop has joined #zope3-dev11:12
*** kursor_ has quit IRC11:13
*** kursor has joined #zope3-dev11:14
*** ktwilight_ has joined #zope3-dev11:21
*** yvl has joined #zope3-dev11:31
*** maurits has joined #zope3-dev11:31
*** ktwilight has quit IRC11:37
*** stub has joined #zope3-dev11:39
*** malthe|Zzz is now known as malthe11:39
*** mkerrin has joined #zope3-dev11:41
*** malthe has quit IRC11:50
*** greenman has joined #zope3-dev12:03
*** projekt01 has joined #zope3-dev12:05
*** junkafarian_ has joined #zope3-dev12:26
*** amleczko has joined #zope3-dev12:28
*** junkafarian_ is now known as junkafarian12:33
amleczkohi, i have a problem with opened zodb connections. i want to execute method in new thread like here: it seems to work - i just got "ZODB.POSException.ConnectionStateError: Cannot close a connection joined to a transaction" when trying to invoke any http request12:37
*** amleczko has quit IRC12:39
*** amleczko has joined #zope3-dev12:39
*** jsadjohnson has joined #zope3-dev12:42
*** regebro has joined #zope3-dev12:44
regebroOK, so we have a buildout with a bin/test and a test, but of course the configure.zcml is not getting included in this very simple and basic test.12:46
regebroWhat is the canonical way of getting the configure.zcml included?12:47
*** malthe has joined #zope3-dev12:47
regebroI can't get all the million ways of test setup in Zope2, Zope3 and Plone and Doctets and functional tests and unit tests into my little tiny head.12:49
regebroI wish there was ONE way of doing this. :(12:50
*** dunny has quit IRC12:55
timteregebro: I don't know if all have, but some packages in has buildouts for testing them, those should be good examples12:59
regebrotimte: Good idea, I'll check that.12:59
afd_amleczko: you could look at lovely.remotetask or zc.async as "co-processors" for zope13:01
*** charith_para has quit IRC13:01
*** jpcw2002 has quit IRC13:03
amleczkoafd_: i'm looking :)13:03
regebroIf the test requires ZCML, is it the normally seen as a functional test? Even if no external modules are involved?13:05
regebrotimte: Can't find anything of interest.13:08
*** yvl has left #zope3-dev13:10
timteregebro: for instance the FunctionalDocFileSuite test class probably loads configure.zcml13:18
timteregebro: do you have _the_ zope book?  :)13:19
regebroYeaaah, but this isn't functional. :-)13:19
regebroI have Phillips books, which isn't helping in this case.13:19
regebroAnd it's not the newest version either.13:19
* regebro is ashamed13:19
timteI don't think unit tests ever load zcml, then they are not unit tests13:20
timtethen you have functional and integrational tests13:21
regebrotimte: OK, I suspected that.13:21
regebroThat's not obvious at all, btw. :)13:22
afd_amleczko: another solution might be to use an external queue (NQDQ for ex -> and to have external processes use the queue then call zope with the rezult13:22
amleczkoafd_: i'm testing zc.async13:23
regebrotimte: But OK, we'll use the FunctionalTestLayer to test the zcml, and make a separate unit test to test the functionality of the utility.13:24
regebroA bit silly, but if this is canon, then we do it like that. ;)13:25
timteregebro: what's confusing is that philipp and zope has different opinions about what really is functional testing13:26
timteregebro: it's not silly, it's called isolation  :)13:26
*** MJ has quit IRC13:30
*** MJ has joined #zope3-dev13:30
regebrotimte: And I have a third one. :)13:31
timtemaybe what you do is integrational testing?13:34
regebrotimte: Wel, I'm doing unit testing, really.13:35
regebroIt's just that I don't see why I should register the utilities in the setup, when I already have done it in configure.zcml. :)13:35
regebroI'm lazy. :)13:35
regebroWhat's really needed is a united consistent attitude and view, and documentation, for making tests in Zope3/Zope2 and Plone.13:38
regebroSo you make a test setup the same way in all environments.13:39
*** alga has quit IRC13:39
regebroJust using different layers, preferrably.13:39
*** greenman has quit IRC13:43
*** hexsprite has joined #zope3-dev13:47
*** flox has quit IRC13:50
*** flox has joined #zope3-dev13:51
*** harobed has joined #zope3-dev13:53
*** flox has quit IRC13:53
*** flox has joined #zope3-dev13:53
*** MJ is now known as MJ|lunch13:55
*** sorindregan has quit IRC13:56
*** dirceu has joined #zope3-dev13:57
*** dobee has joined #zope3-dev14:02
regebroAny hints on getting all registered interfaces from the component registry?14:08
regebroIt's "Do our job for free week"! :)14:09
*** markusleist has joined #zope3-dev14:13
*** amleczko has quit IRC14:20
*** MJ|lunch is now known as MJ14:22
*** dobee has quit IRC14:23
regebroTheuni: My GSoC is here and he is working on a component registry introspector.14:24
regebroWe did find how to get all interfaces registered btw.14:24
Theuniwho are you mentoring?14:24
Theuniare do you mean "here" as in at your place?14:25
regebroNo, Martin Lundwall. And yes.:)14:26
*** dirceu has quit IRC14:28
*** benji has joined #zope3-dev14:45
*** faassen has joined #zope3-dev14:47
*** stub has quit IRC14:48
*** amleczko has joined #zope3-dev14:58
*** whit has joined #zope3-dev15:01
*** afd_ has quit IRC15:05
*** mgedmin has joined #zope3-dev15:05
*** alga has joined #zope3-dev15:27
*** ignas has joined #zope3-dev15:35
*** kursor has quit IRC15:43
*** J1m has joined #zope3-dev15:44
*** srichter has quit IRC15:46
*** lurkymclurkleton has joined #zope3-dev15:57
*** jamur2 has joined #zope3-dev15:57
*** povbot has joined #zope3-dev16:10
*** lucielejard has joined #zope3-dev16:13
*** malthe_ has joined #zope3-dev16:40
*** reco has joined #zope3-dev16:43
*** whit has quit IRC16:49
*** malthe has quit IRC16:51
*** sorindregan has joined #zope3-dev16:54
*** flox has quit IRC16:54
*** harobed has quit IRC16:54
*** amleczko has quit IRC16:54
*** tdoggette has joined #zope3-dev17:05
*** mattt_ has joined #zope3-dev17:05
*** jluisn has joined #zope3-dev17:05
*** TheVision has joined #zope3-dev17:10
*** TheVision has left #zope3-dev17:11
*** TheVision has joined #zope3-dev17:13
*** malthe_ is now known as malthe17:14
*** kursor has joined #zope3-dev17:23
*** charith_para has joined #zope3-dev17:23
mattt_So, Zope 3 doesn't require any kind of 'server install', it's just a series of eggs/classes that are loaded by a python script?17:23
mattt_ie: the '-ctl' script?17:23
timtemattt_: the ctl script starts a server17:26
*** charith_para has left #zope3-dev17:26
timtemattt_: zope3 comes with a server, you don't need to install an external one, if that's what you mean17:26
mattt_right, but the server is defined in a buildout by the eggs included and some configuration data?17:26
timtesomething like that17:26
ignasit can work that way17:26
mattt_couldn't just be xml or zcml?17:30
*** nathany has joined #zope3-dev17:33
Theunibenji: ping17:34
*** vimes6 has joined #zope3-dev17:34
*** vimes6 has left #zope3-dev17:34
*** srichter has joined #zope3-dev17:35
*** MJ has quit IRC17:39
*** ChanServ sets mode: +o srichter17:40
*** whitmo has joined #zope3-dev17:45
*** rmarianski has joined #zope3-dev17:45
*** timte has quit IRC17:46
*** whitmo is now known as whit17:50
* jluisn is away: Saindo por enquanto.17:53
*** menesis has quit IRC17:53
*** sorindregan has quit IRC17:54
benjiTheuni: pong17:57
*** salfield has joined #zope3-dev18:00
Theunibenji: I wondered how you made those subsequent 0.3 releases of zc.sf without an 0.3 maintenance branch so i opted to create one now18:02
*** projekt01 has quit IRC18:02
*** jamur2 has quit IRC18:03
*** markusleist has quit IRC18:03
*** deo has quit IRC18:03
*** jfroche has quit IRC18:03
benjiIIRC, there had been no changes to the trunk since the previous release, so I just tagged the trunk18:04
Theunik. i derived it from your last tag18:04
*** jamur2 has joined #zope3-dev18:05
*** markusleist has joined #zope3-dev18:05
*** deo has joined #zope3-dev18:05
*** jfroche has joined #zope3-dev18:05
Theuniactually I guess that we should start calling it 1.0 at some point18:05
Theunithere really isn't anything missing feature-wise18:05
*** ccomb has joined #zope3-dev18:09
*** acsr has quit IRC18:12
Theunii'll do that when i have some time18:13
*** vimes656 has quit IRC18:13
mattt_Is there any mechanism for remote-including html files in a Zope 3 template?  A third-party package, perhaps?18:16
*** jukart has quit IRC18:17
mattt_like the apache <!--#include ...--> directive18:18
ignasdon't think so, though if I had to do it - i'd do it as WSGI middleware rather than as something in Zope18:19
mattt_So, create some WSGI app that I could use in Zope?18:20
ignasok, maybe not, i am not sure what problem you are solving18:20
ignasit seems that you just don't want to rewrite some legacy content as ZPT's and want to use them as they are?18:21
mattt_ignas: I've been provided with a set of templates designed for a typical LAMP environment.  Because they're processed by Apache they can use <!--#include .../foo.html --> to include some remote html before the document is sent to the user.18:21
mattt_If I can't do that, I'll have to update my templates if there are any updates to those remotely included fiels18:22
ignasif you are using buildout and paste18:22
mattt_which is the purpose of the remotely included files - they have some content that is managed centrally18:22
ignasthen - write a wsgi middleware that can process the include tag18:22
*** reco has quit IRC18:22
ignasand add it in the paste.ini18:23
mattt_so have my templates updated when I run buildout?18:23
*** jayaraj has quit IRC18:23
*** flox has joined #zope3-dev18:23
ignascreate code that does the same "work" apache did18:23
ignasand add it to paste.ini18:23
ignasas middleware18:23
ignasat least - that's the simplest way to make it work18:24
*** baijum has joined #zope3-dev18:24
ignasi am often wrong ;)18:24
mattt_seems like a reasonable solution ^_^  I'm just not entirely familiar with paste and WSGI :)18:25
ignasmight be useful then18:25
*** alecghica has quit IRC18:26
*** baijum has quit IRC18:27
ignasPaste egg has some examples of a middleware18:27
ignaslike "Paste-1.6-py2.4.egg/paste/"18:27
*** malthe has quit IRC18:28
mattt_cool, thanks18:28
ignasanother solution would be to use mod-wsgi compiled for python2.4 which would probably allow apache to do it's thing18:30
ignasbut for that you must feel confident in your ability to compile an apache module18:30
ignasinstall it and configure it18:30
junkafarianhey, is there a way for a container to parse the rest of the url without relying on the NotFound exception?18:31
ignasjunkafarian: containers do not parse urls18:31
junkafariani meant use the traversal logic18:31
ignaswhat are you trying to do?18:32
junkafarianto recognise when a specific container has been called and pass the rest of the url as args or somesuch18:32
junkafarianits for a gallery18:32
junkafarianand is basically going to use cataloged categories to filter content18:33
junkafarianso i want to have urls like: path/to/gallery/category18:33
ignasso why don't you write a custom traverser for that container?18:33
ignasthat would do category lookup18:33
ignasinstead of doing item lookup ?18:34
junkafarianthats what i want18:34
junkafarianwheres the best place to read up on that?18:34
*** acsr has joined #zope3-dev18:34
ignasno idea, i just look at my old code for that18:35
ignaslisppaste6: url18:35
lisppaste6To use the lisppaste bot, visit and enter your paste.18:35
junkafarianor just the location in the zope codebase?18:35
lisppaste6ignas pasted "Custom traverser registration" at
ignasthe zcml looks like that18:36
ignasjust take care to register it only for your gallery container18:36
ignasand make the custom traverser implement the IWhateverPublisher interface18:36
ignasit's "zope:view" in there18:37
ignasthough i guess simple adapter registration would work too18:37
junkafarianIWhateverPublisher eg: IHTTPPublisher?18:37
ignasas for type - IBrowserRequest or some kind of layer is more suitable too18:37
ignasyeah18:37 has some examples18:38
ignasmaybe not very good, but still something18:39
*** jayaraj has joined #zope3-dev18:39 - are better18:39
ignasbecause they have the code that deals with view lookup18:39
ignasif the category/item is not found18:39
ignasjunkafarian: and take care to handle items with same names as categories, if you will try traversing to both - container and categories in the same traversal step18:40
ignaslike gallery/image.jpg and gallery/fish/image.jpg both being valid18:40
ignasyou can get inaccessible images if someone will upload an image called "fish"18:40
*** tdoggette has quit IRC18:40
junkafarianim planning on blocking it all out of that skin18:41
junkafarianso its all done through the traverser18:41
ignasblocking what out?18:41
mattt_Is there some basic infrastructure available to determine which language to display the site in?18:42
junkafariandirect access to the objects18:42
ignasmattt_: yes18:42
junkafarianas all the data will be gathered server side18:42
*** reco has joined #zope3-dev18:42
ignasjunkafarian: I was talking about your traverser implementation18:42
junkafarianso was i :P18:43
ignasyou don't need to block anything in there18:43
junkafarianbasically using the traverser to block direct access to the contained objects18:43
ignaswell - it's more like - not giving not "blocking"18:44
junkafarianthere is that18:44
*** jayaraj has quit IRC18:44
ignasif the code to do that is absent - i wouldn't call it "blocking" ;)18:44
junkafarianjust a lack of providing :P18:44
ignasso yeah, in that case - just fire NotFound error if there is no such category, and there is no view with that name18:45
mattt_ignas: where can I find it?18:45
ignasmattt_: hmm, it's all around you, i mean - just use MessageFactory where you have to, and i18n:translate=""18:46
ignasor do you want some direct way to find out which language the page is in18:46
mattt_ignas: I want to find out which language the user is requesting18:46
ignashmm, in schooltool we had it in config file + reacting to browser configuration, then i had to add links to allow users to switch languages18:47
mattt_well, does the user want some page in french or english, for example.  So I can do things in my template like set the correct "lang" attribute on a tag18:47
ignasstoring the state in the session18:47
ignaslang attribute on a tag?18:48
*** binseer has quit IRC18:48
mattt_sure, like the <html> tag - I'd want something like <html tal:attributes="lang view/language">18:49
mattt_I need to know if the user is requesting the page in 'en' or 'fr'18:49
mattt_If I have an internationalized site, how does Zope know which language to publish in?18:50
ignaswell - automatically18:50
ignasthere is a utility18:51
ignasthat determines that information18:51
ignasfrom - configuration and browser settings18:51
ignasand then the rest of the zope does the right thing if you did the right thing ;)18:51
ignasupl = IUserPreferredLanguages(self.request)18:51
ignasreturn upl.getSelectedLanguage()18:51
ignasis the code to get the language if you want to do something about it yourself18:51
mattt_ah, cool, thanks18:52
ignasbut in schooltool it's only used to "mark" the right flag18:52
ignasin the selector18:52
ignasthe actual - pick the right text for "Hello" is done by Zope18:52
*** vimes656 has joined #zope3-dev18:54
*** rmarians1i has joined #zope3-dev19:07
*** reco has quit IRC19:08
*** reco has joined #zope3-dev19:09
*** faassen has quit IRC19:13
*** vimes656_ has joined #zope3-dev19:17
*** MJ has joined #zope3-dev19:21
*** thruflo has quit IRC19:21
*** seletz has left #zope3-dev19:22
*** agroszer has quit IRC19:28
*** jodok has quit IRC19:29
*** srichter has quit IRC19:31
*** srichter has joined #zope3-dev19:35
*** vimes656 has quit IRC19:36
*** rmarianski has quit IRC19:36
*** rmarians1i is now known as rmarianski19:36
mgedminuh, oh19:40
mgedminresources referring to other resources is a tricky thing19:40
*** jpcw2002 has joined #zope3-dev19:41
*** srichter has quit IRC19:42
*** mkerrin has quit IRC19:42
*** srichter has joined #zope3-dev19:42
*** tarek has quit IRC19:45
*** MJ has quit IRC19:46
*** gberdyshev has joined #zope3-dev19:49
*** tarek has joined #zope3-dev19:50
*** quodt has quit IRC19:55
*** jsadjohnson has left #zope3-dev19:55
*** rmarianski has quit IRC19:55
*** rmarianski has joined #zope3-dev19:58
*** TheVision has left #zope3-dev20:08
junkafarianignas: still there?20:10
ignasjunkafarian: yes20:10
junkafarianwhat should i return instead of the contained object in the publishTraverse method?20:10
junkafariancan i not just render a page template from it?20:11
ignaslisppaste6: url20:11
lisppaste6To use the lisppaste bot, visit and enter your paste.20:11
ignaspost your traverser there20:11
ignasso I would know what you are talking about20:11
lisppaste6junkafarian pasted "custom traverser" at
junkafarianwould you like the zcml too?20:13
junkafarianpublishTraverse gets called20:13
junkafarianbut it seems to continue traversing20:13
junkafarianand ends in a NotFound exception20:14
ignastraversers do not render20:14
ignasthey return objects20:14
ignasthat are then shown20:14
ignasfrom what I can recall20:14
junkafarianso should i just return self.context?20:14
ignasoh, yeah, double traversal is tricky20:14
ignaswhat I do most of the time is - store the state20:14
ignaslike "traversed into category 'foo'"20:15
ignasand return self20:15
ignasreturn a "proxy" category object20:15
ignasthat acts as a container20:15
ignasthat contains the images20:15
* ignas prefers the second approach20:15
ignasused the first one when doing some crazy stuff, like traversing into dates wiritten like 2007/01/1520:16
mattt_What's the difference between a BrowserPage and a BrowserView ^_^20:16
ignasdon't ask me ;)20:16
ignasjunkafarian: so what you want your traverser to return is a "Category" that has __parent__ set to the gallery object20:17
*** vimes656_ has quit IRC20:17
ignasit does not have to be persistent20:17
ignasjust has to have __name__ set to it's id and __parent__20:17
*** maurits has quit IRC20:17
ignasand then you either inherit from Container and implement the container bits20:17
junkafarianwill it require an interface?20:17
ignasor implement a custom traverser for your category20:17
*** RaFromBRC has joined #zope3-dev20:17
*** vimes656 has joined #zope3-dev20:18
junkafarianand how would i render the content from the Category object?20:18
ignaswell - Category traverser returns the image20:18
ignashow will the url for some image in there look like?20:19
*** kursor has quit IRC20:19
junkafarianits actually only going to be and no deeper20:19
ignasso the category will show what?20:20
ignasand html page?20:20
junkafarianwith a list of objects20:20
ignasand in that html page20:20
ignaswhat do you have?20:20
ignas<img > tags?20:20
junkafarianits actually a gallery....of links :P20:21
ignasoh, img tags will be pointing to images stored somewhere on the filesystem or even on another server... yes?20:21
junkafarianso no img tags20:21
ignasok, links20:21
junkafarianor if there are img tags then ^^yes20:21
ignasso there are no actual images in your ZODB20:21
ignasonly links to them ?20:21
junkafarianhell no :P20:21
junkafariani hate storing multimedia in databases20:21
ignasok, so you don't need a traverser for category20:21
ignasyou want a "view" for your category object20:22
ignasregistered for "index.html"20:22
ignasand you want to return that category object when someone tries traversing into your gallery20:22
*** sp0cksbeard has joined #zope3-dev20:22
junkafarianessentially yes20:22
junkafarianit would be great if i could just pass the remaining url to the container object20:23
ignaswhat container object?20:24
ignaswhat remaining url? if you only have "gallery/category/"20:24
ignasand no deeper20:24
junkafarianeg: pass /category to gallery20:25
ignaswell - you can do that in your traverser, i mean - all the traverser can see is "category"20:25
junkafarianas a string or list20:25
ignaswhat do you mean "pass"20:25
junkafarianso return the gallery object with 'category' as an arg or somesuch20:26
ignaswell - don't do that, you don't want traversers modifying or setting state to persistent objects20:26
junkafarianright ok20:27
junkafarianso best solution is?20:27
ignasadd a class Category20:27
ignasadd a method to your Gallery that is called20:27
ignasthat returns either error or none or a Category object for that string20:28
ignasand use that method in your traverser20:28
ignasor do whatever you like20:28
ignasi mean - it's your code20:28
junkafarianhow do i call it from the traverser?20:28
*** fcorrea has joined #zope3-dev20:28
ignashmm, cat = self.context.getCategory("name")20:29
junkafarianthen return cat?20:30
ignasif cat: return cat else: return queryMultiAdapter(get the view)20:30
ignasunless you don't want views on your gallery to work20:30
ignasand WTF you are doing there with get_url20:30
ignasif you want the name of the category - it's the "name" parameter20:31
junkafariansorry, copied it over from another class which someone else wrote :)20:32
*** TheVision has joined #zope3-dev20:32
junkafariani used name in publishTraverse20:32
ignasand - traversers do not render, they either return the View or the object and raise NotFound in other cases20:33
*** jluisn has left #zope3-dev20:33
* junkafarian hasnt used traversers before20:33
TheVisionHello.  I was hoping there may be someone around that may be able to help out with zc.sourcerelease issue??? :-)20:34
ignasTheVision: just state the question20:35
*** charith_para has joined #zope3-dev20:35
aclarkTheVision: as they say in #plone, "Don't ask to ask just ask." :-)20:35
TheVisionha thanks.. pasting code in clean area.. hold on..20:37
junkafarianignas: cheers for all your help btw :)20:42
ignasjunkafarian: you're welcome20:42
TheVisionthe packager goes through my buildout.cfg.. everything appears to be going great but when it gets to the last "part" .. which is itself..  it dies with the pasted error..20:44
*** norro_ has joined #zope3-dev20:44
ignaswell - you're in trouble20:44
ignasyou are using system python20:44
ignasand it has PIL installed already20:45
ignasso packaging machinery get's confused about it20:45
TheVisionSo i need to local python and PIL ?20:45
ignasPILwoTk i'd guess20:45
ignasas for local python20:45
ignasi have managed to get it working once, but the thing was not foolproof20:46
ignasget sourcerelease20:46
ignassourcerelease, the last time i tried it20:46
ignashad problems with including eggs that are not in your eggs cache20:46
ignasand you don't get eggs in eggs cache if you have them installed in your python, even if it's local20:46
TheVisioni got it working once as well.. but it was a couple months ago.. haven't changed my usage of python or anything since then20:47
ignasso local will solve PIL problem probably20:47
ignasor just plainly - try uninstalling PIL ;)20:47
TheVisionok, maybe here is a smarter question...  I need to release a buildout to a staging machine that is completely offline due to network..  obvisouly this product seems ideal but is there any other possible option to use?20:48
ignasnope, don't think so, this thing seems perfect (unless that machine is 64 bit and your machine is 32 bit )20:48
TheVisionmy sys admin would install python, PIL, etc. like this machine..20:48
ignasyou see - PIL is an egg20:48
TheVisionthey are same20:48
ignasand sourcerelease is failing20:48
ignasbecause it tries copyying PIL20:48
ignasfrom your site-packages to your eggs20:49
ignasat least that's my guess20:49
TheVisionPIL is evil..20:49
ignasactually - it's your linux distribution vs easy_install vs buildout20:49
TheVisioni believe we easy installed that..20:49
ignasso - uninstall PIL20:50
ignasoptionally - change the dependency to PILwoTK (to make it easier to build) and set your find_links to find that20:50
TheVisioni'll get PIL unsinstalled.. is there directions on how to add that to buildout?20:50
ignasat least we are using that, so building of PIL would not depend on TK20:50
ignaswell - your setup.py20:51
ignasshould have "PIL" in there20:51
ignasi'd guess20:51
ignasnot sure if there is a real PIL egg20:51
ignasi definitely know there is PILwoTk somewhere in zope repositories20:51
ignasin here
ignas for example20:52
ignasI have that egg in my own server20:53
ignasso i would not get all the unstable eggs from there20:53
ignaswhen setting find_links20:53
ignasbut do this at your own risk ;)20:53
TheVisioni guess i'm unsure as to what i need to add to buildout to include PILwoTk20:54
ignasit's "Works on my machine" certified ;)20:54
ignasfind some section with "eggs ="20:54
ignasadd find_links = path_to_where pil is20:54
TheVisionmy find links uses zope..distribution already so thats good20:54
benjiignas: darn, is taken20:54
ignasand add PILwoTk ot the list of eggs20:54
TheVisionand uninstall PIL and boom that should work?20:55
ignaswell - that worked for me ;)20:55
ignasactually - i am not using system python even20:55
ignasI am doing a one of a kind hack to bootstrap a virtual python and buildout in my sandbox20:56
TheVisionyeah i don't want to mess with virtual python20:56
ignasthen using virtualpython recipe to do that in the sourcerelease20:56
TheVisioni have eggs = elementtree20:56
ignasthen in the next line add20:56
*** mattt_ has left #zope3-dev20:56
ignas"     PILwoTk"20:57
ignasor is it PILwoTK20:57
TheVisionlooks like lowercase..20:57
TheVisionif i just added locally.. will system use locally.. so maybe I don't need to bother sys admin to uninstall?20:57
TheVisionguess I can find out.. ha20:58
*** charith_para has left #zope3-dev20:58
TheVision(trying new source release with local PIL fully installed, package came down no problem)21:01
TheVision**fingers crossed**21:01
*** vimes656 has quit IRC21:02
ignasif only I had the time (cared enough) to fix the bug that is bothering me in sourcerelease :/21:02
TheVisionnope didn't work..  looks like same error21:03
*** vimes656 has joined #zope3-dev21:03
TheVisionis it this bug or something else that is known?21:03
ignasTheVision: did you see the PILwoTk egg getting installed?21:03
ignasTheVision: it's a different bug21:04
TheVisionyup.. it came down no problems.. saw output of PIL Build Summary, etc..21:04
ignashmm, really the same error?21:04
ignassite-packages one?21:04
ignasso PIL is still in site-packages21:05
ignaswhich was the cause of your problems ...21:05
ignasat least I think21:05
ignasi might be wrong though21:05
TheVisioni just wish it was smart enough to use local PIL..  there are other people using this dev box so I can't just wipe system PIL without having everyone update to local PIL, etc..21:06
ignaswell - i'd use virtual python, but i would not suggest it ;)21:07
TheVisionin this IRC log with wiggy trying this...21:07
TheVisionmid-way down..21:07
ignasyeah - it's the bug21:08
ignasthat i want fixed21:08
*** bigkevmcd has quit IRC21:08
TheVisionseems similar to my problem21:08
TheVisionbut he got it working.21:08
*** junkafarian has quit IRC21:09
ignaswell - he is using virtualenv21:09
ignasand encountering the same problem21:09
ignassome eggs in stie packages21:09
TheVisionoh yeah.. now i see that21:09
ignasare excluded from the tarball21:09
ignaswhich is solved by21:09
ignasinstalling zc.sourcerelease in a buildout21:09
TheVisionwhich i did21:10
TheVisionas he directed me to21:10
ignasin a buildout that is using virtualpython21:10
ignasor a clean python21:10
ignasyour site-packages have to be empty21:10
ignasfor that to work i *think*21:10
ignasbut now I know how to update my sourcerelease tutorial21:10
ignaseven though I don't like it21:10
*** mattt_ has joined #zope3-dev21:11
TheVisionno offense.. i found current documentation very confusing21:11
TheVisioni've tried doing build via svn but it can't handle https://21:11
mattt_Are there any wysiwyg editors with Zope 3 integration?21:11
ignasmattt_: zope.html21:12
ignashas FCK editor widget21:12
mattt_oh great, thanks21:12
ignasTheVision: i have no idea what's the current documentation ;)21:12
ignasTheVision: i am doing the writeup for myself ;)21:12
TheVisionignas: well you should make it public.. haha21:13
ignas is the writeup, but it's *wrong*, as it is using easy_install to install zopeproject and zc.sourcerelease, while it should do a buildout for each21:14
ignasi might update it21:14
TheVisionmaybe i should try virtual python21:14
ignasand it is very *me* centric21:14
ignasas in - it reflects all the fears and issues i have had with this stuff ;)(21:15
ignaslike - "never require users to have root" and "never ask users to compile python"21:15
ignasand "no one has buildout installed on their machine"21:15
*** vimes656 has quit IRC21:17
ignassourcerelease will work only if the only thing you have in your site-packages is buildout21:18
ignasfrom what *I* understand21:18
ignasgoing home, bye21:19
TheVisionthanks for your help21:19
ignasthanks for the link to irc logs21:19
*** ignas has quit IRC21:19
*** whit has quit IRC21:23
*** gberdyshev_ has joined #zope3-dev21:28
*** sparcd has joined #zope3-dev21:28
sparcdI have a form that is being generated using formlib based on schema from interface IMyInterface. In a totally seperate product I'd like to extend the fields in IMyInterface with schema from IMyNewInterface, anyone got any pointers?21:30
*** tarek has quit IRC21:34
*** aclark is now known as aclark|away21:36
*** jpcw2002 has quit IRC21:36
*** gberdyshev has quit IRC21:43
*** markusleist has quit IRC21:43
*** tarek has joined #zope3-dev21:52
hazmatsparcd, make a new form21:53
sparcdhazmat: and subclass the functionality from the existing form?21:53
*** mgedmin has quit IRC21:54
hazmatsure.. and just set up the form fields as you want with your new interface21:54
sparcdhazmat: will give that a try...21:54
*** afd_ has joined #zope3-dev21:56
*** tarek has quit IRC22:22
*** tarek has joined #zope3-dev22:25
*** hazmat has quit IRC22:30
*** whit has joined #zope3-dev22:33
*** sparcd has left #zope3-dev22:35
*** greenman has joined #zope3-dev22:37
*** ARiKA-2 has joined #Zope3-Dev22:46
mattt_Is there some way to create a content class with a field that can contain multiple instances of some other object?  I don't want a folder, just a field in an object which can contain objects.22:47
mattt_multiple instances of some other class.. :)22:47
mattt_For example, a vocabulary with translatable terms.22:48
ARiKA-2Zope 3 has no way to run with Python 2.5? lol22:49
*** greenman has quit IRC22:51
*** dunny has joined #zope3-dev22:54
*** yota has joined #zope3-dev23:04
*** aclark|away is now known as aclark23:05
*** norro_ has quit IRC23:07
*** mgedmin has joined #zope3-dev23:08
*** afd_ has quit IRC23:14
*** RaFromBRC is now known as RaFromBRC|lunch23:15
*** alga has quit IRC23:20
*** philiKON has joined #zope3-dev23:47
*** malthe has joined #zope3-dev23:50
*** regebro has quit IRC23:50
*** TheVision has quit IRC23:51
*** harobed has joined #zope3-dev23:52
*** greenman has joined #zope3-dev23:54
*** RaFromBRC|lunch is now known as RaFromBRC23:54

Generated by 2.15.1 by Marius Gedminas - find it at!