Friday, 2009-05-15

*** tpb has joined #melange00:00
*** tansell_laptop has quit IRC00:41
*** dmitrig01|afk has quit IRC00:45
*** dmitrig01|afk has joined #melange00:47
*** ChanServ sets mode: +v dmitrig01|afk00:47
*** arvind_khadri has joined #melange01:13
*** dmitrig01|afk has quit IRC01:43
*** dbentley-laptop has quit IRC01:54
*** mithro has joined #melange02:05
*** ChanServ sets mode: +v mithro02:05
*** forever has joined #melange02:26
*** arvind_khadri has quit IRC02:50
*** solydzajs has joined #melange03:17
*** ChanServ sets mode: +o solydzajs03:17
*** solydzajs has quit IRC03:23
*** solydzajs has joined #melange03:23
*** ChanServ sets mode: +o solydzajs03:23
*** SRabbelier has joined #melange03:29
*** ChanServ sets mode: +o SRabbelier03:29
*** mithro has quit IRC04:26
*** Merio has joined #melange05:00
*** ankitg has quit IRC05:36
*** SRabbelier has quit IRC06:09
*** SRabbelier1 has joined #melange06:10
*** SRabbelier1 is now known as SRabbelier06:11
*** ChanServ sets mode: +o SRabbelier06:11
*** jbailey has quit IRC06:20
*** jbailey has joined #melange06:20
*** irc.freenode.net sets mode: +o jbailey06:20
*** ankitg has joined #melange06:33
*** florinciu has joined #melange06:58
*** madrazr has joined #melange08:06
*** mithro has joined #melange08:18
*** ChanServ sets mode: +v mithro08:18
madrazrSRabbelier: Hi08:38
SRabbeliermadrazr: heya!08:38
madrazrSRabbelier: I have a question :P08:40
SRabbeliermadrazr: ask away08:40
madrazrSRabbelier: Say I have a model and I create 2 instances of that model and store those instances in the data store08:40
SRabbeliermadrazr: sure08:40
madrazrSRabbelier: one instance will have values for all the properties, where as the 2nd instance will have values for just 20% of the properties (as in if there are 10 properties, it holds values for just 2)08:41
SRabbeliermadrazr: assuming those values are not required, ok08:41
madrazrwill the 2nd instance consume less storage space in the data store?08:41
madrazrSRabbelier: yeah08:41
SRabbeliermadrazr: hmmmm, yes, I do think it could consume less space, but in practice it'll probably be negligable, why?08:43
SRabbeliermadrazr: 0.47 of 602.00 GBytes08:43
SRabbeliermadrazr: we have quite a bit of storage space left :P08:43
madrazrSRabbelier: ROFL! :D08:44
madrazrSRabbelier: For GHOP tasks we are planning to store the entire history of a task08:45
SRabbeliermadrazr: aye08:45
madrazrSRabbelier: I was thinking of storing them as ChangeSets08:45
madrazrSRabbelier: ?08:45
SRabbeliermadrazr: mhhh, that's an option08:45
madrazrSRabbelier: Lennie also suggested, storing the change as a single field and parsing this field to obtain the history08:48
SRabbeliermadrazr: as a JSON string?08:48
madrazrSRabbelier: can you suggest something?08:48
madrazrSRabbelier: yeah thats possible08:48
SRabbeliermadrazr: that would make gathering statistics harder and easier at the same time08:48
madrazrSRabbelier: easier?08:49
SRabbeliermadrazr: e.g., you can't find out in one query how many students have completed a task, but you can gather _all_ statistics in one go very easily08:49
madrazrSRabbelier: Oh yeah08:51
madrazrSRabbelier: which of these 2 kinds are more often?08:51
SRabbeliermadrazr: mhhh, I think the latter08:52
madrazrSRabbelier: Ok08:52
*** forever has quit IRC10:03
*** solydzajs has quit IRC10:21
*** dr__house has joined #melange10:52
*** dr__house has quit IRC11:01
*** dr__house has joined #melange11:02
madrazrSRabbelier: what should scope_path contain if I have to create a dummy organization entity?11:13
madrazrSRabbelier: this question is in context of writing organization logic test11:13
SRabbeliermadrazr: the scope of some test program11:17
madrazrSRabbelier: sorry, was on a call :(11:30
SRabbeliermadrazr: np11:31
madrazrSRabbelier: so it can be some arbitrary string? or should I create a program too?11:31
SRabbeliermadrazr: no, it should be the key name of a program entity (sorry, not scope)11:31
SRabbeliermadrazr: might be good to re-use some code from seed_db to create what you need11:32
madrazrSRabbelier: Ok11:32
*** dr__house has quit IRC11:39
*** dr__house has joined #melange11:39
*** florinciu has quit IRC12:05
*** dr__house has quit IRC12:29
*** dr__house has joined #melange12:30
*** Merio has quit IRC12:52
madrazrSRabbelier: how do I run the tests I have added now?13:03
SRabbeliermadrazr: ./run.py13:11
madrazrSRabbelier: did the same, but I get this error, "nose.config.ConfigError: Error reading config file 'setup.cfg': no such option 'cover-html-dir'"13:12
SRabbeliermadrazr: you need to install nose 0.1113:12
madrazrSRabbelier: ah Ok13:12
SRabbeliermadrazr: easy_install nose=0.1113:12
madrazrI have install 0.10 from repos13:12
madrazrSRabbelier: will install it13:12
SRabbeliermadrazr: mind updating the wiki13:13
SRabbelier?13:13
madrazrSRabbelier: I will do it13:13
SRabbeliermadrazr: sweet, thanks!13:13
madrazrthis should goto Testing Guidelines Wiki page?13:13
madrazrSRabbelier: NP13:13
SRabbeliermadrazr: mhhhh, should go in some testing related document :D13:14
* SRabbelier is not sure where13:14
madrazrSRabbelier: Ok, thats the only document that talks about tests :P13:14
madrazrso it should go there :D13:14
SRabbelierhehe, maybe make a new one?13:14
SRabbeliermadrazr: GettingStartedOnTests?13:14
madrazrSRabbelier: it already exists, you have created it13:15
madrazrwe need to update it13:15
madrazrI will do it13:15
madrazris it Ok if I do it on that page?13:15
SRabbeliermadrazr: yes please :)13:16
madrazrSRabbelier: Ok cool!13:16
madrazrSRabbelier: this tests is making histories for me :D13:16
madrazrMany first things, this is the first time I ever used easy_install :D13:17
SRabbeliermadrazr: cool! best way to learn new stuff is to use it :D13:18
madrazrSRabbelier: yeah13:18
*** dr__house has quit IRC13:25
*** dr__house has joined #melange13:26
*** dhaun has joined #melange13:42
Erant*yawn*14:08
ErantReversing a wearleveling algo for large block is not fun.14:08
Erantlarge block NAND too.14:08
*** dbentley-laptop has joined #melange14:25
madrazrSRabbelier: is it Ok to call seed_db.seed_org () and similar functions if necessary from the tests instead of writing the same code again?14:43
SRabbeliermadrazr: I think that's acceptable, jup14:53
madrazrdr__house: Ok14:53
dr__housemadrazr: that was referred to SRabbelier I guess14:53
dr__house:P14:53
madrazrdr__house: I have really gone mad today :P14:54
dr__housemadrazr: no, thats not true. You were before :P14:54
madrazrdr__house: no I was madrazr before :P14:54
dr__househeh14:55
*** jbailey has left #melange15:37
madrazrSRabbelier:15:48
madrazrhttp://paste.pocoo.org/show/117477/15:48
tpbTitle: Paste #117477 | LodgeIt! (at paste.pocoo.org)15:48
madrazrhow do I solve this error?15:48
SRabbeliermadrazr: look at how run.py, it should set it16:02
SRabbeliermadrazr: if it doesn't, make it16:02
madrazrSRabbelier: yeah I now just tried with os.environ['HTTP_HOST'] = 'localhost'16:03
madrazrand that error is gone16:03
SRabbeliermadrazr: wooh16:03
madrazrI have a new error now :P16:03
madrazrSRabbelier: http://paste.pocoo.org/show/117482/16:04
tpbTitle: Paste #117482 | LodgeIt! (at paste.pocoo.org)16:04
SRabbeliermadrazr: you forgot a .logic16:04
madrazrSRabbelier: for?16:05
SRabbeliermadrazr: or.. you found a bug :P16:05
SRabbeliermadrazr: the error line16:05
SRabbeliermadrazr:     key_name = model_logic.notification.logic.getKeyNameFromFields(fields)16:05
madrazrSRabbelier: latter I am thinking :D16:05
SRabbeliermadrazr: should be model_logic.logic16:05
SRabbeliermadrazr: or at the top16:05
madrazrSRabbelier: Ok16:06
madrazrSRabbelier: import soc.logic.models as model_logic16:14
madrazrThe import statement looks like this16:14
madrazrSRabbelier: so key_name = model_logic.notification.logic.getKeyNameFromFields(fields) should be correct16:14
madrazrbut still the test says module has no attribute notification16:14
*** dr__house has quit IRC16:24
Eranthttp://www.theregister.co.uk/2009/05/15/microsoft_banishes_memcpy/16:24
tpb<http://ln-s.net/3C4m> (at www.theregister.co.uk)16:24
ErantOh pulease.16:24
ErantMicrosoft has crappy programmers.16:24
*** madrazr1 has joined #melange16:33
SRabbeliermadrazr, madrazr1: oh, maybe I misread16:33
*** madrazr has quit IRC16:34
*** madrazr1 is now known as madrazr16:34
madrazrSRabbelier: Ok16:34
madrazrbut I am wondering why that error is occuring16:34
SRabbeliermadrazr: what's your full path?16:34
madrazrSRabbelier: full path to?16:35
SRabbeliermadrazr: to you repo16:35
madrazrSRabbelier: /media/netfs/melange/16:35
SRabbeliermadrazr: and then /tests?16:36
madrazrSRabbelier: yeah16:36
SRabbeliermadrazr: mhhh, weird then16:37
SRabbeliermadrazr: all the tests pass but that one?16:37
madrazrSRabbelier: yeah16:37
madrazrSRabbelier: and the weirdest part is, just replace model_logic.notification with any other logic say model_logic.user this error won't occur16:38
SRabbeliermadrazr: mhhhh, weird, it's working for me :(16:39
madrazrSRabbelier: this is happening for the new test I have written16:39
madrazrSRabbelier: I will mail the patch16:39
madrazrapply and test16:39
madrazrSRabbelier: whenever you are free16:39
SRabbeliermadrazr: ok, I can do that now :)16:40
madrazrSRabbelier: Ok I will send it in 2 mins16:42
SRabbeliermadrazr: ok16:43
madrazrSRabbelier: sent16:46
SRabbeliermadrazr: ok16:46
madrazrSRabbelier: brb16:48
*** madrazr has left #melange16:48
*** madrazr has joined #melange16:50
madrazrSRabbelier: back16:54
SRabbeliermadrazr: wb16:54
madrazrSRabbelier: :)16:54
SRabbeliermadrazr: good news, I get the error too :P16:56
madrazrSRabbelier: hehe :)16:56
madrazrSRabbelier: that means I broke something? :P16:56
SRabbeliermadrazr: am checking16:59
madrazrSRabbelier: Ok16:59
SRabbeliermadrazr: mhhh, maybe I know17:00
madrazrSRabbelier: cool! whats that?17:00
SRabbeliermadrazr: fixed :)17:04
madrazrSRabbelier: sooper17:04
madrazrSRabbelier: did you commit it?17:04
SRabbeliermadrazr: doing so now17:04
madrazrSRabbelier: Ok17:05
SRabbeliermadrazr: committed under git, then converted to hg and pushed!17:08
SRabbelierhg-git ftw :)17:08
SRabbeliermad props to durin42 and schacon :D17:08
* durin42 hears name, unlurks17:08
durin42hee, thanks17:09
madrazrSRabbelier: sooper17:10
SRabbelierdurin42: I hope to be able to help out more with hg-git, but everytime I pick something to fix schacon has already fixed it, amazing! :P17:11
madrazrSRabbelier: I still did not understand what the problem was :(17:12
madrazrSRabbelier: and what did your fix do?17:12
SRabbeliermadrazr: in python, if you do not import a module, it just does not exist in the parent module17:12
SRabbeliermadrazr: try this in an interactive python interpreter17:13
*** florinciu has joined #melange17:13
SRabbelier(in app)17:13
SRabbelierimport soc17:13
SRabbelierdir(soc)17:13
SRabbelierimport soc.models17:13
SRabbelierdir(soc)17:13
SRabbelierand lo and behold ;)17:13
madrazrSRabbelier: heh OK :)17:14
madrazrgot it now :D17:14
madrazrit looks so trivial now ;-(17:14
madrazr;-)17:14
SRabbeliermadrazr: ^_^17:15
SRabbelierhttp://tinyurl.com/lol-birds17:15
tpbTitle: LOL burdz « Lolcats n Funny Pictures of Cats I Can Has Cheezburger? (at tinyurl.com)17:15
madrazrSRabbelier: :)17:16
madrazrSRabbelier: where should I get gaeftests module from?17:17
SRabbeliermadrazr: easy_install again :)17:17
madrazrSRabbelier: heh Ok :)17:17
madrazrSRabbelier: tests passed17:22
madrazrSRabbelier: I have not changed anything in the patch sent17:22
SRabbeliermadrazr: yup :D17:22
SRabbeliermadrazr: that's what I saw too17:22
madrazris it possible to review the patch and give suggestion?17:22
madrazrSRabbelier: heh Ok17:22
madrazrSRabbelier: any suggestions for improvement?17:22
SRabbeliermadrazr: can you reuse the org_app properties from seed_db?17:36
madrazrSRabbelier: as in call seed_db.seed_org_app() method?17:37
SRabbeliermadrazr: right, or modify seed_db to let you more easily do that, that'd be fine too17:37
madrazrSRabbelier: Ok17:38
madrazrthat means just have request parameter take a default value as None17:38
SRabbeliermadrazr: mhhh, would be better to just make it not need the request parameter17:38
madrazrSRabbelier: I did not get you17:39
SRabbeliermadrazr: what does it use request for?17:39
madrazrSRabbelier: nothing17:39
madrazrso totally remove request?17:39
SRabbeliermadrazr: mhhh, I think that would break other parts of seed_db17:40
madrazryeah17:40
madrazrso making def seed_org_app(request=None, i):17:41
madrazrworks?17:41
SRabbeliermadrazr: yeah, I guess that'd work for this case :)17:42
madrazrSRabbelier: Ok17:43
*** dhaun has quit IRC17:48
madrazrSRabbelier: if we re-use seed_db's seed_org_app after we get the properties back17:53
madrazrwe will have to manipulate the link_id17:54
SRabbeliermadrazr: how come?17:54
madrazrSRabbelier: link_id of org and org_app needs to same no?17:54
SRabbeliermadrazr: right, but doesn't it use the 'i' value for that?17:54
madrazrSRabbelier: it does, but the way seed_org and seed_org_app constructs link_id is different17:55
madrazrseed_org_app has 'link_id': 'org_app_%d' % i,17:55
madrazrseed_org has 'link_id': 'org_%d' % i,17:55
SRabbeliermadrazr: ah, right, that should probably be changed (org_app should be org)17:56
madrazrSRabbelier: Ok17:56
madrazrSRabbelier: then I think now we can reuse both seed_org and seed_org_app17:57
madrazrshall I ?17:57
SRabbeliermadrazr: yup, go ahead17:57
madrazrSRabbelier: ouch, seed_org_app uses request parameter :)18:04
madrazrstatus = request.GET.get('status', 'pre-accepted')18:04
madrazrSRabbelier: can we still re-use it? any tricks?18:05
SRabbeliermadrazr: yes, do the status extraction in the seed_db code, and pass that to seed_org_app18:06
madrazrSRabbelier: so status is a 3rd parameter?18:08
madrazrto seed_org_app18:08
SRabbeliermadrazr: instead of request18:09
madrazrSRabbelier: I did not get this, please explain a bit18:09
SRabbeliermadrazr: sorry, was looking up The Law of Demeter on statckoverflow :P18:23
SRabbeliermadrazr: http://stackoverflow.com/questions/871090/what-is-the-name-of-this-programming-rule18:23
SRabbelier:D18:23
tpb<http://ln-s.net/3C7Q> (at stackoverflow.com)18:23
madrazrSRabbelier: NP18:23
madrazrI am reading it18:23
madrazrSRabbelier: you posted that for me? :P18:24
SRabbeliermadrazr: yeah :P18:25
SRabbeliermadrazr: wanted to refer you to it, but couldn't remember the name!18:25
madrazrSRabbelier: he he OK18:25
SRabbeliermadrazr: we're almost-but-not-quite violating it there18:25
madrazrSRabbelier: stackoverflow is freaking fast :P18:25
SRabbeliermadrazr: but the idea is the same18:25
SRabbeliermadrazr: yes, it is, it's amazing18:25
madrazrSRabbelier: Ok18:25
SRabbeliermadrazr: instead of doing foo(request) and then in foo have request.GET.get('status', 'pre-accepted')18:26
SRabbeliermadrazr: we should extract that value before calling foo, and then pass it as argument18:26
madrazrSRabbelier: but that breaks other parts of seed_db no?18:26
SRabbeliermadrazr: well, that's the point, you need to fix those calles :P18:27
SRabbeliermadrazr: should only be one though18:27
madrazrSRabbelier: Ok18:27
madrazrSRabbelier: found out where to fix this18:30
SRabbeliermadrazr: yay18:30
madrazrI will fix it now, test it and send it tomorrow18:30
madrazrneed to sleep now :) 4AM :D18:31
madrazrSRabbelier: ^18:31
SRabbeliermadrazr: lol, go to bed!18:31
madrazrit is just one call as you said on line number 786 in seed_db props = action(request, i) :P18:31
madrazrSRabbelier: yeah running18:31
madrazrbye good night18:31
SRabbeliermadrazr: g'night :)18:32
*** madrazr has left #melange18:32
*** SRabbelier has quit IRC20:10
*** florinciu has quit IRC22:07

Generated by irclog2html.py 2.17.2 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!