1 2010-12-01T00:00:26  <ThomasWaldmann> sure, post url when you're ready
   2 2010-12-01T00:01:58  <moin2> http://paste.pocoo.org/show/298267/
   3 2010-12-01T00:04:01  <moin2> the set of conditionals might be able to be trimmed
   4 2010-12-01T00:04:13  <ThomasWaldmann> please show the complete function
   5 2010-12-01T00:05:11  <ThomasWaldmann> and don't call lists foo_list
   6 2010-12-01T00:05:31  *** nickr500 has joined #moin-dev
   7 2010-12-01T00:06:59  <ThomasWaldmann> moin2: that doesn't work correctly
   8 2010-12-01T00:07:47  *** nickr5 has quit IRC
   9 2010-12-01T00:08:53  <ThomasWaldmann> there are at least 3 bugs in there
  10 2010-12-01T00:08:58  <moin2> ok
  11 2010-12-01T00:11:17  <ThomasWaldmann> btw if you have trouble to find those, you could add unit tests
  12 2010-12-01T00:13:47  *** maker__ has quit IRC
  13 2010-12-01T00:14:42  <ThomasWaldmann> moin2: maybe start to get clear about what an item object is and what an item name is
  14 2010-12-01T00:16:08  <ThomasWaldmann> also, do not call dicts foo_list :)
  15 2010-12-01T00:16:20  <ThomasWaldmann> that is plain misleading
  16 2010-12-01T00:16:49  <ThomasWaldmann> reduce code duplication within your function
  17 2010-12-01T00:17:11  <ThomasWaldmann> line 10 and 13
  18 2010-12-01T00:22:26  <moin2> (current_rev.get(ITEMLINKS, [])) returns item names or item objects?
  19 2010-12-01T00:22:34  <ThomasWaldmann> names
  20 2010-12-01T00:23:08  <moin2> so all item linked_item and item calls need to use .name
  21 2010-12-01T00:23:10  <moin2> ?
  22 2010-12-01T00:23:48  <ThomasWaldmann> most of the stuff you have to do is just dealing with names
  23 2010-12-01T00:24:17  <ThomasWaldmann> but iteritems is giving you items, not names
  24 2010-12-01T00:24:58  <ThomasWaldmann> so just build a all_items list (with all item names) as first step
  25 2010-12-01T00:26:42  <ThomasWaldmann> and try to run your code more often
  26 2010-12-01T00:26:56  <ThomasWaldmann> you'll notice some bugs immediately
  27 2010-12-01T00:27:29  <ThomasWaldmann> you can either do that manually, using the wiki and a browser, or (better) write unit tests
  28 2010-12-01T00:27:49  <moin2> does the return template stay the same?
  29 2010-12-01T00:29:08  <ThomasWaldmann> you'll see that :)
  30 2010-12-01T00:29:32  <ThomasWaldmann> if you write java code at school, you run that code, don't you?
  31 2010-12-01T00:30:30  <moin2> yeah, but it simply comes out of the ide
  32 2010-12-01T00:30:53  <moin2> i hope else if -> elif was one of the bugs :)
  33 2010-12-01T00:31:29  <ThomasWaldmann> no :)
  34 2010-12-01T00:33:11  <ThomasWaldmann> btw, did you do some python tutorial already or read some python (online) book?
  35 2010-12-01T00:36:17  <moin2> i did a rough tutorial
  36 2010-12-01T00:43:02  <moin2> but what do i do for the return statement, i'm not seeing the links
  37 2010-12-01T00:46:21  <moin2> are there supposed to be many wanted items?
  38 2010-12-01T00:55:18  <moin2> hello, are you there??
  39 2010-12-01T00:56:57  <ThomasWaldmann> you should create some test pages
  40 2010-12-01T01:18:13  <moin2> i think it works
  41 2010-12-01T01:19:22  <moin2> i have run through the actual items in the wiki and checked to what wanted items they link to
  42 2010-12-01T01:19:41  <moin2> i still don't know what to put in the return statement though
  43 2010-12-01T01:22:01  <ThomasWaldmann> don't "think it works", try it
  44 2010-12-01T01:22:19  <ThomasWaldmann> and remember, you have working orphans code, that is rather similar
  45 2010-12-01T01:22:39  <moin2> what should i return in the last parameter in the render_template
  46 2010-12-01T01:22:41  <ThomasWaldmann> of course your code and your template has to deal with the source items lists
  47 2010-12-01T01:23:18  <ThomasWaldmann> parameters pass something, not return something
  48 2010-12-01T01:23:57  <ThomasWaldmann> and of course you give the dict you have built to the template and change the template code accordingly
  49 2010-12-01T01:24:16  <moin2> how do i change the template code
  50 2010-12-01T01:30:32  <ThomasWaldmann> with an editor
  51 2010-12-01T01:32:48  <moin2> i'll be back later or tomorrow
  52 2010-12-01T01:32:51  *** moin2 has quit IRC
  53 2010-12-01T04:16:24  *** jordonwii has joined #moin-dev
  54 2010-12-01T04:17:12  <jordonwii> Greetings
  55 2010-12-01T04:17:28  *** GCIBot has quit IRC
  56 2010-12-01T04:17:41  *** GCIBot has joined #moin-dev
  57 2010-12-01T04:21:06  <jordonwii> Err, moin =)
  58 2010-12-01T05:20:02  *** kursor has joined #moin-dev
  59 2010-12-01T05:50:40  *** nickr500 has quit IRC
  60 2010-12-01T06:07:54  *** jordonwii has quit IRC
  61 2010-12-01T07:47:43  <dreimark> moin
  62 2010-12-01T07:56:35  *** kursor has quit IRC
  63 2010-12-01T08:02:50  <pvinogradov> ThomasWaldmann: I create hashes with this script http://bpaste.net/show/11799/
  64 2010-12-01T08:03:15  <pvinogradov> ThomasWaldmann: I'm already fix space in comments
  65 2010-12-01T08:06:54  <pvinogradov> ThomasWaldmann: And use py.test.skip to skip test_auth_with_des_stored_password test if crypt module not provided
  66 2010-12-01T08:18:48  <dreimark> pvinogradov: look at MoinMoin/_template
  67 2010-12-01T08:21:04  <dreimark> if it is used to create hashes for tests, can this be added to _tests.__init__ ?
  68 2010-12-01T08:29:04  *** gwork has joined #moin-dev
  69 2010-12-01T09:21:20  <dreimark> TheSheep: just finished http://moinmo.in/EasyToDo/make%20an%20alternate%20stylesheet/Green%20on%20Black%20Style
  70 2010-12-01T09:32:44  <dreimark> bbl
  71 2010-12-01T10:04:19  *** Kapace has quit IRC
  72 2010-12-01T10:21:41  *** rfw has quit IRC
  73 2010-12-01T10:59:44  <ThomasWaldmann> pvinogradov: the reason why these hashes were added was to easy migration from apache htpasswd iirc
  74 2010-12-01T11:00:04  <ThomasWaldmann> so could you check place if that gives sames hashes?
  75 2010-12-01T11:00:27  <ThomasWaldmann> s/place/please/ %-)
  76 2010-12-01T11:01:56  *** greg_f has joined #moin-dev
  77 2010-12-01T11:46:32  <CIA-62> pavel_vinogradov default * 5742:dde52ccbb1e3 1.9/MoinMoin/_tests/test_user.py: fix the comments so they look like: # foo not like: #foo
  78 2010-12-01T11:46:34  <CIA-62> pavel_vinogradov default * 5743:abcfaf27a11a 1.9/MoinMoin/_tests/test_user.py: Skip test test_auth_with_des_stored_password if platform don't provide crypt module
  79 2010-12-01T13:10:44  <ThomasWaldmann> re
  80 2010-12-01T13:18:55  * ThomasWaldmann plays with the clouds background
  81 2010-12-01T13:23:53  <CIA-62> Thomas Waldmann <tw AT waldmann-edv DOT de> default * 10122:c6fc4343e671 2.0-dev/MoinMoin/themes/modernized/static/ (css/screen.css img/white_clouds.png): white clouds background image for modernized theme (thanks to jbills, GCI 2010)
  82 2010-12-01T13:25:59  <ThomasWaldmann> nice, bg image is 2000px wide, so should be enough for most displays
  83 2010-12-01T13:40:16  * ThomasWaldmann works on HHH :)
  84 2010-12-01T13:43:30  <CIA-62> Thomas Waldmann <tw AT waldmann-edv DOT de> default * 10123:927884423740 2.0-dev/MoinMoin/ (9 files in 8 dirs): preparation for autoescape mode - marked all places that insert html into output with HHH (thanks to Roboraider, GCI 2010)
  85 2010-12-01T13:46:57  <ThomasWaldmann> bbl
  86 2010-12-01T14:26:42  *** m4k3r has joined #moin-dev
  87 2010-12-01T15:04:01  <pvinogradov> ThomasWaldmann: Can you explain suggestion about password hashes?
  88 2010-12-01T15:04:18  <ThomasWaldmann> please ask more precisely
  89 2010-12-01T15:06:45  <pvinogradov> Did you want to include hashes generation into _tests.__init__ ?
  90 2010-12-01T15:07:23  *** maker__ has joined #moin-dev
  91 2010-12-01T15:07:48  *** m4k3r has quit IRC
  92 2010-12-01T15:07:55  <ThomasWaldmann> pvinogradov: would be nice
  93 2010-12-01T15:08:18  <ThomasWaldmann> esp. if you create the expected hash data with htpasswd
  94 2010-12-01T15:09:42  <pvinogradov> To create hashes i use code from User._validatePassword
  95 2010-12-01T15:10:06  <pvinogradov> but i don't see any problems in adding it to __init__
  96 2010-12-01T15:13:28  <ThomasWaldmann> ehrm, if you want to test something, it should be in a test method
  97 2010-12-01T15:46:55  *** kursor has joined #moin-dev
  98 2010-12-01T16:09:21  *** achshar has joined #moin-dev
  99 2010-12-01T16:18:23  *** achshar has left #moin-dev
 100 2010-12-01T16:40:31  *** gwork has quit IRC
 101 2010-12-01T16:43:13  <dreimark> re
 102 2010-12-01T16:52:00  <pvinogradov> ThomasWaldmann, dreimark: Did you like such solution for password hashes? : http://bpaste.net/show/11813/
 103 2010-12-01T16:58:01  <ThomasWaldmann> hmm, i have rather thought of running htpasswd with that password (once, interactively, for the different hashes)
 104 2010-12-01T16:58:15  <ThomasWaldmann> and then use the generated hashes in the tests
 105 2010-12-01T16:58:38  <ThomasWaldmann> to check if our code creates the same hash
 106 2010-12-01T16:58:38  <pvinogradov> Windows don't have htpasswd by default
 107 2010-12-01T16:58:59  <ThomasWaldmann> doesn't apache provide one for windows?
 108 2010-12-01T16:59:20  <pvinogradov> provide, but user must intall apache before
 109 2010-12-01T16:59:30  <ThomasWaldmann> user = you
 110 2010-12-01T16:59:36  <ThomasWaldmann> this is only done once
 111 2010-12-01T16:59:48  <ThomasWaldmann> you just copy the resulting string to the tests
 112 2010-12-01T17:00:14  <ThomasWaldmann> and put a comment right to the hash telling # generated from password 12345 by htpasswd
 113 2010-12-01T17:00:27  <pvinogradov> i'm finally understand you
 114 2010-12-01T17:00:54  <ThomasWaldmann> because what your code currently is testing is somehow md5crypt against md5crypt
 115 2010-12-01T17:01:11  <ThomasWaldmann> even if that would be plain wrong, it would likely generate same output for same input
 116 2010-12-01T17:01:40  <ThomasWaldmann> you have htpasswd on your machine?
 117 2010-12-01T17:02:05  <pvinogradov> i have access to linux machine
 118 2010-12-01T17:02:23  <ThomasWaldmann> ok.
 119 2010-12-01T17:02:42  <ThomasWaldmann> # User don't require to be valid
 120 2010-12-01T17:02:58  <ThomasWaldmann> btw, while you are working on that file, check the grammar of this.
 121 2010-12-01T17:03:42  <ThomasWaldmann> is it "User is not required to be valid" maybe?
 122 2010-12-01T17:03:51  *** Kapace has joined #moin-dev
 123 2010-12-01T17:04:08  <pvinogradov> sorry, i'm not native english speaker and made many mistake
 124 2010-12-01T17:04:38  <ThomasWaldmann> iirc that was there before you started, so maybe not your fault (except copying it :)
 125 2010-12-01T17:04:55  * ThomasWaldmann is neither btw, but i read a lot on the internet
 126 2010-12-01T17:06:16  <ThomasWaldmann> dreimark: the item transclusion thing needs thorough review, I'll try to do it later, so no early close please, just comments
 127 2010-12-01T17:20:51  <dreimark> ThomasWaldmann: ok, same opinion
 128 2010-12-01T17:33:07  <pvinogradov> i'm generate hashes for apr1 and des, but can't find tool for MD5
 129 2010-12-01T17:36:33  <TheSheep> pvinogradov: http://docs.python.org/library/md5.html
 130 2010-12-01T17:36:53  <TheSheep> hmm, deprecated
 131 2010-12-01T17:44:25  <ThomasWaldmann>  -m  Force MD5 encryption of the password.
 132 2010-12-01T17:44:33  <ThomasWaldmann> that's what my htpasswd tells
 133 2010-12-01T17:46:04  <ThomasWaldmann> foo:$apr1$u6YI44zq$eBKvjrClLi.f2Vf4qIpPM.
 134 2010-12-01T17:46:13  <ThomasWaldmann> that's what it outputs for 12345
 135 2010-12-01T17:47:15  <ThomasWaldmann> baz:{SHA}jLIjfQZ5yojbZGTqxg2pY0VROWQ=
 136 2010-12-01T17:47:19  <ThomasWaldmann> sha ^^
 137 2010-12-01T17:47:42  <ThomasWaldmann> boo:7Jq4mQZYQ8x4c
 138 2010-12-01T17:47:45  <ThomasWaldmann> crypt ^^
 139 2010-12-01T17:48:23  <ThomasWaldmann> http://moinmo.in/EasyToDo/autoescaping%20with%20jinja2%20-%20fix%20code%20and%20templates please review - is it hard or medium?
 140 2010-12-01T17:57:57  <pvinogradov> ThomasWaldmann: output of htpasswd -m don't match with result of md5crypt.unix_md5_crypt
 141 2010-12-01T17:58:06  <pvinogradov> with same salt
 142 2010-12-01T18:00:21  <ThomasWaldmann> hm, can you check the User code?
 143 2010-12-01T18:10:59  <ThomasWaldmann> http://moinmo.in/EasyToDo/make%20file%20upload%20more%20comfortable please review
 144 2010-12-01T18:20:08  <pvinogradov> ThomasWaldmann: what i can find in User code? I read code and see call to  unix_md5_crypt from support.md5crypt
 145 2010-12-01T18:20:49  <pvinogradov> according to comments - this is implementation of old FreeBSD md5crypt implementation
 146 2010-12-01T18:21:15  <pvinogradov> and not compatible with new md5 implementation: "unix_md5_crypt() provides a crypt()-compatible interface to the rather new MD5-based crypt() function found in modern operating systems."
 147 2010-12-01T18:24:13  <ThomasWaldmann> pvinogradov: those additional hashes were added by a moin user to ease migration from apache (iirc)
 148 2010-12-01T18:24:33  <ThomasWaldmann> so either he had a different goal, or it was not tested, no idea :)
 149 2010-12-01T18:24:50  <ThomasWaldmann> would be nice to have something that makes sense in the end.
 150 2010-12-01T18:26:11  <pvinogradov> i can use MD5 test hash created with help of unix_md5_crypt from support.md5crypt
 151 2010-12-01T18:26:45  <ThomasWaldmann> yeah, no surprise (see above :)
 152 2010-12-01T18:33:36  <pvinogradov> it seems like i fix all suggestion about password test code in 1.9 tree
 153 2010-12-01T18:41:07  <ThomasWaldmann> yeah. if you can't clear up the md5 stuff easily, proceed to porting it to moin2.
 154 2010-12-01T19:23:15  *** rfw has joined #moin-dev
 155 2010-12-01T19:24:38  *** greg_f has quit IRC
 156 2010-12-01T19:24:54  *** kursor has quit IRC
 157 2010-12-01T20:55:00  *** achshar has joined #moin-dev
 158 2010-12-01T20:55:34  <achshar> hello
 159 2010-12-01T20:57:33  <achshar> :-D
 160 2010-12-01T21:00:45  *** achshar has left #moin-dev
 161 2010-12-01T21:04:00  *** m4k3r has joined #moin-dev
 162 2010-12-01T21:04:28  *** maker__ has quit IRC
 163 2010-12-01T21:16:20  *** achshar has joined #moin-dev
 164 2010-12-01T21:27:24  <dreimark> re
 165 2010-12-01T21:37:06  *** achshar has left #moin-dev
 166 2010-12-01T22:10:38  *** m4k3r has quit IRC
 167 2010-12-01T22:11:08  *** m4k3r has joined #moin-dev
 168 2010-12-01T22:34:10  *** blathijs_ has quit IRC
 169 2010-12-01T22:34:20  *** blathijs has joined #moin-dev
 170 2010-12-01T23:12:06  <ThomasWaldmann> re
 171 2010-12-01T23:12:39  <ThomasWaldmann> btw, our xapian-indexer script eats increasing amount of memory
 172 2010-12-01T23:24:19  <m4k3r> ThomasWaldmann:  is the ldap authentication support already completed?
 173 2010-12-01T23:27:32  <ThomasWaldmann> m4k3r: what exactly are you referring to?
 174 2010-12-01T23:27:59  <m4k3r> MoinMoin.auth.ldap_login.
 175 2010-12-01T23:28:44  <m4k3r> Not the file, active directory authentication support.
 176 2010-12-01T23:29:59  <ThomasWaldmann> it works in 1.9, 2.0 state unknown
 177 2010-12-01T23:33:23  <m4k3r> ThomasWaldmann:  seems like ldap authentication support only convers the file ldap_login in MoinMoin/auth. Any template file, any binding config with the rest of the code.
 178 2010-12-01T23:33:51  <m4k3r> s/any/no/g
 179 2010-12-01T23:35:08  <ThomasWaldmann> 1.9 has also new ldap groups support
 180 2010-12-01T23:35:24  <ThomasWaldmann> (separate repo, needs more work/review)
 181 2010-12-01T23:36:25  <m4k3r> ThomasWaldmann:  I'm talking strictly about ldap for 2.x. I took a look at that becouse I suppose openids support would get a similar structure.
 182 2010-12-01T23:40:32  <ThomasWaldmann> well, options for openid are either to use flask-openid or use openid code from 1.9 and port it to moin2
 183 2010-12-01T23:45:37  <m4k3r> ThomasWaldmann:  yep, but I first have to get an idea about how moinmoin 2.x handles authentications.
 184 2010-12-01T23:47:13  <ThomasWaldmann> it should work similar to 1.9 currently
 185 2010-12-01T23:47:34  <ThomasWaldmann> see MoinMoin/__init__.py, MoinMoin/auth/*
 186 2010-12-01T23:50:18  <m4k3r> ThomasWaldmann:  there's something also on MoinMoin.support.pygments.lexers. What about it?
 187 2010-12-01T23:51:06  <ThomasWaldmann> you need to ask more precisely
 188 2010-12-01T23:52:35  <m4k3r> On MoinMoin/support/pygments/lexers/_phpbuiltins.py there is something like a dict with key "LDAP" and as value a list of methods(?).
 189 2010-12-01T23:54:18  <m4k3r> Seems like it is automatically generated, since there is a "Do not alter the MODULES dict by hand!" warning at the top.

MoinMoin: MoinMoinChat/Logs/moin-dev/2010-12-01 (last edited 2010-11-30 23:45:02 by IrcLogImporter)