IRC log of #schooltool for Monday, 2010-11-29

*** th1a has joined #schooltool03:18
*** replaceafill has joined #schooltool03:41
*** th1a has quit IRC07:32
*** yvl has joined #schooltool07:48
replaceafillyvl, you around?08:05
yvlgood evening, replaceafill08:05
replaceafillhey yvl, you're better?08:05
yvlyeah, thanks :)08:05
replaceafillglad to hear, i've been wanting to ask you a couple of things, i know you probably have lots of work to do08:06
replaceafillcan you give me a time for us to meet? like 30 mins or so08:06
yvlof course!08:07
yvlwe can do that now :)08:07
replaceafillgreat! let me take my notes08:07
replaceafillmy questions are related to the scoresystem preference work in the gradebook08:08
replaceafilland i have a few about enrollment statuses08:08
replaceafilli dont want to continue until i have your ok :)08:08
replaceafillok, for the scoresystem preference work08:08
replaceafillbug: https://bugs.launchpad.net/schooltool.gradebook/+bug/67186308:08
replaceafillscoresystem preferences (and others like hiding average and total columns) are currently stored in the person as annotations, right?08:09
yvlAFAIR yes, but lemme check08:10
replaceafill:)08:10
replaceafillschooltool.gradebook/gradebook.py08:10
yvlah, yes08:10
replaceafillok, you suggested we use adapters for that08:11
replaceafilland store the annotations in the adapter contexts (i guess)08:11
replaceafilllike worksheets08:11
yvlyou can keep storing in 0th instructor of the section..08:12
yvlcurrent functionality is a bit weird, actually08:12
replaceafillwhat if he dies? :D08:12
replaceafilland he's changed?08:12
yvleverybody will see same preferences as 0th teacher08:12
yvlother teachers see their own preferences08:13
yvlyou can keep the system working as it is now08:14
yvland fix it in another go :)08:14
replaceafillwhat do you mean? not sure i got that right :(08:14
yvlthis:08:14
yvl            section = ISection(gradebook)08:14
yvl            instructors = list(section.instructors)08:14
yvl            if len(instructors) == 0:08:14
yvl                person = None08:14
yvl            else:08:14
yvl                person = instructors[0]08:14
yvlcolumnPreferences = gradebook.getColumnPreferences(person)08:14
yvlhowever you refactor, make adapters get annotations if the 0th instructor of the relevant section08:15
replaceafilli'd still have to store the worksheet|section data, correct?08:17
replaceafillto know that i want preferences of 0th instructor for THIS worksheet/section08:18
yvlok, I didn't read Alans last comment right08:20
yvlif you're doing the "three-level selection paradigm" thing08:21
replaceafillI guess Alan's suggest a 'cascade' system to pick the scoresystem08:21
yvlyou should store on annotations of respective objeccts08:21
replaceafillyes!08:21
yvlsorry, didn't finish my morning coffe yet08:22
yvlsleepy ;)08:22
replaceafillnp08:23
replaceafillso, i'm in a worksheet and i want its preferences, i have to adapt (worksheet, instructor[0]), right?08:24
yvlscrap what I said before08:24
yvljust the worksheet08:24
replaceafillah ok08:25
replaceafillworksheet stores its preferences08:25
replaceafillwhat if i want to set preferences by section, same right? store preferences in the section08:26
yvlI'm afraid you know the details better08:27
yvlhow are the worksheets done now?08:27
replaceafilli was trying an approach like: look up worksheet prefs, if you find one use it, if not, look at the section, if you find one use it, adn so on08:27
*** aelkner_ has quit IRC08:28
replaceafill"<yvl> how are the worksheets done now?" <-- not sure i got that right?08:29
* yvl is looking at the code...08:29
yvlumm08:33
yvlclearly still haven't woken up08:33
replaceafill:))08:33
yvlwhere are the worksheets stored?08:33
replaceafillin the IActivities08:35
replaceafillyou adapt a section to IActivities08:35
replaceafillthe IActivities are stored in the section annotations08:35
replaceafillschooltool/gradebook/activity.py/getSectionActivities08:36
yvlok, found/remembered :)08:37
yvlso yes08:37
yvlstore on section annotations08:37
yvlby the way08:38
yvlhow are you going to implement the "hierarchy"?08:38
yvlsay, we are selecting worksheet score system08:38
yvlthe default value should be something like 'use __parent__ defaults'08:39
yvlreplace __parent__ with section here08:39
replaceafillyes08:39
replaceafillat this point i have it working for worksheet/section only08:40
yvlhow are you going to select the parent?08:40
replaceafillbut another of my questions is: how do i handle existing data?08:40
yvlanother adapter?  IParentPreferences? :)08:41
yvlor IInheritedPreferences or something :)08:41
replaceafilli've used a function with sucky 'providedBy' checks by now08:41
yvlexisting data -> evolution08:41
replaceafillbut as i learned from you, wherever you see if's with providedBy... you can use adapters ;)08:42
yvlevolution, because you will be changing the behaviour, so no sense to keep the data were it is08:42
replaceafillbut existing data stores no information about sections :(08:42
replaceafillexisting data only says, justas wants total columns hidden08:43
replaceafillnot where08:43
yvlyeah08:43
yvlbut all sections have instructors08:43
replaceafilli take the instructor[0] preference?08:43
yvlI meant may have08:43
yvlyes08:43
replaceafilldo i erase the preference from the person in the evolution script?08:44
yvlprobably yes08:45
yvlbut it would be good to bring this up in today's meeting08:45
yvlthat the behaviour is changing08:45
replaceafillyes, evolution is where i got stuck :(08:45
replaceafilli wasn't sure what to do08:45
yvlignore it for now08:45
yvl:)08:46
replaceafillgreat! will make those if's adapters then08:46
replaceafillfor the hierarchy08:46
yvlI may be to cautious or something08:46
yvlbut I like things like that to be matter of configuration08:46
replaceafillthe adapters for the hierarchy?08:47
yvlas in: I want the defaults of worksheets to be specified for sections08:47
yvlyes08:47
replaceafillunderstood08:47
replaceafillwell, i guess that's all i had to ask in this matter :)08:48
replaceafillwill leave the enrollment status qeustions for next time08:48
yvleasy to change, if, for some reason some school decides that defaults for section should come from the courses, not from terms08:48
replaceafillyes08:49
yvloh, it's a bit late... :)08:49
yvlwell, good night ;)08:49
replaceafillnp, i'll plan to stay up late ;) (slept a lot in the afternoon) :D08:50
replaceafillbtw, these dont need to be 'named' adapters, right?08:51
replaceafilli still get confused when the name is required08:51
replaceafillwhen you're planning to make possible to override the adapter08:51
yvlI can't think of a reason for them to be named08:53
replaceafillcool08:54
replaceafillthanks yvl!08:54
yvlyou're welcome :)08:54
replaceafillglad to have you back :)08:54
yvlThanks :)08:59
yvlit's good to be back...08:59
*** aelkner has joined #schooltool09:06
aelkneryvl: hey09:32
yvlevening, aelkner09:32
aelknerdo you have a moment to look at my schooltool branch?09:32
aelkneri haven't pushed yet, but i cold09:33
aelknercould09:33
yvlsure09:34
aelkneryvl: ok, i pushed up my changes to the resource forms09:46
aelknerthey use z3c formlib09:46
yvlthanks, looking at it...09:46
aelknerand i was able to get the forms rendered until i dealt with the subtype widget09:47
aelknersee the getBaseFields(self): method where I set the widget for the field09:47
aelknerlocation and equiptment resources have the type attribute which has a special widget09:48
aelknerso i've been working on the widget class which uses the z3c version of the widget subclass09:52
aelkneri made a lot of progress, but the datamanager adapter is not working09:52
aelknerdo i need to register something?09:52
yvlprobably :)09:54
yvlI'm still looking at the changes09:54
*** menesis has joined #schooltool09:56
yvlby the way09:57
yvlwhy is src/schooltool/resource/browser/templates/resource_form.pt  full of metal:define ?09:57
yvlsorry define-slot09:58
yvlit looks like a copy of skin/templates/z3c-schooltool-form.pt09:58
replaceafill...which btw is not updated for subgroups ;)09:59
yvlFIY, I'd prefer instead of: from zope.formlib import form as oldform10:00
yvljust do: from zope import formlib10:00
yvland then use formlib.form.Fields, formlib.form.Actions10:00
yvlwould make it easier to read the code10:01
aelknergood idea10:02
yvlyou may do the same for z3c.form10:02
yvlbut that is up to your aesthetics10:02
aelkneryeah, more verbose, but disambiguated10:02
yvlyes10:02
yvlit's up to you to choose if it makes sense in this particular case10:03
yvlexplicit use of z3c.form.* and formlib.* makes code clearer10:03
yvl but also gives macaroni :)10:03
yvlz3c.form.button.buttonAndHandler(_('Cancel'))10:04
aelknerit's always a trade-off10:04
aelknerbtw10:04
aelknerthe problem is the file has mixed formlib/z3c.formlib10:05
yvlyes10:05
aelknerthat isn't usually the case10:05
yvlthat is why in this file it may make sense10:05
yvlI mean - sometimes it's good to warn a developer that this is formlib, and the next class is z3c.form10:06
yvlif it's the same file, in my opinion - the long resulting macaroni may not be worth it10:06
yvlhmm, you might want to change menuItem directives to navigation viewlets10:07
yvlalso, you don't need to write your __call__ in BaseResourceView10:08
yvlit is already done in z3c.form10:08
yvl(just so you know, it also checks if response status is a redirect, in which case the view is not rendered)10:09
yvl(just an interesting factoid ;) )10:09
yvlas for BaseResourceAddView.update10:11
yvlI usually consider it somewhat dangerous to override a single method of the base library class10:11
yvland not call with super or similar10:12
yvlin your implementation, it differs from z3c.form, because it does not refresh actions10:12
yvlmight give future developers an unexpected 'present'10:12
yvlplease change to something like:10:13
yvl43710:13
yvl    def update(self):10:13
yvl10:13
yvl43810:13
yvl        self.fields = self.getBaseFields()10:13
yvl10:13
yvl43910:13
yvl        self.fields += self.getDemoFields()10:13
yvlsuper(BaseResourceAddView, self).update()10:13
aelkneryvl: i need to go to sleep now, but could you keep looking at the branch and try to10:23
aelknerfigure out how to get it to not fail on the adapter lookup?10:23
yvlsure10:23
yvlin short10:24
yvlyou wrote a new widget10:24
aelkneri hacked one, you should say10:24
yvland it does not know how to get the data from the request, validate it, and convert ir to python variables10:24
yvl(well, at least from z3c.form point of view ;) )10:25
aelknerit's in a transition state from formlib to z3c...10:25
yvlI understand10:25
yvlif you want an example10:25
yvlwe do have on in basicperson/browser/demographics.pyt10:26
yvl.py10:26
yvlCustomEnumDataConverter10:26
yvlbut that will be not enough10:26
yvlor maybe...10:27
aelknerdo you think you could make any progress on it while i sleep?10:27
yvlyes10:29
yvlgoodnight aelkner10:29
yvlsee you at the meeting :)10:29
aelknerthanks, see you in six hours10:29
replaceafillyvl, question10:30
replaceafillif we implement the lookup hierarchy for preferences using adapters10:30
replaceafillwouldnt be nice to be able to set the worksheet preferences for the whole school and let the teachers to customize what they want?10:31
* replaceafill thinks he's trying to fly too high10:31
replaceafillbut i see a problem with the look up :(10:32
replaceafilli set the preferences for the section, then i go to a worksheet and customize "SOME" not all10:32
replaceafilli only can handle that duplicating data from the 'parent'10:33
replaceafillyvl, http://pastebin.com/16X419Qs10:33
yvla moment... I'm making coffee :9~~~10:34
* replaceafill feels envy and goes to make coffee too...10:34
yvlwell, the old implementation of preferences is a simple dict10:41
yvlso it does not have a schema, IIRC10:41
replaceafillno10:42
replaceafilland that's a problem if you want to know what preferences we have :(10:42
yvlright10:42
yvlso you'll need to add a few things10:42
yvlscoresystem_average should be a choice field, shouldn't it?10:42
replaceafillah ok10:43
yvlwith a custom vocabulary10:43
yvlthat lists scoresystems that make sense10:43
yvland an option "inherit from XXX"10:43
replaceafill:|10:43
yvloverall, I'd go as far as use the pattern calendars and timetabling is using10:44
yvlIHaveWorksheetPreferences10:44
yvlIWorksheetPreferences10:44
yvlIInheritedWorksheetPreferences10:44
yvlin the vocabulary, get IInheritedWorksheetPreferences10:44
replaceafillihaveworksheetpreferences -> objects that store preferences10:45
yvlif it's None, it has nowere to inherit from (e.g. it's app preferences)10:45
yvlyes10:45
replaceafilliworksheetpreferences -> the preferences stored in ihaveworksheetpreferences10:45
yvlif it's not None, use inherited.context.title or somehting10:45
yvlstored in annotations of object that implements ihaveworksheetpreferences10:45
replaceafillnice :)10:46
yvlif you do this, the rest should be defined in ZCML10:46
yvland modified up to user's requirements :)10:47
replaceafilli was wondering if the instructor could be a ihaveworksheetpreferences10:48
replaceafilllike jumping from: worksheet -> section -> teacher -> app10:48
yvlprobably yes10:50
yvlbut there's always a question of multiple instructors :)10:50
replaceafillah crap! true10:50
yvlthe relationships are not exactly ordered10:51
*** replaceafill has quit IRC11:08
*** th1a has joined #schooltool15:34
*** replaceafill has joined #schooltool16:25
th1aHi replaceafill, yvl, menesis, aelkner.16:30
aelknermorning16:30
replaceafillgood morning/afternoon16:30
menesishello16:31
yvlgood morning116:32
yvl!16:32
th1aOK, just hit "send" on the 2010 report & 2011 proposal.16:33
th1aJust got the "out of office" reply from Mark.  ;-)16:34
th1aNow, where were we?16:34
th1ayvl, how are you?16:34
yvlI'm back, in "full battle condition" :)16:34
yvl(and it's freezing here, -13C / 9K)16:35
th1a9 Kelvin?16:35
yvlyes16:35
yvlshould get as low as 0K16:35
th1aDoesn't all matter stop moving at 0K?16:36
th1aAbsolute zero?16:36
yvlgood point ;)16:36
th1aDo you mean F?16:36
yvlof course16:36
aelknerK is for Fahrenheit16:36
th1aGood coding weather.16:36
yvl:)16:37
yvlby the way, what's the status with guys from Critical Links?16:37
yvl(aelkner, please check your email :) )16:38
th1aWe will probably be having our annual meeting in Portugal in late January.16:38
th1aAlex, the product manager for the education appliance is going to be there too (from New Jersey).16:39
th1aSo that will be the big summit.16:39
th1aIn the meantime, we want to clear out some of the basic technical issues, particularly around packaging, version control, etc.16:39
th1aSo we're going to send some questions -- tomorrow -- and then have a conference call.16:40
th1aCall to be scheduled.16:40
yvlok16:40
yvlI emailed a batch of questions last week16:40
yvlto the dev list16:41
th1aThe thing right now is that my conversations with their marketing guys are somewhat tortured.16:42
th1aWhich is typical I think -- we just usually don't have to talk to marketing people.16:42
th1aI'm spoiled.16:42
yvl:)16:42
th1aSo I think getting the geeks together will go very well.16:43
yvlbut we definitely need some answers first16:43
th1aIn the meantime I just have to tell the marketing guys what they want to hear and do what they do.16:43
yvlat least - versions, and how often they are upgrading16:43
th1ayvl:  They're several versions behind right now.16:43
yvlwe suspected that much... :|16:44
th1aI think they're working on getting caught up.16:44
th1aI know they mentioned the student index loading bug.16:44
th1aI'd like to get their CVS mirrored on Launchpad.16:45
yvlonly ST part?16:46
th1aI'll pass on your questions.16:46
yvlthanks16:46
th1aWell, yeah, the ST part.16:46
th1aI also have to ask if we can get a build of the complete system.16:46
yvlthat would be nice16:47
yvlthough I'm primarily interested in their modifications (for some reason)16:47
th1aSure.16:48
yvland how they integrated ST with everything else, of course16:48
th1aThat's what I mean -- having access to using a complete system so we can see that.16:48
th1aI don't really care about the code for the other parts.16:48
yvlwell, we'll see how it goes16:50
yvlit will be really interesting to see how ST acts as part of a solution16:50
th1aYes.16:50
th1aOK, so, what's your plan for this week, yvl?16:51
yvlthinking...16:51
yvlah!16:51
yvlthere's a lot of little things, and of course it would be nice to spend some time on timetables finally16:52
th1aLet's finish timetables.16:53
th1aReally.16:53
yvlok16:54
yvlby the way16:54
yvlI was talking with Albertas another day16:54
yvlhe suggested I compose the big huge general TODO list16:55
yvlthere are some umbrella tasks, that are keeping me awake at nights16:55
th1aYes, but perhaps not RIGHT NOW.16:55
yvlsure16:56
th1aLet's wrap up timetables then we can take a deep breath at the beginning of the year.16:56
yvlok16:56
yvlthere's a lot of communication stuck at my end16:57
yvland it's out of scope of IRC meeting16:57
th1aAnd also, next year we should be able to have more than one of you guys working together during the course of the year instead of on completely separate threads the whole time.16:57
yvljust so you know16:57
th1ayvl:  I understand.16:57
yvlok then16:58
yvlto finish the report -16:58
th1aWe'll manage things differently next year to avoid these big pileups.16:58
yvlAlbertas mentioned that16:59
yvlI'm sure we can work out how to make more things happen :)16:59
yvljust so you know - I got really attached to ST :)17:00
yvlmy baby, and so on ;)17:00
replaceafill:)17:00
th1aWell, that's much better than getting sick of it altogether.17:00
yvlyes :)17:01
yvlso, last week I helped Alan and Douglas a bit17:01
aelkneryes, thanks yvl17:01
yvlI also read a *lot* of documentation on other python web frameworks - that's not billable work, I assume17:01
yvlPyramid is a very interesting thing to track17:02
replaceafillgo Pyramid :)17:02
yvlIt may become "the new sexy"17:02
yvland we wouldn't need to abandon Zope to support that new sexy17:02
th1arepoze?17:02
yvlyes17:02
yvlbut under Pylons project17:02
yvlPylons 2.0 got scrapped, to put bluntly17:03
yvlinstead, they got the code from repoze.bfg17:03
yvland joined efforts17:03
th1aI'll check it out.17:03
yvland under the hood, Pyramid uses ZCA17:03
yvlAlan and I also had a little chat about creating schooltool.ui package17:04
yvlthat's a possible topic for sprint17:04
yvlcurrently writing forms is very cumbersome in ST17:04
th1aMaking forms easier would help.17:05
yvlyes17:05
th1aIn the meantime... finishing timetables?17:05
th1aThis year?17:05
yvlyes!17:05
th1aOK, do that.17:06
th1aWe should move on...17:06
th1aThanks yvl!17:06
th1amenesis:  Where are we now with packaging.17:06
th1a?17:06
th1aWe got a response to your questions last week, correct?17:06
menesisth1a: I am uploading packages to schooltool PPA17:06
menesisDaniel agreed that REVU is too much hassle so I upload to the PPA17:07
menesisI have uploaded a few packages last week, and a few today17:07
menesisso there is something for sponsors to upload17:08
menesisI should reply telling that, I guess17:08
th1aYes -- communicate!17:08
th1aThat's the key to this process.17:08
menesispointing to https://wiki.ubuntu.com/Zope/Natty and add more information there17:09
menesisI have added a nightly builder of versionator, the tool I use for tracking package versions and todos17:10
menesisto publish a status on the web at http://ftp.schooltool.org/schooltool/trunk/overview.txt17:10
th1aLooks good -- make sure the right people know it is there!17:11
menesisyes, that was the point of publishing that17:12
th1aOK.  Send that email ASAP.17:12
menesistoday17:12
th1acc: me.17:12
th1aGreat.17:12
menesisas always17:12
menesisok17:13
menesisanother thing I finally made last week was finish and release schooltool 1.4.317:13
menesisthe backport for Lucid17:14
menesisalso made schooltool 1.5.3 with one fix and translation updates17:14
menesisbut haven't updated release notes or sent an announcement17:15
th1aWe need to do a better job with that.17:15
th1aSomeday we're going to surprise a lot of deployed instances with an unannounced buggy release.17:15
menesisthere is a problem with that release17:16
th1aBetter to warn people before we give them the buggy release.17:16
th1aWhat is the problem?17:16
menesisthat I only noticed after release17:16
menesisso I should have sent announcement asap and reply that there is a known problem?17:17
menesisguess so17:17
menesistwo CanDo tests break17:17
menesisone test I fixed, it was only a test17:17
menesisbut another exposes a security problem that I was not able to understand17:18
menesisstudents cannot access their SCR17:18
menesisStudent Competency Record17:18
menesisfor a strange reason, section instructor.first_name throws Unauthorized exception17:19
th1aThese are only CanDo bugs?17:20
menesisI have merged some security fixes between 1.4.2 and 1.4.3, but nothing obvious that could cause that17:20
menesiswould like someone to look into this17:20
menesisyes, this is only CanDo17:20
menesisI have tested SchoolTool before release and all looked good17:21
replaceafillcan i help?17:21
menesismaybe, if you understand security declarations17:22
th1areplaceafill:  Yes, perhaps you could take a look at this.17:22
menesismaybe it is only in cando, because students can see sections and instructors elsewhere17:22
replaceafillmenesis, if i check out cando's trunk and run the tests i'll see the failure?17:23
menesisreplaceafill: yes17:23
replaceafillok17:23
menesisor http://source.schooltool.org/buildbot/builders/pov-cando-buildout/builds/143/steps/functional%20tests/logs/stdio17:23
replaceafilland the goal is not to remove any proxy the person could have, but to understand what's going on17:24
menesisof course. but I couldn't.17:25
replaceafillgot it17:25
replaceafilli mean, understood :)17:25
menesisth1a: I think that's all I have to report17:25
menesisI have to send two emails today17:26
menesisand will continue uploading packages17:26
th1aOK, thanks menesis.17:26
th1aIt would be very helpful if you'd just be chattier during the week about these things.17:27
th1aA few more emails to the developer list would go a long way.17:27
th1areplaceafill?17:27
replaceafillok17:28
replaceafill1. no news about cambodia yet17:28
replaceafill2. i tested the fedora 9 packages, and they work17:28
replaceafill3. i worked in the worksheet preferences part and got confused about evolution17:29
replaceafillsince i'm moving annotations to the section and the current preferences data has no info about this17:29
replaceafillthe current data only says: th1a wants total columns hidden17:30
replaceafillbut it doesnt say in what section17:30
replaceafilli asked about this to yvl earlier17:30
replaceafilland he recommended that we look at the first instructor preferences (if possible) and store those in the evolution for sections17:31
yvl(to mimic SectionFinder.processColumnPreferences)17:33
replaceafillyes, the current implementation takes the first instructor17:34
replaceafilli also liked yvl's suggestion about using an approach similar to the calendar/timetable17:34
replaceafillwith IHaveWorksheetPreferences interface for instance17:35
th1aaelkner:  Any thoughts about this?17:35
replaceafilland adapters for the hierarchy, for looking up where to inherit from17:35
replaceafillworksheet inherits from section by default17:35
replaceafillsection "could" inherit from app, etc17:36
replaceafillwill finish writing the tests and will push my branch17:36
aelknerwhy do we need to make such a huge change to the gradebook code just for a simple preferences change?17:36
replaceafillaelkner, is not huge (i think)17:37
replaceafillit's only more complex :/17:37
aelknerso we're keeping person preferences and adding section preferences?17:37
yvlreplaceafill, can you give the link to the bug?17:37
replaceafillyvl, https://bugs.launchpad.net/schooltool.gradebook/+bug/67186317:37
replaceafillaelkner, we're moving the data to the section17:38
replaceafillas yvl said the relationship between section preferences and instructors is trickier, because you can have many instructors in a section17:39
replaceafillright now, my implementation cannot allow two instructors with different preferences in the same section for instance17:39
replaceafillbut th1a said we keep it simple in that part anyway17:40
replaceafillkeeping the preferences data in the section would also allow admins to change it17:40
yvlaelkner, replaceafill is implementing the chain you mentioned here: https://bugs.launchpad.net/schooltool.gradebook/+bug/671863/comments/217:40
aelknerth1a, i'm not going to be able to get my head into this feature and still get my resource demos work done17:40
aelkneryvl, ok, that would be nice17:41
th1aThat's fine -- just wanted to know if you had any specific ideas or concerns.17:41
th1aTrying to keep everyone awake.17:41
aelknerhehe17:41
aelkneri'm trusting my colleges on this one :)17:42
replaceafillwell th1a that's where i'm at right now17:42
replaceafillthanks aelkner :P17:42
th1aOK.  Cool, and have a look at those CanDo bugs.  It would be good to fix those before anyone notices.17:42
replaceafillth1a, understood17:42
replaceafillwill give that priority one17:42
th1aThanks replaceafill!17:43
th1aaelkner?17:43
aelkneri took a day off last week for thanksgiving, but i made progress with the resource demos17:44
aelkneri brought my person forms from schooltool.niepa (which have schooltool.camboda as their model)17:44
aelknerinto the resource package which meant changing the resource views to z3c formlib17:45
yvl(a small nitpick - it's z3c form, not formlib)17:45
aelknerfair enough17:45
aelkneranyway, i got the forms to work, but the tests failed on the subtype widget17:46
aelknerso yvl helped me with that late last night and made some changes today that i merged17:46
aelkneryvl: the tests still fail, but that's probably because the new widget has a different field id, right?17:47
yvlprobably17:47
yvlsorry, I didn't check the test17:47
yvls17:47
yvljust made it work :)17:47
aelknerwhat is the point of the subtype widget anyway?17:48
aelkneri mean, there's an edit field AND a dropdown17:48
yvlyou can add a new subtype in the edit field17:48
yvlOR select an existing subtype from the drop-down17:48
aelkneradd to where?17:49
yvlto the dropdown :)17:49
aelknerthat's weird17:49
yvlas in17:49
yvlknown Equipment types17:49
yvlyou add a HPLazerSomething with type printer17:49
replaceafillyvl, do you suggest to take that approach in other places, for instance cambodia's villages17:49
yvland next time you can pick type 'printer' from the dropdown17:50
replaceafillright now in cambodia you add/edit villages in one place and you see the result in the form17:50
aelkneryeah, what's up with changing choice sources in the view itself?17:50
aelknerusually, you would go to another view to maintain things like that17:50
aelknerfor instance, scoresystems are a choice when adding an activity17:51
yvlit's an old feature relly17:51
yvlreally17:51
yvlbut I like it17:51
yvlmakes input easy17:51
aelknerbut you don't add a scoresystem in the activity add view17:51
yvlideally these days17:51
aelkneryou add new scoresystems in the scoresystems view17:51
replaceafillmy concern would be what if the add/edit permission is different from the form using the dropdown17:51
yvllook17:51
yvlthese are just cached values17:51
yvlevery time, it goes through the list of available equipment17:52
yvlor location17:52
yvland checks what types have been entered manually17:52
yvland gives you a dropdown17:52
yvlthat's it17:52
yvland in another place, you can filter by types, of course17:52
yvlpermissions can't be different there17:53
yvlbecause if you can edit the type, you can edit the type17:53
yvlit's a free-text field17:53
yvlthe dropdown only collects 'already used' types17:53
yvl(and it assumes that if you can edit a resource, you have permissions to know what types of equipment are there)17:54
aelknerah, so the user chooses the types17:54
aelknerthere is no vocabulary somewhere17:54
yvlexactly17:54
aelknerok, i'm not changing that anyway17:55
aelkneri just wanted to understand it better, and now i do17:55
yvlideally, the dropdown would consist of existing types17:55
yvland an option Other:17:55
yvlselecting that option would javascriptily make the input box visible17:55
yvl[printer]17:55
yvl[computer]17:55
yvl[other:]17:55
aelknerok, anyway, i need to get the tests to pass now17:56
aelkneryvl: will you be reachable late tonight at the usual time if i need your help?17:56
yvlyes17:57
aelknercool, thanks17:57
aelknerth1a, anyway, i will work on the census pdf this week after that17:57
th1aWe need to get David onto a source (eggs) install this week so we can push last minute changes, right?17:57
aelknerthis time next week we should have something to package for david17:57
th1aDavid's big meeting in Nigeria is Dec. 9.17:57
aelkneryou mean sandbox, right?17:58
th1aShould we just do it with him then?17:58
th1aPlan a meeting?17:58
aelknerfor later this week?17:59
th1aWell, after you're ready for him to check it out.18:00
th1aWe wouldn't need the report at that point.18:00
aelknerare we agreeing on using the sandbox?18:00
th1aConsidering I foresee last minute requests, yes.18:00
aelknercool, and it can use my branch of schooltool so that we don't need merges to happen quickly18:01
th1aOK, let's just try to set up a longish meeting time late this week or early next.18:01
aelknerlet's try for late this week, thurs or fri?18:02
th1aOK.18:02
aelknercould you please schedle that with david, and i'll make sure to be available?18:02
th1aThat's what I'm saying.18:02
aelknerwell, ok then :)18:03
th1aOK.  I think we're done here.18:03
th1aHave a great week gentlemen!18:03
* th1a drops the bag of gravel.18:03
yvlgood week to you all!18:03
aelknergreat week everyone18:03
replaceafillthanks everybody18:03
replaceafillmenesis, i don't know if you knew this but the error arose in the schooltool/1.4 rev 2710 commit20:03
replaceafilland it seems related to the <PersonInfoViewersCrowd> removal20:04
replaceafilli had a related problem in cambodia20:04
replaceafillbut i'll keep looking20:04
th1areplaceafill:  Why was that removed?20:04
replaceafillth1a, not sure, it seemed like a big refactoring by yvl20:09
replaceafilli tracked it down to here: http://bazaar.launchpad.net/~schooltool-owners/schooltool/trunk/revision/2724#src/schooltool/basicperson/security.py20:09
replaceafillthen i asked yvl about that crowd and he told me we shouldn't use it anymore20:10
menesisreplaceafill: yes the removal of that crowd most likely causes this problem20:10
th1aOh, so CanDo has to catch up to that change.20:10
replaceafillmenesis, any idea how to fix it? in cambodia i just had to delete a directive in overrides20:11
menesisthe access setting is not needed but the crowd did something more20:12
th1aCanDo is doing something more with it?20:25
replaceafillth1a, checking...20:26
replaceafillmenesis, the context to a crowd is the object your checking the permissions on?20:31
replaceafillin this case the instructor20:31
replaceafillto me, it seems like cando was working becuase of this same bug :D https://bugs.launchpad.net/schooltool/+bug/56159020:34
replaceafillin this case, paul (a student) is trying to access jeff (a teacher)20:34
replaceafillthe crowd takes jeff (a teacher) as context20:35
replaceafilland the last line is the killer:20:35
replaceafill        return (ConfigurableCrowd.contains(self, principal) or20:35
replaceafill                teachers in groups)20:35
replaceafillpaul IS NOT in the crow, but jeff is in the teachers group!20:35
* replaceafill goes to check the section index view20:37
replaceafillah, the section view uses a tal path adapter to access the instructor title20:41
replaceafillit doesnt access the first_name, last_name attributes directly20:41
menesiscando has additional crowds, maybe they interfere20:44
menesisand some very hairy code20:44
menesisexample, studentGradebook:20:45
replaceafilli guess the PersonInfoViewersCrowd was the one that made possible for the student to access the teachers attributes20:45
menesis    interfaces.IGradebookInstructors(gb).instructors = interfaces.IGradebookInstructors(gradebook).instructors20:45
menesisthen how to know what instructors the view is trying to access...20:46
menesisreplaceafill: but student can see teacher's name in other views20:47
replaceafilllike the section index20:47
replaceafillwhat others...?20:47
replaceafillgradebooks!20:48
* replaceafill checks20:48
replaceafillmenesis, all the accesses i find to the instructor full name are calls to person.title21:00
replaceafill    def getLastEvaluator(self,comp):21:00
replaceafill        evaluation = self.context.getEvaluation(comp)21:00
replaceafill        if not self.isGraded(evaluation):21:00
replaceafill            return ''21:00
replaceafill        return evaluation.evaluator.title21:00
replaceafilli mean, from the student point of view21:00
menesisreplaceafill: I noticed that... but title is not even in IBasicPerson interface21:06
menesismaybe there needs to be a crowd that allows students to see their instructors21:07
menesisbecause as I see it is only the other way around21:07
menesisreplaceafill: I tried with title and it is Unauthorized as well21:07
replaceafillmenesis, the cando.gradebook.browser.StudentGradebookView has this access:21:14
replaceafill        self.instructors = ", ".join(["%s %s" % (instructor.first_name,21:14
replaceafill                                                 instructor.last_name,)21:14
replaceafill                                      for instructor in section.instructors])21:14
replaceafillhowever, the crowds check don't include <PersonInfoViewersCrowd>21:15
replaceafillthe student is allowed by the LearnerCrowd21:15
replaceafill(Pdb) crowd21:15
replaceafill<LearnersCrowd>21:15
replaceafill(Pdb) crowd.contains(principal)21:15
replaceafillTrue21:15
menesismaybe the StudentSCRView accesses some different instructors. it's hard for me to see through context.__parent__.__parent__ and similar if somewhere is a problem21:24
menesisbut sorry it is late here, I'm getting too tired to debug further21:25
replaceafillnp menesis21:25
replaceafillwill try to catch you tomorrow and report back21:25
*** replaceafill has quit IRC21:44

Generated by irclog2html.py 2.15.1 by Marius Gedminas - find it at mg.pov.lt!