2007-01-09T00:03:18  <dreimark> http://test.wikiwikiweb.de/GuiTest shows gots some new examples
2007-01-09T00:04:01  <dreimark> the subpage and http with and without imagelink is solved
2007-01-09T00:11:00  <dreimark> now attachment: is always translated in to ImageLink, let me know if this isn't wanted
2007-01-09T07:39:53  <dreimark> my latest change text_html_text_moin_wiki checks no if an attachment or http image source was scaled
2007-01-09T07:40:25  <dreimark> ThomasWaldmann:there is a bug in ?action=raw
2007-01-09T07:41:12  <dreimark> it gets the latest-1 version
2007-01-09T07:41:56  <dreimark> and not the current one
2007-01-09T07:44:29  <dreimark> I have added some more examples on test.wiki...
2007-01-09T07:45:43  <dreimark> if that is ready for use now I can check how to proceed with EmbedObject width and height
2007-01-09T07:49:28  <dreimark> MoinMoin page broken http://moinmoin.wikiwikiweb.de/MoinMoinExtensions?action=info
2007-01-09T10:20:43  <ThomasWaldmann> dreimark: i removed the non-utf8 stuff from that edit-log
2007-01-09T10:21:16  <dreimark> ok
2007-01-09T10:21:38  <dreimark> canyou add my last changes to the test wiki
2007-01-09T10:22:54  <ThomasWaldmann> done
2007-01-09T10:24:18  <dreimark> :)
2007-01-09T10:25:03  <ThomasWaldmann> the raw bug, is it in 1.5 or 1.6?
2007-01-09T10:25:52  <dreimark> in 1.6
2007-01-09T10:28:10  <dreimark> arrgh, that upload line goes wrong I hope that's the last bug in gedit#
2007-01-09T10:31:26  <ThomasWaldmann> dreimark: give me a url where i see the raw bug
2007-01-09T11:13:04  <dreimark> http://test.wikiwikiweb.de/GuiTest?action=raw&rev=25#preview
2007-01-09T11:13:18  <dreimark> The revision is wrong actual is 26
2007-01-09T11:14:10  <dreimark> it's only if you use the action menu on this page
2007-01-09T11:14:28  <dreimark> if you write ?action behind that page it's ok
2007-01-09T11:39:16  <ThomasWaldmann> dreimark: keeping the rev no is a feature, not a bug
2007-01-09T12:22:51  <dreimark> ThomasWaldmann:if you use the action menu for raw text you like to have the actual raw text and not the one before
2007-01-09T12:23:03  <dreimark> the revision number needs to be the right one
2007-01-09T12:23:45  <dreimark> If you now alter in testwiki a page and go to the action raw text you don't see your changes in raw
2007-01-09T12:41:51  <ThomasWaldmann> dreimark: go to action=info, display rev 2 of the page, then go to menu and do raw action -> raw of that page, rev 2
2007-01-09T12:42:05  <ThomasWaldmann> dreimark: go to action=info, display rev 3 of the page, then go to menu and do raw action -> raw of that page, rev 3
2007-01-09T12:48:39  <ThomasWaldmann> but you are right, on the #preview screen, it seems to get the wrong rev number
2007-01-09T13:06:23  <dreimark> :)
2007-01-09T17:09:26  <ThomasWaldmann> parsley: welcome :)
2007-01-09T17:09:31  <parsley> thx ;-)
2007-01-09T17:09:37  <parsley> here's where I am:
2007-01-09T17:09:46  <parsley> I've clicked 'login', and pdb has come up
2007-01-09T17:09:58  <parsley> after some digging, I find this disturbing:
2007-01-09T17:10:05  <parsley> (Pdb) p self.user
2007-01-09T17:10:05  <parsley> <MoinMoin.user.User at 0x2aa07582d8 name:'' id:1168358967.81.55003 valid:0>
2007-01-09T17:10:18  <xorAxAx> ah, the repr?
2007-01-09T17:10:25  <xorAxAx> parsley: 1.6 wont show it
2007-01-09T17:10:42  <parsley> what's a repr?
2007-01-09T17:10:49  <xorAxAx> it automatically knows which information is secret and which not
2007-01-09T17:11:08  <xorAxAx> repr==representation. thats the strings that describe what an object is
2007-01-09T17:11:13  <xorAxAx> used for debugging etc.
2007-01-09T17:11:21  <parsley> ah ok, thanks
2007-01-09T17:11:34  <ThomasWaldmann> parsley: can you trace through the ldap stuff?
2007-01-09T17:12:22  <xorAxAx> parsley: or do you mean that '' is the problem?
2007-01-09T17:12:25  <xorAxAx> i was thinking about the id
2007-01-09T17:12:30  <ThomasWaldmann> still using 1.5.6 and the original ldap plugin?
2007-01-09T17:12:36  <xorAxAx> it will allow everybody who reads the irc logs to loging
2007-01-09T17:12:39  <parsley> ThomasWaldmann, not sure how; pdb starts at RequestModPy.run
2007-01-09T17:12:40  <xorAxAx> s/g$//
2007-01-09T17:13:02  <parsley> ThomasWaldmann, actually, this is 1.5.6 w/ backport patch from 1.6
2007-01-09T17:13:25  <parsley> if you remember, I backported 1.6 code because 1.5+ was storing the ldap password hash
2007-01-09T17:13:40  <ThomasWaldmann> ah, ok
2007-01-09T17:14:47  * ThomasWaldmann isnt used to pdb debugging
2007-01-09T17:15:25  <parsley> ah - is there a better way?  seems pretty handy...
2007-01-09T17:15:27  <ThomasWaldmann> maybe you can either put breakpoints at the interesting places or just use some logging?
2007-01-09T17:15:52  <parsley> I'll probably have to use some logging
2007-01-09T17:16:30  <parsley> I've got to run to lunch, and unfortunately I've actual work to do when I return :-/
2007-01-09T17:16:30  <ThomasWaldmann> the first thing to find out is whether your ldap plugin gets called after hitting login button
2007-01-09T17:16:55  <ThomasWaldmann> we can also proceed at another time, no problem
2007-01-09T17:17:58  <parsley> ThomasWaldmann, ok, it looks like that sequence of events starts in RequestBase.__init__, at self.user = self.get_user_from_form()
2007-01-09T17:18:18  <ThomasWaldmann> yeah
2007-01-09T17:19:46  <parsley> ok; I may need to insert that line in the RequestBase.run() function, so I can trace into it
2007-01-09T17:20:00  <parsley> because I tried running it in the debugger:
2007-01-09T17:20:13  <parsley> (Pdb) self.user = self.get_user_from_form()
2007-01-09T17:20:13  <parsley> (Pdb) p self.user
2007-01-09T17:20:13  <parsley> <MoinMoin.user.User at 0x2aa07582d8 name:'' id:1168358967.81.55003 valid:0>
2007-01-09T17:20:37  <parsley> ok, I'll start there when I get back to this
2007-01-09T17:21:43  <ThomasWaldmann> maybe you have to debug the real cgi stuff that interacts with the users browser
2007-01-09T17:22:08  <ThomasWaldmann> i dont know if this can work with pdb, maybe rather use a log file / print / whatever
2007-01-09T17:23:38  <ThomasWaldmann> btw, maybe using fastcgi would also solve that problem (in case it is caused by mod_python)
2007-01-09T17:24:41  <parsley> is fastcgi more tested, or just more reliable?
2007-01-09T17:25:26  <ThomasWaldmann> i guess both
2007-01-09T17:25:52  <ThomasWaldmann> the main issue of mod_python is that it runs everything under the same userid
2007-01-09T17:26:14  <ThomasWaldmann> and, depending on the version of it, we had to do some strange workarounds
2007-01-09T17:27:13  <parsley> mainly, I'm trying to avoid too much stuff that doesn't ship w/ RHEL4
2007-01-09T17:27:29  <parsley> RHEL4 ships w/ mod_python, but not fastcgi
2007-01-09T17:27:54  <ThomasWaldmann> maybe you could also reverse proxy to a standalone moin
2007-01-09T17:28:15  <ThomasWaldmann> depends on the load you expect
2007-01-09T17:28:34  <parsley> pretty light load; I just want good responsiveness
2007-01-09T17:28:55  <parsley> cgi is noticeably slow loading some pages, like indexes
2007-01-09T17:29:22  <ThomasWaldmann> yeah, it restarts everything on every request
2007-01-09T17:29:38  <parsley> yup :-(
2007-01-09T17:29:45  <parsley> ok, I gotta head to lunch...
2007-01-09T17:29:47  <parsley> later
2007-01-09T17:29:56  <ThomasWaldmann> cu
2007-01-09T19:08:03  <parsley> ThomasWaldmann, ok, I'm back for a bit; you around?
2007-01-09T19:09:57  <parsley> I'm confused by this bit of code in class RequestBase:
2007-01-09T19:10:20  <parsley> def get_user_default_unknown(self, **kw):
2007-01-09T19:10:20  <parsley> (Pdb) l
2007-01-09T19:10:20  <parsley> 541             u = self.get_user_default_unknown(name=name, password=password,
2007-01-09T19:10:20  <parsley> 542                                               login=login, logout=logout,
2007-01-09T19:10:20  <parsley> 543                                               user_obj=None)
2007-01-09T19:10:21  <parsley> 544             return u
2007-01-09T19:11:12  <parsley> erm - that didn't paste quite how I wanted...
2007-01-09T19:12:04  <parsley> but basically, get_user_default_unknown is called with name=name, password=password, etc...; but it's defined as get_user_default_unknown(self, **kw)
2007-01-09T19:15:54  <xorAxAx> maybe the function name is missing the word "to"?
2007-01-09T19:17:00  <parsley> xorAxAx, I don't follow you?
2007-01-09T19:17:27  <xorAxAx> i mean, obviously that function is used to generate the user object
2007-01-09T19:17:41  <xorAxAx> and it seems to default _to_ unknown
2007-01-09T19:18:12  <parsley> right
2007-01-09T19:18:27  <parsley> but what's **kw?
2007-01-09T19:18:54  <parsley> do the name=, password=, etc. arguments somehow get translated by python into a **kw dictionary or something?
2007-01-09T19:18:58  <xorAxAx> yes
2007-01-09T19:19:05  <xorAxAx> keyword arguments, its called
2007-01-09T19:19:14  <parsley> ah - I'm kinda green w/ python
2007-01-09T19:19:50  <xorAxAx> but its nearly intuitive, right? :)
2007-01-09T19:20:29  <parsley> that's why I like python so much - pretty readable even if you don't really know it that well ;-)
2007-01-09T19:32:07  <parsley> ok, found something
2007-01-09T19:32:22  <parsley> in l.simple_bind_s(ldap_binddn.encode(coding), ldap_bindpw.encode(coding))
2007-01-09T19:32:24  <parsley> I get:
2007-01-09T19:32:36  <parsley> ENCODING_ERROR: <ldap.ENCODING_ERROR instance at 0x2aa0775b48>
2007-01-09T19:33:34  <parsley> and from there it skips to the 'except' clause
2007-01-09T19:34:05  <parsley> coding = 'utf-8'
2007-01-09T19:59:03  <parsley> ok, it's not the ldap_binddn.encode() (or bindpw)
2007-01-09T20:00:33  <parsley> it happens in ldap libs, here:
2007-01-09T20:00:36  <parsley> > /usr/lib64/python2.3/site-packages/ldap/ldapobject.py(94)_ldap_call()
2007-01-09T20:00:36  <parsley> -> result = func(*args,**kwargs)
2007-01-09T20:00:36  <parsley> (Pdb) s
2007-01-09T20:00:36  <parsley> ENCODING_ERROR: {'desc': 'Encoding error'}
2007-01-09T21:11:58  <ThomasWaldmann> parsley: found the problem?
2007-01-09T21:16:07  <ThomasWaldmann> maybe your ldap server doesnt like utf-8?
2007-01-09T21:16:57  <ThomasWaldmann> otoh, did you have any non-ASCII character in your username or password?
2007-01-09T21:25:51  <ThomasWaldmann> parsley: hmm, this likely has nothing to do with character encodings, but maybe your binddn is invalid
2007-01-09T21:26:03  <ThomasWaldmann> check for typos
2007-01-09T21:55:12  <parsley> ThomasWaldmann, it's something deeper - all the same values work fine w/ run as CGI
2007-01-09T21:56:44  <ThomasWaldmann> do you have other ldap stuff loaded in apache?
2007-01-09T21:57:09  <parsley> hrm... maybe so
2007-01-09T21:57:30  <parsley> lemme see if mod_authz_ldap is loaded...
2007-01-09T21:58:17  <parsley> ThomasWaldmann, yeah, apache is loading mod_ldap and mod_auth_ldap...
2007-01-09T21:58:28  <parsley> I'll try commenting those out
2007-01-09T21:59:09  <ThomasWaldmann> maybe different versions of the ldap libs were used to build that stuff
2007-01-09T21:59:57  <parsley> no joy
2007-01-09T22:00:39  <ThomasWaldmann> did you kill everything moin/apache before retrying?
2007-01-09T22:00:45  <parsley> hrm... apache links directly to libldap
2007-01-09T22:01:01  <parsley> yeah, http was completely stopped
2007-01-09T22:03:03  <parsley> interesting; the python _ldap.so links to: libldap_r-2.2.so.7 => /usr/lib64/libldap_r-2.2.so.7
2007-01-09T22:03:20  <parsley> but apache links to: libldap-2.2.so.7 => /usr/lib64/libldap-2.2.so.7
2007-01-09T22:03:35  <parsley> note the _r in the python linking
2007-01-09T22:04:36  <ThomasWaldmann> my apache2 uses _r
2007-01-09T22:04:45  <ThomasWaldmann> (whatever that means)
2007-01-09T22:06:04  <parsley> reentrant?
2007-01-09T22:06:06  <parsley> *shrug*
2007-01-09T22:07:30  <ThomasWaldmann> do you have both in lib64/ ?
2007-01-09T22:08:43  <parsley> yes
2007-01-09T22:09:16  <parsley> but it wouldn't be able to load both at once in the same process space, eh?  wouldn't it cause conflicting symbols?
2007-01-09T22:10:32  <parsley> you know - maybe I'll just use auth.http and sidestep the whole issue
2007-01-09T22:11:22  <parsley> wouldn't that also prevent password hashes from being stored in the profile, thus obviating the need for my backported patch?
2007-01-09T22:14:41  <ThomasWaldmann> i think so, but you wont be able to get email from ldap
2007-01-09T22:15:34  <ThomasWaldmann> parsley: is this centos?
2007-01-09T22:18:04  <parsley> no, true blue RHEL4
2007-01-09T22:18:10  <parsley> we have a site license
2007-01-09T22:18:41  <ThomasWaldmann> http://www.centos.org/modules/newbb/viewtopic.php?viewmode=thread&topic_id=658&forum=27&post_id=1840 maybe check your symlinks?
2007-01-09T22:20:49  <parsley> nope, the only dangling symlink is /usr/lib64/X11
2007-01-09T22:22:08  <parsley> ThomasWaldmann, you know, I was kind of worried that the new ldap stuff in 1.5.7 might break my backport patch, as well - from a maintainability standpoint, I'm probably better off using auth.http
2007-01-09T22:23:15  <ThomasWaldmann> if that's enough for you, sure.
2007-01-09T22:23:22  <ThomasWaldmann> alternatively try fcgi
2007-01-09T22:27:44  <parsley> ThomasWaldmann, yeah; anyway, thanks a lot for the help.  Given that this doesn't appear to be a MoinMoin bug, I'll just add some notes to the bug I filed and close it
2007-01-09T22:29:07  <ThomasWaldmann> yeah

MoinMoin: MoinMoinChat/Logs/moin-dev/2007-01-09 (last edited 2007-10-29 19:10:51 by localhost)