IRC log of #zope3-dev for Monday, 2008-03-10

*** alecm has joined #zope3-dev00:29
maltheI get the following exception in a functional test; in a real application it runs fine: "InvalidObjectReference: Attempt to store a reference to an object from a separate connection to the same database or multidatabase"00:34
maltheIt occurs when I annotate an ``ore.workflow`` persistent workflow that is made up from transitions defined on a module-level.00:37
*** d2m has quit IRC00:40
*** sunew has quit IRC00:42
maltheSo the issue is really that I'm creating a persistent object that gets a different connection to the ZODB.00:45
*** norro has quit IRC00:51
*** lisppaste6 has quit IRC00:56
*** jsadjohnson has quit IRC01:04
*** lisppaste6 has joined #zope3-dev01:09
maltheOkay it seems to have to do with persistent utilities as instantiated by getUtility.01:12
*** quodt_ has quit IRC01:13
*** regebro has quit IRC01:21
*** malthe is now known as malthe|Zzz01:21
*** reco has quit IRC01:24
*** alecm has quit IRC01:28
*** rcrafton has quit IRC01:39
*** salfield has quit IRC02:04
*** harobed has quit IRC02:05
*** alecm has joined #zope3-dev02:16
*** ccomb has quit IRC02:18
*** b52laptop has quit IRC02:25
*** alecm has quit IRC02:38
*** febb has joined #zope3-dev02:43
*** J1m has quit IRC02:58
*** sm has quit IRC03:01
*** hazmat has joined #zope3-dev03:13
*** ChanServ sets mode: +o hazmat03:13
*** whit has quit IRC03:38
*** whit has joined #zope3-dev03:41
*** lucielejard has joined #zope3-dev03:55
*** whit has quit IRC03:55
*** whit has joined #zope3-dev04:07
*** whit has quit IRC04:13
*** reco has joined #zope3-dev04:27
*** lucielejard has quit IRC04:42
*** lucielejard has joined #zope3-dev04:42
*** lucielejard has quit IRC04:43
*** reco has quit IRC04:45
*** reco has joined #zope3-dev04:52
*** reco has quit IRC05:10
*** reco has joined #zope3-dev05:37
*** reco_ has joined #zope3-dev05:48
*** reco has quit IRC05:55
*** reco has joined #zope3-dev06:05
*** stub has joined #zope3-dev06:06
*** reco_ has quit IRC06:07
*** reco_ has joined #zope3-dev06:21
*** tarek|away has quit IRC06:24
*** tarek|away has joined #zope3-dev06:24
*** reco has quit IRC06:29
*** reco has joined #zope3-dev06:33
*** reco_ has quit IRC06:40
*** febb has quit IRC06:45
*** febb has joined #zope3-dev06:46
*** tarek|away has quit IRC06:48
*** reco_ has joined #zope3-dev06:53
*** reco has quit IRC06:53
*** pcardune has joined #zope3-dev07:04
*** reco_ has quit IRC07:10
*** sm has joined #zope3-dev07:11
*** reco has joined #zope3-dev07:12
*** afd_ has joined #zope3-dev07:14
*** pcardune has quit IRC07:25
*** huajie has joined #zope3-dev07:26
*** jayaraj has joined #zope3-dev07:33
*** reco has quit IRC07:35
*** amit_am has joined #zope3-dev07:41
*** reco has joined #zope3-dev07:41
*** reco has quit IRC08:00
*** d2m has joined #zope3-dev08:00
*** reco has joined #zope3-dev08:04
*** afd_ has quit IRC08:10
*** philiKON_ has joined #zope3-dev08:11
*** reco has quit IRC08:20
*** philiKON has quit IRC08:26
*** sorin has joined #zope3-dev08:44
*** sorin is now known as sorindregan08:44
*** jukart has joined #zope3-dev08:50
*** afd_ has joined #zope3-dev09:08
*** kursor has joined #zope3-dev09:23
*** febb has quit IRC09:28
*** projekt01 has joined #zope3-dev09:58
*** harobed has joined #zope3-dev10:01
*** timte_ has joined #zope3-dev10:04
*** timte has quit IRC10:06
*** ghendi has joined #zope3-dev10:08
*** jpcw2002 has joined #zope3-dev10:10
*** pelle_ has joined #zope3-dev10:17
*** norro has joined #zope3-dev10:17
*** malthe|Zzz has quit IRC10:27
*** jodok has joined #zope3-dev10:30
*** quodt_ has joined #zope3-dev10:32
*** toutpt has joined #zope3-dev10:34
*** MJ has joined #zope3-dev10:38
*** sorindregan has quit IRC10:51
*** malthe has joined #zope3-dev10:52
*** sorin has joined #zope3-dev10:52
*** sorin is now known as sorindregan10:52
*** maurits has joined #zope3-dev10:57
*** febb has joined #zope3-dev11:03
*** bigkevmcd has joined #zope3-dev11:11
*** ktwilight_ has joined #zope3-dev11:36
*** mkerrin has joined #zope3-dev11:37
*** markusleist has joined #zope3-dev11:41
*** ccomb has joined #zope3-dev11:42
*** zagy has joined #zope3-dev11:43
*** pyqwer has joined #zope3-dev11:47
pyqwerDoes someone know how to reach through informations from the Auth/Credentials Plugins to my Login form?11:48
*** zagy has quit IRC11:49
pyqwerI can successfully authenticate, but I for instance don't know how to check in my login form why my authentication failed (no cookies enabled, wrong login, wrong password) etc.11:49
pyqwerAnd I need to communicate this info to the user.11:49
*** ktwilight has quit IRC11:51
*** goschtl has joined #zope3-dev11:55
*** jodok has quit IRC11:56
*** thruflo has joined #zope3-dev12:07
*** b52laptop has joined #zope3-dev12:11
*** mderstap has joined #zope3-dev12:13
*** ktwilight has joined #zope3-dev12:17
*** dunny has quit IRC12:23
*** ktwilight_ has quit IRC12:32
*** sunew has joined #zope3-dev12:42
*** timte_ is now known as timte12:51
*** stub has quit IRC13:07
*** mcdonc has quit IRC13:12
*** zagy has joined #zope3-dev13:14
*** philiKON_ is now known as philiKON13:20
*** sunew has quit IRC13:26
*** MJ has quit IRC13:34
*** MJ has joined #zope3-dev13:34
*** salfield has joined #zope3-dev13:40
*** sm has quit IRC13:45
*** benji has quit IRC13:47
*** mcdonc has joined #zope3-dev13:50
*** stub has joined #zope3-dev13:53
*** projekt01 has quit IRC14:13
*** rocky has joined #zope3-dev14:23
*** toutpt has quit IRC14:24
*** benji has joined #zope3-dev14:25
*** niemeyer has joined #zope3-dev14:43
*** ccomb has quit IRC14:55
*** MJ is now known as MJ|lunch14:57
*** MJ|lunch is now known as MJ|out14:57
*** afd_ has quit IRC15:02
*** toutpt has joined #zope3-dev15:06
*** danielblackburn has joined #zope3-dev15:10
*** rcrafton has joined #zope3-dev15:24
*** jodok has joined #zope3-dev15:27
*** whit has joined #zope3-dev15:27
*** whit has quit IRC15:34
*** whit has joined #zope3-dev15:35
*** mderstap has left #zope3-dev15:35
*** jsadjohnson has joined #zope3-dev15:37
*** stub has quit IRC15:39
*** projekt01 has joined #zope3-dev15:40
*** kursor has quit IRC15:45
*** huajie has quit IRC15:48
*** nathany has joined #zope3-dev15:54
*** tarek has joined #zope3-dev15:59
*** reco has joined #zope3-dev16:00
*** ghendi has quit IRC16:04
*** MJ|out is now known as MJ16:05
*** malthe has quit IRC16:10
*** jayaraj has quit IRC16:12
*** salfield_ has joined #zope3-dev16:15
*** salfield has quit IRC16:17
*** salfield_ is now known as salfield16:18
*** afd_ has joined #zope3-dev16:22
*** malthe has joined #zope3-dev16:22
*** nouri has joined #zope3-dev16:29
*** rmarianski has joined #zope3-dev16:40
*** whit has quit IRC16:42
*** lucielejard has joined #zope3-dev16:44
*** RaFromBRC has joined #zope3-dev17:01
*** norro has quit IRC17:17
*** pelle__ has joined #zope3-dev17:20
*** norro has joined #zope3-dev17:26
*** sorindregan has quit IRC17:27
*** pelle_ has quit IRC17:35
*** pelle__ has quit IRC17:38
*** pcardune has joined #zope3-dev17:44
*** pcardune_vm_ has joined #zope3-dev17:56
*** pcardune_vm_ is now known as pcardune_vm17:57
*** norro has quit IRC18:02
*** danielblackburn has quit IRC18:04
*** reco is now known as reco|meeting18:13
*** norro has joined #zope3-dev18:20
*** jodok has quit IRC18:24
*** projekt01 has quit IRC18:28
*** pyqwer has quit IRC18:42
*** nouri has quit IRC18:47
*** maurits has quit IRC18:50
*** pyqwer has joined #zope3-dev18:50
pyqwerafd_: Hi, if I remember right, you also recently implemented some authentication, right?18:50
afd_not recently, but maybe I can help you18:51
*** reco|meeting is now known as reco18:51
afd_I've debuged code of auth related stuff18:51
pyqwerOh, that would be great. The authentication is currently working very well, but I don't know how to pass through information to my login form.18:51
pyqwerFor instance, passing why a login failed (no such user, wrong pass etc.)18:52
pyqwerIn my login form, the authentication has already be done and I know nothing about it.18:52
*** febb has joined #zope3-dev18:53
afd_pyqwer: thinking18:53
pyqwerI could perhaps put some information in the thread, I assume. But I'm unsure if this is nice.18:53
afd_most of the times the purpose of the login form is just to serve as a place where to put info for the request18:54
afd_then the credential plugin takes this info18:54
*** pbugni has joined #zope3-dev18:54
*** jpcw2002 has quit IRC18:55
pyqwercurrently, I "recheck" the password in the action handler of my form, but this is quite silly.18:55
afd_have you written your own authentication and credential plugins?18:56
pyqwerMy own authentication, yes, credential not yet, but that should not be too hard.18:57
pyqwerMoreover, there's a similar problem in the credentials, too.18:57
pyqwerIf the browser does not support cookies, the credential plugin will (hopefully) notice this and redirect the user to a specific page.18:57
afd_can't you throw some meaningful error on authenticateCredentials? and display that error in an error page...18:58
*** agroszer has joined #zope3-dev18:58
pyqwerafd_: Hmmm, but who would catch this error?18:58
pyqwerA generic error page? Hmmm.18:59
afd_pyqwer: either register a generic page for all exceptions, which would show the errors18:59
afd_or throw specific errors, and register pages just for them18:59
pyqwerSo, it's quite common to have a login page that displays "Wrong user/password combination" in case the user entered a wrong login.18:59
pyqwerHmmm, quite complicated - perhaps it's easier then to put the information in the local thread then?19:00
afd_you mean, annotate the request?19:01
afd_pyqwer: it's not that hard, though, your use case, to display "wrong username/password"19:01
pyqwerNo, if I understand it right, you can do something like "from thread import local". And then you can just write "local.auth_error=blabla".19:01
pyqwerAnd in my form, I once again import local and access the information.19:02
afd_check for the auth input (which should be in the request), check if the is different from zope.anybody19:02
*** tarek has quit IRC19:02
pyqwerYes, that's one option I also already use, I check if the request provides IUnauthenticatedPrincipal.19:02
pyqwerThis tells me if the authentication succeeded but not why it did not.19:03
afd_like, for example, missing cookies support?19:03
pyqwerYes, for instance.19:03
*** timte has quit IRC19:03
pyqwerOr "no such user"19:04
pyqwer(which is different from a wrong password)19:04
afd_maybe you can get away with just 'wrong username/password'19:04
pyqwerHmmm, unfortunately not, there's a lot more info.19:04
afd_I think plone, for instance, has some js code to check cookies support19:04
*** b52laptop has quit IRC19:04
pyqwerFor instance, in my system it's possible to lock out users (in case they did something nasty).19:05
afd_I see19:05
pyqwerSo, I don't only check the password but also a flag "locked" on the user.19:05
*** b52laptop has joined #zope3-dev19:05
afd_shouldn't be too hard to implement those error pages, though19:05
pyqwerAnd what I'd like to do is to redirect the user to another page in case he is locked.19:05
pyqwerSame thing for an unconfirmed user.19:05
pyqwerI assume, in the authentication utility, I can't redirect, right?19:06
afd_if you have access to the request, maybe19:07
afd_but I don't see it used in the zope equivalent stuff19:07
pyqwerHmmm, I'll check that.19:07
afd_it's not that hard to write your custom exception page..19:08
pyqwerAh, I see, so all I do is to register a view for a custom error?19:09
pyqwerYes, that's an option.19:09
pyqwerAnd then, I have another (very silly) thing: My Login form has an "OK" and "Cancel" button.19:09
pyqwerYou probably know what happens if the user inputs the right credentials and then presses "Cancel" ;-)19:10
afd_is this a formlib generated form?19:11
pyqwerNo, z3c.form.19:11
afd_maybe in the cancel action handler you clear a cookie19:12
afd_or... why don't you make the Cancel button be a reset button?19:12
pyqwerWell, yes that's what I also thought. I could also call the logout() function of my Credential plugin.19:12
afd_or you need it to redirect to a different page with it?19:13
pyqwerThe cancel button should also redirect ,right.19:13
pyqwerI use Zope3 for a mobile app, so I need this navigation as there are no menus.19:13
afd_I see19:13
pyqwerI also thought about writing my own SessionCredentials plugin and check if theres button.cancel in the request.19:14
pyqwerI probably have to write my own credential anyway for the cookie checking.19:14
*** J1m has joined #zope3-dev19:14
afd_I'd call credential_plugin.logout() in the action handler19:14
pyqwerYes, that's *maybe* an option.19:15
pyqwerBut there could be problems with the automatic redirection of the logout function.19:15
pyqwerIf my context is not accessible, it redirects me back to my login page.19:16
afd_logout can just erase some cookies, then redirect to a page. It doesn't have to enter circular redirection, if that's what you're afraid of19:17
*** ktwilight has quit IRC19:20
pyqwerafd_: Ok, thanks a lot! I'll quit for today and put these idea into action tomorrow!19:21
*** pyqwer has quit IRC19:22
*** agroszer_ has joined #zope3-dev19:22
*** markusleist has quit IRC19:28
*** jukart has quit IRC19:28
*** danielblackburn has joined #zope3-dev19:31
*** MJ has quit IRC19:32
*** goschtl has quit IRC19:36
*** harobed has quit IRC19:37
*** agroszer has quit IRC19:39
*** agroszer_ is now known as agroszer19:39
*** povbot has joined #zope3-dev19:46
*** sunew has joined #zope3-dev19:48
*** thruflo has quit IRC19:52
*** thruflo has joined #zope3-dev19:53
*** tarek has joined #zope3-dev19:53
*** sm has joined #zope3-dev19:54
*** tarek has quit IRC20:03
*** toutpt has quit IRC20:06
*** benji has quit IRC20:15
*** benji has joined #zope3-dev20:16
*** malthe has quit IRC20:18
*** sp0cksbeard has joined #zope3-dev20:22
*** MJ has joined #zope3-dev20:24
*** regebro has joined #zope3-dev20:29
*** afd_ has quit IRC20:38
*** mkerrin has quit IRC20:39
*** dunny has joined #zope3-dev20:40
*** jukart has joined #zope3-dev20:41
*** MJ has quit IRC20:42
*** reco is now known as reco|vudoskinnin20:45
*** reco|vudoskinnin is now known as reco|vudo20:46
*** stub has joined #zope3-dev20:54
*** danielblackburn has quit IRC21:02
*** benji has quit IRC21:04
*** nouri has quit IRC21:17
*** ktwilight has joined #zope3-dev21:19
*** danielblackburn has joined #zope3-dev21:46
*** quodt_ has quit IRC21:49
*** jukart has quit IRC21:50
*** d2m has quit IRC21:55
*** quodt has joined #zope3-dev22:04
*** benji has joined #zope3-dev22:06
*** agroszer has quit IRC22:07
*** pbugni has quit IRC22:09
*** pbugni has joined #zope3-dev22:09
*** alecm has joined #zope3-dev22:10
*** thruflo has quit IRC22:13
*** nouri has joined #zope3-dev22:14
*** stu1 has joined #zope3-dev22:14
*** stub has quit IRC22:14
*** stu1 is now known as stub22:14
*** stu1 has joined #zope3-dev22:18
*** stub has quit IRC22:18
*** stu1 is now known as stub22:18
*** stub has quit IRC22:23
*** sunew has quit IRC22:25
*** salfield has quit IRC22:31
*** nathany has quit IRC22:35
*** pbugni_ has joined #zope3-dev22:39
*** pbugni has quit IRC22:56
*** malthe has joined #zope3-dev23:05
*** reco|vudo has quit IRC23:22
*** ktwilight has quit IRC23:33
*** ktwilight has joined #zope3-dev23:33
*** lucielejard has quit IRC23:35
*** amit_am has left #zope3-dev23:44
*** reco has joined #zope3-dev23:45
*** RaFromBRC has quit IRC23:48
*** dunny has quit IRC23:54

Generated by 2.15.1 by Marius Gedminas - find it at!