IRC log of #schooltool for Thursday, 2010-03-18

*** pcardune has quit IRC00:46
*** dlobo has joined #schooltool00:49
*** dlobo has quit IRC01:20
defunkt2np guys...  how long this project been in develpment?02:34
*** dlobo has joined #schooltool02:40
replaceafilldefunkt2, :)03:42
defunkt2ooh.. its been here longer than i thought03:43
*** replaceafill has quit IRC05:06
*** replaceafill has joined #schooltool05:11
*** th1a has quit IRC06:23
*** dlobo has quit IRC06:51
*** defunkt2 has quit IRC07:19
*** aelkner has quit IRC07:19
*** replaceafill has quit IRC08:42
*** defunkt2 has joined #schooltool09:14
*** aelkner has joined #schooltool09:14
*** Aiste has joined #schooltool09:47
*** menesis has joined #schooltool10:01
*** alga has joined #schooltool10:59
*** mgedmin has joined #schooltool11:27
*** Lumiere has quit IRC12:52
*** Lumiere has joined #schooltool12:54
*** alga has quit IRC12:57
*** ignas has joined #schooltool13:00
*** Aiste has quit IRC13:00
*** alga has joined #schooltool13:00
*** th1a has joined #schooltool14:34
*** dlobo has joined #schooltool15:03
*** jelkner has joined #schooltool15:06
*** replaceafill has joined #schooltool15:25
*** dlobo has quit IRC16:10
*** dlobo has joined #schooltool16:17
replaceafillyvl, do you have time for a couple of questions?16:30
yvlmorning, replaceafill, aelkner16:31
yvlsure, replaceafill :)16:31
replaceafillyvl, great, first IBoundContacts16:31
replaceafilluse case: teacher needs to send email to a kids contact16:32
replaceafillteacher is instructor in a kid's section16:32
replaceafillso teacher can see kid's info16:32
replaceafillbut when the teacher hits the "Contacts" button in the kid's index page16:32
replaceafillhe get's a login screen16:32
replaceafilli used you Security Log :D16:32
*** dlobo has quit IRC16:32
replaceafilland noticed that the problem is in16:32
yvluhh ouch16:33
*** aelkner has quit IRC16:33
yvlwhat was the last security check?16:33
replaceafilli get this at the end16:33
replaceafill#   Deny schooltool.view  on < object at 0xbbfb4ec>16:33
replaceafill# Crowds: <AggregateCrowd crowds=[<AggregateCrowd crowds=[<AdministratorsCrowd>, <ClerksCrowd>, <ManagersCrowd>]>, <OwnerCrowd>, <PersonInfoViewersCrowd>, <ContactPersonInstructorsCrowd>]>16:33
replaceafilllisppaste5, url16:34
yvllisppaste5 is in coma, it seems16:34
yvlhit by a truck or something16:34
replaceafillthat last ContactPersonInstructorsCrowd got my attention16:34
replaceafilli thought, that should check that the teacher is actually an instructor for the kid16:34
replaceafilland it does16:35
replaceafilland it works16:35
replaceafillthe teacher can access the kid's contact16:35
replaceafilllike http://localhost/contacts/Contact16:35
replaceafillthe teacher can see that16:35
replaceafillbut the teacher cannot access the ContactOverviewView for some reason...16:35
replaceafilli even removed everything from the ContactOverviewView template, thinking that maybe the template is trying to access something forbidden16:36
replaceafillbut still16:36
replaceafilli get a login page16:36
yvlok, I'll try to debug that16:36
replaceafillsee? your security log tool works ;)16:37
yvlI wonder why it said DENY16:38
*** alga has quit IRC16:39
yvlyou know what16:39
yvladd __repr__ to the bound contact16:39
yvlsomething like16:39
yvldef __repr__(self):16:39
yvl   return '<BoundContact(%s)>' % self._person.__name__16:40
yvljust for debugging16:40
replaceafillshould i check the security log again?16:41
replaceafillor use prints somewhere16:42
yvlyes, security log16:44
yvlit should print # Deny schooltool.view on <BasicPerson(student-username-something)>16:44
replaceafillthe teacher can see ariana's index page16:45
yvlthat is very odd16:46
yvlare you working with st trunk?16:46
*** aelkner has joined #schooltool16:46
replaceafillyvl, i'm using your sprint branch for the logging16:46
replaceafillbut i get the same login screen in trunk16:46
yvlhmm, I cannot reproduce16:47
yvlwell, if it got deny, then ContactPersonInstructors crowd also failed16:48
yvldo an old fashioned import pdb; pdb.set_trace()16:48
yvlor, add print's16:48
replaceafilli did16:48
replaceafillin that crow16:48
replaceafilland i noticed that when tom tries to access ariana's contactoverviewview16:49
replaceafillself.context.persons is empty16:49
replaceafillbecause i guess the crowd works for a contact16:49
replaceafillno a boundcontact16:49
yvlwhat is self.context ?16:49
replaceafillcontact.persons -> students16:50
replaceafillin that case, self.context -> boundcontact for ariana16:50
yvlis it the right self.context?16:50
replaceafilllet me check again16:50
replaceafill        if user.username == 'tom' and self.contex._person.username == 'ariana':16:51
replaceafill            import pdb; pdb.set_trace()16:51
replaceafillin that crowd16:51
replaceafilland self.context...16:51
replaceafillok, login as tom, the teacher16:53
replaceafillgo to ariana's index16:53
replaceafillhit Contacts16:53
replaceafillpdb.set_trace works16:53
replaceafill(Pdb) self.context16:53
replaceafill(Pdb) [v for v in self.context.persons]16:53
replaceafillbecause the student is not a contact for other students16:54
yvlfound out why16:55
replaceafillmy tiny brain thinks that crowd works on Contacts16:55
replaceafillnot BoundContacts16:55
yvl        # XXX: hack to obtain basic person, because if we write an adapter16:55
yvl        #      to it, all objects adaptable to IBasicPerson will get indexed.16:55
yvl        #      This is to be removed as soon as basic person catalogs learn16:55
yvl        #      how to index *only* basic persons.16:55
yvl        person = self.context16:55
yvlere you go16:55
yvlI wonder why getParent did not work there16:56
replaceafillwant me to put the pdb there?16:56
yvlno, it's my bug from now on16:58
yvlthe thing is, that we need an adapter to IPerson from IBoundContact16:58
yvlthe actual crowd to work is schooltool.course.section.PersonInstructorsCrowd16:59
yvlbut the XXX in explains why we do not have one16:59
replaceafilli see17:00
yvlI'll fix the catalog soon17:00
replaceafillcool, i'm cheating in the tests right now17:00
replaceafillopening access for everyone17:00
replaceafillyvl, getParent does get the basicperson17:03
yvlbut not in PersonInstructorsCrowd17:04
yvloh, wait17:04
yvlit isn't even listed17:04
th1ayvl: not to break your train of thought, but before you sign off, I'd like to schedule a meeting for tomorrow.17:06
yvlgo ahead th1a17:07
yvlreplaceafill: try putting tom into 'teachers' group at the same year17:08
yvlit should work17:08
replaceafillit is17:08
replaceafilllet me check17:08
replaceafillyes, he is in the teachers group17:10
yvloh my god17:10
replaceafillyvl, question, the PersonInstructorsCrowd is not in the security log, correct?17:10
yvljust read the personinfoviewers implementation17:10
yvlit turns out17:10
replaceafillso, the view is not trying to use it?17:11
yvl(this is gonna be a good one)17:11
yvlthat you can look at person info17:11
yvlif they are teachers17:11
yvlthis year17:11
th1ayvl:  I'll have the main feature requests from the preliminary grant proposals loaded as bugs in Launchpad by tomorrow.  I'd like to go through them and apply guesstimates and ask questions tomorrow.17:14
yvlsounds great17:15
yvl9:30 your time tomorrow?17:15
th1a8:30 is ok with me.17:16
th1aSo that's... 1230 UTC?17:16
yvlits 11:16 now in Providence?17:16
yvlok then17:18
yvlit will be 14:30 here17:18
th1aOK.  See you then.17:20
replaceafillyvl, last question then17:20
replaceafillis it possible to know how many pages a PDF will have17:21
replaceafilluse case:17:21
replaceafillwee need to put a signature space for a report in the last page17:21
replaceafillin CanDo17:21
replaceafillthe first page needs a logo17:21
replaceafillthe second, third and other pages dont need a logo17:22
replaceafillbut sometimes, the report can be only a single page17:22
yvl( th1a, please assign to someone, once you have free time to look at LP )17:22
replaceafilli was using a 'front_page' style sheet for the first page17:22
yvlso far so good17:23
replaceafilland the signature space was there too17:23
replaceafillbut now dwelsh wants the signature space at the last page17:23
replaceafillso, i thought, i need a special stylesheet for the last page17:23
replaceafilli know rml has support for firstpage style or something like that17:24
th1ayvl:  Already did.17:25
th1aYou can just give all intervention bugs to aelkner.17:25
th1areplaceafill:  Uh oh.17:26
yvlreplaceafill I doubt that you can specify something like lastPageTemplate17:26
replaceafillyes :(17:26
th1aAsk him if it can go on the front page.17:26
replaceafillth1a, he said it could but if we changed the position of the signature :)17:27
yvlone solution would be add the logo as the flowable17:27
yvlappending to the story17:27
yvlmaybe flowables can 'snap' to bottom of the page17:28
yvlwell, flowables ar all elements within a story17:28
yvllike paragraphs, images17:28
replaceafillRML for Idiots!!!17:30
replaceafilla doc just for me ;)17:30
replaceafillok yvl, now for real, last dumb question17:32
replaceafillin a browser = Browser(...)17:32
replaceafillin a ftest17:32
replaceafillwe have browser.serve()17:32
yvlgo on...17:32
replaceafillto start the server for debuggin right17:32
replaceafilland it launches your browser17:32
replaceafillwith localhost:800017:32
replaceafilland the user that you specified in Browser('tom', 'tom')17:33
replaceafillmy question is, do you know if it's possible to log in as another user17:33
replaceafillin the same session?17:33
yvlnever tried it17:34
replaceafillah ok, never mind then :)17:34
replaceafilljust a question that came to me17:34
replaceafillsince Log out doesn't work17:34
replaceafillbut it's ok, no biggie17:34
replaceafillthanks yvl17:34
*** dlobo has joined #schooltool17:35
yvlif you really need it17:35
yvlyou can change browser.username and browser.password17:36
yvlbefore browser.serve()17:36
yvlevil, but should work17:36
replaceafillbut not in the web browser, right?17:36
yvlthat I didn't try17:36
yvlso - dunno...17:37
replaceafillyvl, thanks again, those were my only questions17:37
yvlallright then17:41
yvlhappy coding ;)17:41
yvl(and don't spend too much time struggling with rml... I'm not that confident that you can add the logo at the bottom of the page easily)17:42
yvl(and I'd guess that you can't add logo to the _top_ of the last page)17:42
replaceafillah ok17:43
*** Aiste has joined #schooltool17:57
*** mgedmin has quit IRC18:38
*** Aiste has quit IRC18:41
*** dlobo has quit IRC18:59
*** dlobo has joined #schooltool19:37
*** replaceafill has quit IRC20:55
*** dlobo has quit IRC22:06
*** dlobo has joined #schooltool22:06
*** dlobo has quit IRC22:12
*** dlobo has joined #schooltool22:43
*** dlobo has quit IRC23:30
*** jelkner has quit IRC23:50
ignasyvl, FYI - the only way to log in as another user is to NOT give a user at all, as in - pass None and None, then - you will have to log in for the first URL, but the log in will be cookie based instead of http headers based23:50

Generated by 2.15.1 by Marius Gedminas - find it at!