IRC log of #zope3-dev for Friday, 2005-11-18

*** tarek has joined #zope3-dev00:10
*** sashav_ has quit IRC00:23
*** dobee has quit IRC00:41
*** GaryPoster has quit IRC00:48
*** palmTree has joined #zope3-dev00:52
*** palmTree has quit IRC00:55
*** zbir has joined #zope3-dev00:57
*** j1m has quit IRC01:01
*** MJ has quit IRC01:09
*** jinty has quit IRC01:41
*** natea has joined #zope3-dev01:59
*** _anguenot has joined #zope3-dev02:30
*** srichter has joined #zope3-dev02:36
*** natea has quit IRC03:02
*** Hellfried has quit IRC03:02
*** bob2 has quit IRC03:02
*** zbir has quit IRC03:02
*** projekt01 has quit IRC03:02
*** d2m has quit IRC03:02
*** SteveA has quit IRC03:02
*** Aiste has quit IRC03:02
*** andres has quit IRC03:02
*** dhuang_ has quit IRC03:02
*** jack-e has quit IRC03:02
*** vinsci has quit IRC03:02
*** natea has joined #zope3-dev03:03
*** zbir has joined #zope3-dev03:03
*** d2m has joined #zope3-dev03:03
*** SteveA has joined #zope3-dev03:03
*** Aiste has joined #zope3-dev03:03
*** andres has joined #zope3-dev03:03
*** Hellfried has joined #zope3-dev03:03
*** bob2 has joined #zope3-dev03:03
*** dhuang_ has joined #zope3-dev03:03
*** vinsci has joined #zope3-dev03:03
*** jack-e has joined #zope3-dev03:03
*** jfmoxley has joined #zope3-dev03:09
*** _anguenot has quit IRC03:15
jfmoxleyif i want a schema for a class attribute "1B", how do i define it?  "1B = zope.schema.float(" will give me a syntax error obviously03:33
jfmoxleyi can set the atttribute with setattr(object, "1B", -5), but i'm not sure how to retrieve it now... object.1B gives an error, too03:34
jfmoxleyi'm assuming i just need to use an underscore, but i wanted to see if that was the proper way03:35
*** GaryPoster has joined #zope3-dev03:38
*** sashav has joined #zope3-dev03:47
*** yota has quit IRC03:48
srichterjfmoxley: attribute names cannot start with a number03:50
srichterthat's a Python thing03:50
srichteractually, I am sure it is forbidden in most langauges03:50
jfmoxleyso the proper way to do this is to add an underscore, correct03:55
jfmoxleylike hitter._1B03:55
*** sashav_ has joined #zope3-dev04:13
*** sashav has quit IRC04:14
srichteryeah, though '_' means private in Python (by convention)04:23
srichterjfmoxley: any chance you can rename the variable?04:24
jfmoxleythanks stephan.  i'm hesitant to rename b/c i'm getting it as a field from another database04:26
*** sashav has joined #zope3-dev04:37
*** niemeyer has quit IRC04:40
*** sashav_ has quit IRC04:43
*** sashav has quit IRC04:45
*** sashav has joined #zope3-dev04:45
*** JoaoJoao has joined #zope3-dev04:55
*** sashav has quit IRC05:57
*** sashav has joined #zope3-dev05:57
JoaoJoaoWill a proper DateTime widget be in Z3.2?06:03
*** GaryPoster has quit IRC06:20
*** JoaoJoao has quit IRC06:22
*** Jim7J1AJH has joined #zope3-dev07:21
*** Jim7J1AJH has quit IRC07:42
*** zagy has quit IRC08:29
*** zagy has joined #zope3-dev08:33
*** sashav has quit IRC08:35
*** jhauser has quit IRC08:51
*** stub has joined #zope3-dev09:22
*** stub has quit IRC09:26
*** dobee has joined #zope3-dev09:29
*** hdima has joined #zope3-dev09:47
*** eins has joined #zope3-dev10:01
einshi all, how do I use sql_delimiter in Zope3 sql scripts?10:02
*** MJ has joined #zope3-dev10:08
*** sashav has joined #zope3-dev10:12
*** agroszer has joined #zope3-dev10:14
*** dobee has quit IRC10:15
*** MJ has quit IRC10:16
*** eins has left #zope3-dev10:34
*** dobee has joined #zope3-dev10:35
*** agroszer has quit IRC10:40
*** _anguenot has joined #zope3-dev10:51
*** philiKON has joined #zope3-dev11:13
*** drzoltron_ has joined #zope3-dev11:15
drzoltron_I've got a BrowserView which is called by a template. Is it possible to render a different template than the one defined in the zcml ?11:18
drzoltron_(very cryptic question ;))11:18
philiKONjust register the same class twice, each with a different template11:19
philiKONyou can conveniently use the <browser:pages> directive11:19
drzoltron_and how do I tell the publisher which to render ?11:19
philiKONthey have different names :)11:20
drzoltron_philiKON: it's not an object11:20
philiKONeverything is an object11:20
philiKONgotta go11:21
philiKONsee you 2 or 3 hours11:21
drzoltron_sure ;)11:21
*** philiKON has quit IRC11:22
*** zagy has quit IRC11:24
*** stub has joined #zope3-dev11:25
*** stub has joined #zope3-dev11:30
*** xenru has joined #zope3-dev11:30
*** zagy has joined #zope3-dev11:33
*** agroszer has joined #zope3-dev11:40
*** MJ has joined #zope3-dev11:44
*** romanofski has joined #zope3-dev11:45
romanofskimoin :)11:45
*** _anguenot has quit IRC12:07
*** _anguenot has joined #zope3-dev12:10
*** Theuni has quit IRC12:17
*** roym has joined #zope3-dev12:32
*** Aiste has quit IRC12:32
roymcan someone tell me what the z3 equivalent of Zope2's manage_afterAdd() is?12:33
roymI need a hook function to set up stuff after an object has been "located".12:33
romanofskithought that this is now handled by events12:34
romanofskisomething like ObjectAddedEvent, if I remember correctly12:34
roymI've been putting off learning the event model - I guess this is now reason enough to get into it - thanks!12:35
*** efge has joined #zope3-dev12:37
*** alga has joined #zope3-dev12:44
*** ignas has joined #zope3-dev12:47
*** Volpe has joined #zope3-dev12:51
VolpeI've set a page to permission="zope.Public" but when I try to access the page, I can't view it unless I authenticate.12:52
VolpeAny ideas?12:52
drzoltron_can i build the metal:use-macro"foo/loo/moo" string dynamically ?12:54
VolpeI think so, you can in zope 2 :)12:54
drzoltron_Volpe: how does that work, I tried with a $var but z3 didn't want it ..12:55
*** Aiste has joined #zope3-dev12:55
VolpeYou can use TALES, i.e "define macro <expression>" then use-macro="macro" can't you?12:55
drzoltron_Volpe: I tried this one : tal:define="absalon_viewmacro string:bog_macro;"12:56
drzoltron_<div metal:use-macro="context/$absalon_viewmacro/macros/absaloncontent">12:56
VolpePerhaps write a view method that will return the whole macro rather than using a $var12:57
*** mgedmin has joined #zope3-dev12:58
VolpeI'm a newb at z3 though, so don't count to much on what I say :-)12:58
drzoltron_hmm :)12:58
drzoltron_quite different than z3 but very cool12:58
VolpeThat's what I think, z3 is what z2 should have been :-)   If I could just figure out zcml.12:59
VolpeSo no one here knows why a page set to zope.Public could be requesting permission? :\13:00
d2mdrzoltron_: this was always <div metal:use-macro="context/?absalon_viewmacro/macros/absaloncontent">13:01
drzoltron_d2m: just found out :)13:01
drzoltron_got a traversal error though, do I have to register the .pt with the macro as a resource or a page ?13:01
d2mdrzoltron_: i think you will need to pass the correct macroname too13:02
drzoltron_well that should be absaloncontent in my case13:03
*** mkerrin has joined #zope3-dev13:04
VolpeHow is it possible, that I can declare a page public, that makes no context calls, no view calls no anything (just static html) and I have to authenticate before viewing it ???13:06
* Volpe 's eye twitches13:07
*** Volpe has quit IRC13:18
*** lunati1 has joined #zope3-dev13:18
*** lunati1 is now known as lunatik13:19
*** lunatik has left #zope3-dev13:19
*** niemeyer has joined #zope3-dev13:30
*** roym has quit IRC13:33
*** stub has quit IRC13:41
*** SteveA has quit IRC14:01
*** yota has joined #zope3-dev14:02
*** xenru|clone has joined #zope3-dev14:07
*** bavarian has joined #zope3-dev14:23
*** xenru has quit IRC14:23
*** xenru|clone has quit IRC14:26
romanofskiI'm a bit stuck here... my uses: view context/@@view_get_menu/zmi_views for example14:28
romanofskiI don't know, what "zmi_views" is in this context14:28
romanofskiview_get_menu is registered via a browser:page ZCML directive ... but zmi_views ...14:29
romanofskioh.. seems like a parameter for the BrowserMenu14:30
*** MrTopf has joined #zope3-dev14:38
srichterromanofski: zmi_views is the menu name14:44
romanofskiyeh thanks... but I don't know how I'm able to register a view class for my "template" - the view is always my contents view for the folder, and now I'm trying to register a view class with a browser:page14:46
romanofskiand try to access it via tal:define="view context/@@viewclass"14:46
romanofskibut fails with a system error currently14:46
srichterhave you read the books?14:47
srichterthey discuss a lot of this topic14:47
romanofskihm... yes14:47
romanofskibut they only describe the case, where you add a view for a class14:48
romanofskino... sorry.. i'm puzzled14:48
srichterso  what do you want to do then?14:49
romanofskiin short... a customized navigation14:50
romanofskiI have my customized template and a macros template14:50
romanofskihold in it's own skin14:51
romanofskiand now I want to create my own (global) navigation14:51
romanofskiso I checked the books and the other templates how they get the logic out of the view classes14:53
*** philiKON has joined #zope3-dev14:55
romanofskihoi philiKON :)14:56
srichterromanofski: look at zwiki, it has its own navigation in a separate skin15:00
romanofskiah cool - thanks srichter15:01
*** ChanServ sets mode: +o srichter15:02
bavarianI'm trying to get a simple user registration feature working. There are several open questions I have:15:11
bavarianMost important: Due to the nature of a user registration system anonymous users most be able to create a user at some point in the process.15:12
bavarianIn Zope2 I would probably have done one of two things, either use a proxy role or give the users access to a method in the trusted code (Python) layer that creates the user.15:13
bavarianIt seems that in Zope3 this is not possible as the checks for __setitem__ etc. are even enforced if they are not called directly, but from a method in a view support class or so.15:14
bavarianAm I missing something here?15:14
*** zbir has quit IRC15:16
bavarianTo rephrase a bit, I want an anonymous user to be able to do an action (create a user) under very special circumstances (he has completed the registration process), but not want him to have the permissions/roles needed for creating the user in general (e.g. via the ZMI).15:16
srichterI would write a trusted adapter that does this for you15:17
srichtertrusted adapter's context object is not security proxied15:18
srichterso you are responsible for protecting the adapter properly15:18
bavarianI see. That makes sense.15:19
bavarianThe other thing that makes things complicated is that the Pluggable Authentication stuff only exposes interfaces for authenticating, not for user management.15:20
agroszerThere is the principalfolder15:21
romanofskisrichter: it worked the whole time... I just used the expression inside a "string:" for testing purposes and just overlooked my stupid error15:21
bavariansrichter: So I have to do things like "userFolder = principals()['PrincipalFolder']", where I have to know the name of the folder.15:22
agroszersrichter: principalfolder can be accessed by code? I think so15:22
*** stub has joined #zope3-dev15:23
*** deo has joined #zope3-dev15:23
bavariansrichter: What I'd like to see is being able to just call a generic user management interface without having to know the internals of the authentication system used.15:23
srichterbavarian: because it is only supposed to do authentication; user management is not in its scope15:23
srichteryou should check out SchoolTool15:24
srichterST has a user management component and the auth utility stuff is just a hook into it15:24
bavarianOk, I'll have a look at it.15:25
srichterromanofski: ok, cool15:25
srichterbavarian: eek, as far as I know the principal folder is just a utility that you can look up15:26
srichterhave you read
agroszerWhat I thought is, if a properly registered principalfolder could be managed by code, then it is not necessary to write a complete authentication15:27
agroszerjust the interface between PF and my 'persons'15:27
bavariansrichter: I'll have to check. But even if it is, there is no defined interface for adding/managing a user. It's only using the standard interfaces from IContainer, which IMO are too generic for user management.15:27
srichterright, Zope 3 has not committed to one yet, if it ever will15:28
srichterI think a user management API is a pretty specific problem to CMS15:28
srichterI think that Z3ECM might have an answer for that15:29
*** tiredbones has joined #zope3-dev15:29
bavarianThis is definitely not a CMS thing. It's at least a web app thing, if not even a general "app that uses credentials to connect to a server" thing. Rather generic ...15:30
srichterwell, write a proposal, see what people think15:31
bavarianDo you have a macro for that answer? ;-) I've heard it rather often ...15:32
srichteror better, write a package for people to play with15:32
agroszerI need that package also :-)15:32
srichterno, but we are a proiposal driven project, so it should be my standard answer15:32
srichterespecially if it is a case of my opinion versus someone elses15:33
srichterwithout the opinion of other parties, it will be a deadlock anyways15:33
*** drzoltron_ has quit IRC15:34
agroszerI'd like to write the proposal, how-to?15:37
agroszerI checked Zope3Proposals on, do I need some permission there?15:38
d2mIIRC everyone can create new wikipages, you only need a special role to edit or comment on pages15:39
srichterd2m: can you give adam that role. please?15:41
*** roym has joined #zope3-dev15:41
d2magroszer: is this your menenr-id ?15:41
srichterd2m: he should have it for the entire wiki; same with bavarian15:41
roymI have registered an event handler for an IObjectAddedEvent.  I find15:41
roymthat when an object is added to a container via the adding view (/+),15:41
roymthe input values on the form are not available in the object at the15:41
roymtime of the event firing. Is this by design? What event can I wait15:41
roymfor that will fire after the object properties are set?15:41
d2magroszer: is this your member-id ?15:41
agroszerI'm "adamg"15:41
d2mjust a sec...15:41
* d2m agroszer has got the 'PowerMember' role15:43
d2msrichter: bavarian is Joahim Werber from Juvenio AG ?15:43
agroszeryes, edit is coming, thanks15:44
d2msrichter: i changed his rights too15:44
d2mhappy editing ;)15:44
bavarianI'm also ;-)15:44
d2moh, i see15:44
bavarianThat's why I don't have that much time for Zope during the week ...15:45
*** benji has joined #zope3-dev15:48
agroszerstill need some help, I don't want to mess it up... how-to add a new page?15:48
srichtercreate a Wiki link in Zope3Proposals, just like the others15:51
*** tlotze has joined #zope3-dev15:51
srichterclick on the ? mark behind the lionk15:51
srichternote that you should write the text first15:51
srichtertlotze: good morning15:52
tlotzeI'm trying to build and run the tests of the ZODB trunk, with a current Zope3 trunk built and installed in the path. However, a lot of tests fail. Am I doing anything wrong, or are there failing tests?15:53
tlotzegood morning15:53
srichteryeah, probably15:53
romanofskimornin tlotze *G15:53
srichterI recently hooked up the ZODB trunk to Zope 3 and all was fine15:53
tlotzeAh, romanofski *gg15:53
agroszeryou mean, I have to _edit_ the Zope3Proposals, put a new section with [my header] and text, like the others15:55
srichterok, I wanna do some work...15:56
* benji laughs like a mad scientist15:56
benjiIt lives!  It lives!!  :)15:56
srichterLOL (last comment, I prmise)15:57
benjisrichter, I just executed my first JavaScript in Python syntax :)15:58
srichterhow slow?16:02
VladDracjavascript in python syntax?16:06
benjisrichter, sorry, distracted :)16:07
benjisrichter, the translation is pretty fast16:07
*** zbir has joined #zope3-dev16:08
benjiVladDrac, it's an evil personal project I've been working on :)16:08
benjiso I have a view with this method:16:09
benji    @clientside16:09
benji    def test1():16:09
benji        for x in [1, 2, 3]:16:09
benji            alert('hi there ' + x)16:09
benjiand it gets turned in to JS and I can call it on the client16:09
srichteroh, so you have a server-side converter16:10
romanofskibenji: you know that the mozilla project is working on python support16:10
romanofskiso you can use python as a scripting language just like JavaScript16:10
benjiromanofski, yep, which is very cool16:10
benji9 out of 10 users still won't have clilent-side python though :(16:11
romanofskisure, it won't work where IE should be supported... but... cool16:11
efgebenji: @clientside seems awesome, finally I could program in javascript :)16:12
benjithis isn't really for building large systems in JS, it's about providing decent syntax for Python programmers to write small JS snippets16:12
benjiefge :)16:12
*** MacYET__ has joined #zope3-dev16:12
*** ignas has quit IRC16:17
tlotzeZODB building and testing again: Is there anything I haven't understood about the distutils, or why is there no module transaction in build/ It's needed by the tests.#16:18
agroszer"User management API" proposal is done16:18
agroszerat least a draft of it16:18
srichterwell, it is not a proposal; it is a collection of ideas16:25
srichteryou have not proposed an API16:25
agroszersorry, this is just a start16:25
srichterbecause once you propose an API, you will see the risks involved16:25
agroszeras soon as I'll have some time I'll enhance it16:25
agroszercurrently I'm deep in ecm.workflow, but if I didn't start it, I'll never16:27
srichter(note that a proposal is a great document to apply the things you have learned in college; a proposal is equivalent to a design document for school)16:27
*** GaryPoster has joined #zope3-dev16:28
*** natea has quit IRC16:33
agroszersrichter: I'm still fighting with the persistent workflow16:34
*** jinty has joined #zope3-dev16:35
* MacYET__ is flooding the checkin list16:39
*** sashav has quit IRC16:41
srichterMacYET__: why?16:42
MacYET__just updated zpl 2.0 to 2.1 on the z2 head16:42
MacYET__but this is z316:42
MacYET__wrong channel :)16:42
srichterMacYET__: that should not create a flood, not that you use SVN16:48
srichterone check-in16:48
srichterit's large and probably will be held for moderator approval16:48
MacYET__right, that happend already :)16:49
*** MacYET__ has left #zope3-dev17:00
andresTo whom should i forward a patch (adding the marker interface needed for sqlos/sqlobject) of psycopg?17:02
srichterandres: best would be you check it in yourself (i.e become a contributor)17:07
srichterandres: otherwise create an issue and add it to the collector17:08
andressrichter, okay for me. T whom i have to talk to get the commiter bits/become a contributor (talk to Brian or Ken via mail?)17:11
srichterandres: send an E-mail with the scanned, signed contributor agreement to jim _at_ zope.com17:15
srichterbenji: GaryPoster: can you also set someone up as a contributor?17:15
GaryPostersrichter: If you sent it to me, I'd give it to Jim. ;-)17:17
roymfolks: inside of a class, can I specify an attribute to be both a FieldProperty and a "property" [using the property(getter,setter) syntax] or does one override the other?17:17
*** hdima has quit IRC17:17
*** natea has joined #zope3-dev17:25
roymIn other words, I have:17:26
roymclass N:17:26
roym  p = FieldProperty(IXX['somep'])17:26
roym  def getP(self): ...17:26
roym  def setP(self,p): ...17:26
roym  p = property(getP,setP) # does this override the FieldProperty?17:26
*** bradb has joined #zope3-dev17:28
benjiroym, yep, you rebind p to something different17:30
benjiIf I understood what FieldProperties were, I could probably tell you how to make it work :)17:32
roymI guess this means there is no reasonable way to specify that the property conforms to an interface and have it be really a pair of methods in action.17:33
benjiroym, I don't see why not, if you have an interface that specifies an attribute, and you implement that attribute as a property that acts appropriately, then you've fulfilled the contract17:34
andresroym, if you specify the FieldProperty in the interface it should work.17:34
andresAt least it does here.17:34
roymso if I say that Object O implements Interface I, then I don't need to further specify FieldProperty on any attributes?17:36
bavarianDoes anybody know details about the encoding handling of the queuedDelivery mailer?17:36
roymThe real question (as benji suggests) is what does the FieldProperty decl in a class do?17:37
bavarianIt seems that it does not handle unicode on its own :-(17:37
*** natea has quit IRC17:38
agroszerroym: I think it also checks the attribute according to the interface schema17:38
bavarianYep, the interface says: "message is a byte string that contains both headers and body formatted according to RFC 2822."17:40
agroszerroym: check out zope.schema17:41
bavarianSo I'll probably have to port all my mail handling stuff from KONTENTOR to Zope3.17:41
*** Aiste has quit IRC17:43
roymagroszer: thanks.17:44
roymAn unrelated question: Are any events fired when you change field values on an object in @@edit.html view in zmi?17:45
roymI would expect IObjectModified to fire, but it doesn't seem to :)17:45
agroszerI think there is some object... yes, that one17:45
agroszerlook at
agroszerin the update method17:47
roymthanks - let me start with pdb in there.17:48
*** ChrisW has joined #zope3-dev17:50
ChrisWhow does Zope 3 do functional testing?17:50
ChrisW(specifically, file uploads)17:50
srichterlook at testbrwoser17:51
srichterbrowser = TestBrowser()17:51
srichtercontrol = browser.getControl('File Path')17:51
* ChrisW thinks about using Selenium17:51
srichtercontrol.value = StringIO('data')17:52
ChrisWdoes a usuable version of that ship with Zope 2.8?17:52
srichterChrisW: I prefer testbrowser above Selenium (it's Python)17:52
srichterChrisW: no, it is new for 3.2 and 2.917:52
ChrisWoh :-S17:52
ChrisWwhat's the minimum i need to check out to use it?17:53
srichterif you use Python 2.4, then you only need testbroser17:53
srichterit only weakly depends on zope.interface17:53
ChrisWcool, might well give it a go right now17:54
srichterwhen using it with Zope3, a normal Zope 3 environment should be ok17:54
*** sashav has joined #zope3-dev17:54
srichterREADME.txt (as always)17:54
* ChrisW will be using it standalone to do some scalability testing for a Zope 2 app17:54
ChrisWwell an sort-of-Plohn-app17:54
srichtertestbowser also comes with basic performance testing capabilities17:55
srichteryou can test the timing of a request17:55
srichter(in terms of pystones, of course)17:55
ChrisWI just want ms17:55
ChrisWcan i get that>17:55
*** faassen has joined #zope3-dev17:55
srichterwell, Pystones is better, because it is machine independent17:55
srichterI guess you can look at the code and just remove the pystone conversion17:56
ChrisWthis is all for a specific project running on a specific platform17:56
ChrisWI guess the main thing that makes me nervous is "what is a pystone?"17:56
srichterit is a well defined set of operations17:57
srichterso you could figure out what a pystone is in ms on your machine17:57
ChrisWmind if I just add an "output in ms" option to testbrowser?17:57
srichterno, I think this would be fine17:58
ChrisW(if I can, that is, I'm not sure I'll have enough zen...)17:58
ChrisWdoes testbrowser have unit tests?17:58
srichterno, because the functional test (README.txt) serves as unit test in this case ;-)17:58
ChrisWah, cool, so I can play with freedom on the timing front ;-)17:59
ChrisWnow I just have the firewall from hell to contend with17:59
ChrisWI _really_ _really_ wish that was accessible through http for anonymous and https for write access :-(17:59
srichterI think a proposal might go long ways on that one18:00
*** SteveA has joined #zope3-dev18:00
ChrisWfor which bit?18:00
*** SteveA has quit IRC18:00
ChrisWsheesh, not even time to say hello to Steve ;-)18:00
srichterhttp access for anonymous18:00
ChrisWwell, and https for write18:00
ChrisWbut I seem to remember these conversations before...18:01
ChrisWmaybe a mail to zope-dev to kick things off?18:01
*** SteveA has joined #zope3-dev18:01
ChrisWwelcome back Mr A ;-)18:02
SteveAhello chrisW18:02
ChrisWhurm, officially dead now?18:02
SteveAwebsite, yes18:03
ChrisWwhere'd helen's diary go?18:03
SteveAstill get email there, although i should see how much of it is actually spam18:03
*** palmTree has joined #zope3-dev18:03
SteveAshe decided she didn't want it any more, i guess18:03
ChrisWhehe, fair enough18:03
ChrisWsrichter: how do I 'install' testbrowser once I've checked it out? just make sure it's on the python path?18:05
srichterare you using plain Zope 3 for now?18:05
srichterif so drop it into src/zope18:06
srichterand type make18:06
ChrisWI'm just checking out the testbrowser folder from svn18:06
srichteraehm, forget this18:06
ChrisWI have python2.4 ;-)18:06
srichterah ok18:06
ChrisWplain, boring, python2.4 with nothing on it18:06
ChrisWshould I install, or just make sure the checkout is on my pythonpath?18:07
*** zagy has quit IRC18:07
srichterok, I think all you need to do is a create a top level zope dir and put testbrowser in it18:07
srichterChrisW: benji has recently tried to make testbrowser standalone, so he might be a better contact :-)18:07
ChrisWdo I need a
ChrisWis he around?18:07
benjihi, ChrisW18:07
srichterthere you go :-)18:07
ChrisWI am having a good day :-)18:08
ChrisW(well, apart from limi provoking me to flame Plohn on :S)18:08
benjiChrisW, testbrowser currently keeps up with time of request in seconds, I think it'd be a good idea to change that to time in ms, then you can use it18:08
ChrisWbenji: If I got a plain Python2.4 setup, no Zope 3, what's the best way to start playing with TestBrowser?18:08
ChrisWs/ms all the same to me ;-)18:08
benjiwell, it's in integer seconds, so less than 1 second requests aren't handled with much grace :)18:09
*** newnick has joined #zope3-dev18:09
benjiyou get zope.testbrowser from the cheeseshop:
benjiit has no external dependencies (I hope :))18:09
ChrisWhow does cheeseshop work?18:10
benjijust follow the link and then look for the download URL18:10
benjiit just points to a tgz, unpack and run setup.py18:10
benjioh, and testbrowser does use fractional seconds for timing, so you should be good to go there18:11
ChrisWwell, the problem is that the response time is currently minutes ;-)18:11
ChrisWPlohn sux18:12
ChrisWactually, in fairness, this isn't Plohn's fault18:12
ChrisWI think it's revisioning of pieces of content that are abotu 100Mb each in ZODB18:12
ChrisW(ie: 10 x 10Mb attachment...)18:12
ChrisWbenji: what is cheeseshop? how do I use it for my own packages? how do I find out more about it?18:13
benjijust go to and click on "Package submission" :)18:13
newnickMy system went down and my old nick is still sign on. Can only the channel operator remove a nick?18:14
benjinewnick, you can get NickServ to do it for you18:14
srichternewnick: what18:15
ChrisW'/nickserv ghost yournick yourpass18:15
srichternewnick: what's your old name?18:15
*** tiredbones was kicked by srichter (User terminated!)18:15
newnicksrichter, can you also remove tiredbones from schooltool?18:16
benjinewnick /msg nickserv ghost <primary-nick> <your-password>18:16
srichternope, because I am not an operator there18:16
benjiI think that'll do it18:16
SteveAmy system went down and my old nick ChrisW is still signed on.  srichter, can you kick my old nick from the channel please?18:16
srichterSteveA: sure, hold on :-)18:17
* ChrisW inserts something large into Steve ;-P18:17
ChrisWwhich country are you in nowdays, Steve?18:18
* ChrisW resists asking which planet you're on ;-)18:18
SteveAChrisW: this week, lithuania.  last week montreal.  montreal is a cool place.18:18
SteveAparticularly in wintertime18:19
ChrisWwtf were you doing there?18:19
ChrisWwaaagh... why do people take pleasure in installing dox to site-packages18:19
SteveAan ubuntu conference18:20
ChrisWoh? what's the paid work you're doing nowdays?18:20
*** romanofski has quit IRC18:21
SteveAChrisW: working on launchpad.net18:21
ChrisWsrichter/benji - anything exist to record a sequence of testbrowser commands from an http stream?18:22
ChrisWSteveA: what's that written in?18:22
benjiChrisW, yep, it's pretty beta at the moment, but see
benjiit lets you record a sequence of events in the browser and generates a testbrowser or selenium test from them18:23
ChrisWhmm, I think in my case, I may just do it by hand18:23
SteveAChrisW: python, of course.  zope3 for the webapp.  various twisted sqlobject kinda stuff too18:23
*** j1m has joined #zope3-dev18:23
ChrisWI have very specific shit I want to test18:23
ChrisWand yes, shit is _exactly_ the right word here ;-)18:24
ChrisWhow do I do auth using testbrowser?18:24
ChrisWand how do I time requests?18:24
ChrisW(posts requests, specifically)18:24
benjiChrisW, read the README and all will become clear18:26
srichtersee "Performance Testing" in README.txt18:26
* ChrisW is18:26
ChrisWbut that says it returns seconds, I thought you said it returned ms?18:26
*** zagy has joined #zope3-dev18:26
benjiit returns fractional seconds18:27
ChrisWit also doesn't cover authentication18:27
srichterno, it returns seconds, but a float of that18:27
srichteryes it does18:27
* ChrisW loox but doesn't see18:27
benjiChrisW, line 26 of the README18:27
srichtersee the first example in README.txt18:27
benjistart from the top and read through until you get board18:27
srichterno, line 1018:27
ChrisWyou have to build the auth header by hand?18:28
ChrisWanyone mind if I add an "addBasicAuth" method to it?18:28
benjiyes, very much (mind that is)18:28
*** fdrake has joined #zope3-dev18:29
* ChrisW would have thought it was just a helpder method to add to the browser class18:29
ChrisWI wanna do:18:29
benjitoo many helpers are unhelpfull18:29
srichterTestBrowser should not do more than a regular browser18:29
srichterhave a function that computes the header18:29
ChrisWwell, regular browsers do basic auth...18:29
ChrisWwhy force people to jump through more hoops?18:30
ChrisWand end up with ever framework implementing a different addBasicAuth method?18:30
ChrisWseems silly to me18:30
benjiI don't see this as too much of  a burden: browser.addHeader('Authorization', 'Basic mgr:mgrpw')18:30
ChrisWwell, don't you have to encoded that password?18:30
benjino need for a method, just set the header18:30
ChrisWwhy not?18:30
srichterbenji: (note that a plain username and assword only work for the publisher handler)18:30
benjijust like non testbrowser functional tests, it does it for you18:30
benjiright, srichter18:31
srichterbenji: (for a real website, you have to create the MD5 hash)18:31
ChrisWand I'm using a real website here ;-)18:31
ChrisWhence my desire for an addBasicAuth method18:31
ChrisWwhich encapsulates this often-needed functionality ;-)18:31
benjihmm, I'm -0 on it, but wouldn't kill anyone over it18:32
ChrisWokay, now what, exactly, do I need to md5?18:33
ChrisWand isn't it b64, not md5?18:33
benjiI think it's both18:34
srichtercould be18:34
srichtercheck out I do it there18:34
benjiI think you md5 the uname and pw and then b64 the hash and transmit it to the server18:34
benjibut you should check the spec18:34
ChrisWI don't think there's md518:34
*** andres has quit IRC18:34
fdrakeno, just base6418:34
fdrakej1m, wanna jump on AIM?18:35
ChrisWyeah, I now remember just how crummy http basic auth is ;-)18:35
srichter    def setUserAndPassword(self, user, pw):18:35
srichter        """Specify the username and password to use for the retrieval."""18:35
srichter        hash = base64.encodestring(user+':'+pw).strip()18:35
srichter        self.addheaders.append(('Authorization', 'Basic '+hash))18:35
*** dobee has quit IRC18:35
ChrisWokay, I'll subclass for now18:35
ChrisWbut don't beat me if I eventually add it back to the testbrowser  core ;-)18:36
j1msrichter, have you seen:
srichterrevision 4618:37
srichterI assume it is not very complete?18:37
srichteragain, I think the ICU code is very complex and I am concerned that it provides a lot of abstraction that is not needed18:38
*** JoaoJoao has joined #zope3-dev18:39
*** __mac__ has quit IRC18:40
*** dobee has joined #zope3-dev18:40
srichteranyway, I am not very interested in messing with the current I18n implementation18:40
JoaoJoaosrichter: Is it bad?18:41
srichterno, I just want to work on other things18:41
srichter(in my free time that is)18:41
srichterof course, if someone pays me to implement our I18n using pyICU then that's a different story18:42
*** tlotze has quit IRC18:43
JoaoJoaosrichter: Good... btw I did translate about 180 Zope3 messages to pt-br in Launchpad18:43
srichterj1m: your post is the first one since July on the MLs :-)18:43
srichterJoaoJoao: cool18:44
j1msrichter, yup18:44
JoaoJoaoNow I'm still trying to deal with catalogs18:44
j1mIt's also SWIG :(18:44
srichterj1m: I Think this project is pretty dead18:44
srichterj1m: yep18:44
j1mI very much doubt that it is dead.18:45
roymCan anyone suggest a good way to determine (in my event handler) if18:45
roymthe event object is of a particular type... Unfortunately an18:45
roymisinstance() check fails, because upon modification, the event18:45
roymfired carries a proxy object.18:45
j1mIn fact, I think they are presenting it at PyCon.18:45
JoaoJoaoWhen I create a catalog and add a FieldIndex, does it automatically index new objects?18:45
srichterj1m: really?18:45
j1mI suspect that that it is mostly internal to osa.18:45
agroszerbtw, philiKON: ayt ?18:45
j1mI don't think many people know about it yet.18:45
srichterj1m: also note that they use the ICU unicode type, not the standard Python one18:45
JoaoJoaoAnd BTW how scalable is the catalog?18:46
j1mBut I think there is a good bit of interest in a Python ICU binding.18:46
srichterI would hope so! Python has no I18n story at all18:47
j1msrichter, they provide pythonic apis.18:47
j1mfor example, their collation support is usable.18:47
ChrisWhmm, with testbrowser, how do I rest the browser?18:48
ChrisW(ie, start a new request, once I'm done with the old response?)18:48
JoaoJoaoI'm a bit lost in this Z3 catalog18:48
ChrisWbenji: ping!18:53
ChrisWImportError: No module named app.testing.functional18:53
JoaoJoaoI would need a product which would let me take a look at a real use of a catalog18:53
srichteroh, don't use:18:53
srichterfrom zope.testbrwoser improt Browser18:54
srichterfrom zope.testbrowser.browser import Browser18:54
srichterthis is the one that does not depend on the ftesting framework18:54
ChrisWthat looks a bit better18:55
ChrisWI got a 401 error ;-)18:55
ChrisWbtw,last_request_seconds appears to be innaccurate unless you have a successful request :_S18:57
*** sashav_ has joined #zope3-dev19:10
*** sashav has quit IRC19:10
*** sashav_ is now known as sashav19:10
*** dobee has quit IRC19:15
*** MJ has quit IRC19:17
*** sashav has quit IRC19:17
*** palmTree has quit IRC19:25
*** agroszer has quit IRC19:25
*** stub has quit IRC19:28
*** agroszer has joined #zope3-dev19:30
srichterbenji: I just looked at jsolait19:31
srichterit implements a very Python-like API19:31
srichterliek importModule() and string formatting a la Python19:32
*** ChrisW has quit IRC19:32
*** faassen has quit IRC19:34
JoaoJoaoMan this Zope3 architecture is great19:38
srichterI am glad you like it19:40
JoaoJoaoI didn't have enough time to check how good is sqlos, I wonder...19:52
*** hazmat has joined #zope3-dev19:54
*** ChanServ sets mode: +o hazmat19:54
*** _anguenot has quit IRC20:00
jintyJoaoJoao: normally sqlos talk happens on #z3-base20:04
*** ignas has joined #zope3-dev20:07
benjisrichter, jsolait is interesting, but seemed unmaintained the last time I looked20:12
JoaoJoaowhat about MochiKit?20:14
*** jinty has quit IRC20:16
srichterbenji: it is actively developed20:16
benjiJoaoJoao, MochiKit is very cool20:16
benjisrichter, cool, didn't know20:16
*** bradb has quit IRC20:21
roymAfter some tinkering with the event model, it seems to me that the20:22
roymadding view does the following:20:22
roym  1) add the object20:22
roym  2) fire the ObjectAdded event20:22
roym  3) set the attributes on the object20:22
roymShouldn't steps 2) and 3) be reversed - it seems one would need the20:23
roympassed in attributes to initialize the object in the event handler.20:23
j1msrichter, did you see I got a response to my PyICU questiona already? :P20:27
*** natea has joined #zope3-dev20:52
srichterj1m: what are they saying?20:55
srichterroym: I doubt this is true20:56
j1mThey fixed the bug I sort of reported. :)20:56
srichterah cool20:56
*** Aiste has joined #zope3-dev20:57
*** ignas has quit IRC21:04
*** fdrake has quit IRC21:08
roymsrichter: correct me if I am wrong, but21:10
roymIn zope/app/container/browser/
roym    def action(self, type_name='', id=''):21:10
roym        ...21:10
roym        notify(ObjectCreatedEvent(content))21:10
roym        self.add(content)21:10
roymis the user responsible for generating the ObjectAdded event? I don't see anywhere in the code where a notify() is used to send an ObjectAdded event.21:18
*** Jim7J1AJH has joined #zope3-dev21:19
*** MrTopf has quit IRC21:19
efgeroym: in the container code it's there21:20
efgegrep for ObjectAdded21:20
efgeit's a bit convoluted though...21:20
*** MJ has joined #zope3-dev21:22
roymI believe you, though I don't see where :)21:22
*** ToniR has joined #zope3-dev21:22
roymI mean, there is no call to notify, but the tests do show it being used.21:22
ToniRhow do i start zope3 on win32?21:23
ToniRused to be z2.py21:23
ToniRwhat is it now/?21:23
efgeroym: there's notify(event) where object, event = containedEvent(object, container, name)21:23
efgeand containedEvent chooses ObjectAddedEvent when appropriate21:23
efgethis is in contained.py21:24
roymah - I see, thanks.21:24
agroszerToniR: which version do you have?21:25
ToniRI just downloaded21:26
*** sashav has joined #zope3-dev21:26
ToniRlatest stable21:26
ToniR3.1 i think'21:26
ToniR3.1.0  - zope/app/version.txt21:26
*** efge has quit IRC21:27
agroszeryou have the install exe or the source?21:28
ToniREXE which created21:28
ToniRa number of dirs off21:28
ToniRPython 2.4 site-packages dir21:28
agroszerlook for mkzopeinstance21:29
ToniRok and?21:29
agroszerI don't know by heart where it is...21:29
ToniRi found it21:29
agroszerpython mkzopeinstance21:29
ToniRin zope/app./server21:29
ToniRah ok thanks21:30
agroszerno, not that21:30
agroszerI think it is placed in the python24/scripts21:30
*** roym has quit IRC21:31
ToniRaga found it21:31
ToniRit's a batch file21:31
agroszerthat's it21:31
agroszerstart it21:31
agroszerwill ask for instance home, user, password21:32
agroszerafter it finished, you will have an (instance home)/bin/runzope.bat21:33
ToniRyes thank you21:33
agroszeryou're welcome21:33
agroszerphiliKON: ayt?21:36
*** sashav has quit IRC21:37
JoaoJoaoGoing home, bye21:55
*** JoaoJoao has quit IRC21:56
*** Jim7J1AJH has quit IRC21:58
*** bavarian has left #zope3-dev22:00
*** mkerrin has quit IRC22:01
*** agroszer has quit IRC22:03
*** alga has quit IRC22:13
*** hazmat has quit IRC22:16
*** ToniR has left #zope3-dev22:17
*** niemeyer has quit IRC22:18
*** jfmoxley has quit IRC22:21
*** mgedmin has quit IRC22:24
*** agroszer has joined #zope3-dev22:25
srichterbenji: I just ran my first tutorial (only the test shows so far, but still ;-)22:38
philiKONagroszer, now i am22:43
agroszerwhat are the plans for the translations?22:44
agroszerI mean will you copy them somehow from launchpad to SVN?22:44
*** vinsci has quit IRC22:45
benjisrichter, awesome!22:49
benjisrichter, so what exactly do you see?22:49
* agroszer be right back, restart required22:50
*** agroszer has quit IRC22:50
srichterbenji: I can select a tutorial from a set of tutorials22:50
srichterand start it22:51
srichterWhen I click "Next" the first text of the tutorial (a doctest file) sjows up22:51
srichterI can completely click through the entire doctest file22:51
srichter(example code is ignored for now)22:51
srichterthe nice thing is that I think we can even use the tutorial code for unit tests22:52
*** agroszer has joined #zope3-dev22:52
benjisrichter, so you see the prose plus the web page the testbrowser opens?22:53
srichterno, no testbrowser commands are executed yet22:53
srichterI only see the prose22:53
srichterthere are quite a few things to do to be able to run the browser stuff22:55
benjiah, ok22:55
srichterbenji: but from selenium I am going to reuse the browserbot code22:58
*** xenru has joined #zope3-dev22:58
srichterit has some nice methods for selecting elements22:58
*** sashav has joined #zope3-dev23:00
*** sashav has quit IRC23:03
benjisrichter, cool, I figured you'd be able to make use of that23:06
srichterand I really like JSON RPC23:06
srichtervery easy and I get JS back23:07
srichter(selenium should use JSON instead of the plain HTTP requests)23:07
agroszersrichter: I think I solved the persistent workflow stuff23:11
srichteragroszer: yeah, how?23:12
agroszerI reparented the wfmc classes to persistent23:13
agroszerchanged the [] and {} to their persistent equivalents23:14
agroszerAs I remember that's it23:14
srichteroh, so you did take the hard route23:15
srichterI hope you subclassed the original objects23:15
agroszerthe hardest way was s(censored)g with an xpdl sample of z3ecm23:15
agroszerI did not touch too much code23:16
agroszerone more thing is that local utilities have to be used23:16
*** vinsci|2 has joined #zope3-dev23:17
*** vinsci|2 is now known as vinsci23:18
* agroszer is thinking about subclassing23:19
*** j1m has quit IRC23:22
srichterbenji: mmh, if I say <configure package="zope.testbrowser" /> in a config file, it tries to run some unit tests23:22
*** j1m has joined #zope3-dev23:23
agroszersrichter: But then I have to modify the ecm.workflow, according to the subclassed ones...?23:23
srichterwell, you can always cooredinate with the ECM guys23:24
srichtermaybe they take your changes23:24
agroszermy small problem is that they don't seem to have time23:25
agroszerbut that's an other story23:25
srichterbenji: I found it; when running we are not removing the "." dir from the path23:26
agroszerwould it bother that much if the wfmc package would be persistent?23:28
srichterwell, if the zope.wfmc package would be persistent you definitely need to write a proposal23:29
srichterfor Z3ECM I do not know23:29
benjisorry, srichter, was talking to Jim, good, glad you found it :)23:30
srichterbenji: I think eventually tutorials must be based on DocFileSuite objects23:32
srichterbecause special global variables and options might be expected23:32
agroszerok, I'll try to do subclassing way23:33
agroszerif that's too hard I'll write a proposal23:34
srichteragroszer: Note that I think subclassing is the way to go23:34
srichterbecause you probably want  different behavior for the persistent version eventually23:35
agroszerI believe in you, you are the expert  :-)23:35
agroszerIf the subclassing way needs some hooks in wfmc, e.g. in xpdl as it creates the definition,23:37
agroszerthese are ok?23:37
srichteryeah, we could abstract that code23:38
srichter(note that zope.wfmc does not use XPDL yet)23:38
agroszerok, then23:40
agroszerthat's it for today23:40
agroszergood night23:40
*** agroszer has quit IRC23:41
*** bradb has joined #zope3-dev23:48
*** benji has quit IRC23:51

Generated by 2.15.1 by Marius Gedminas - find it at!