IRC log of #schooltool for Wednesday, 2006-02-15

*** Spec has quit IRC00:02
*** vidasp has quit IRC01:38
*** RockyBurt has joined #schooltool04:40
*** wrobel has quit IRC05:04
*** wrobel` has joined #schooltool05:04
*** didymo has quit IRC06:36
*** tiredbones has quit IRC09:52
*** tiredbones has joined #schooltool09:52
*** alga has joined #SchoolTool12:04
*** shapr` has joined #schooltool12:20
*** shapr has quit IRC12:20
*** alga has quit IRC12:42
*** Aiste has quit IRC12:45
*** shapr` is now known as shapr12:54
*** mgedmin has joined #schooltool13:00
*** vidasp has joined #schooltool13:08
*** alga has joined #SchoolTool13:14
*** Aiste has joined #schooltool13:14
*** vidasp has quit IRC14:25
algatiredbones: here's an interesting snippet for you:15:33
algaTroubleshooting15:33
alga    * We've seen segfaults when running the test suite.  This was15:33
alga      invariably caused by having parts of Zope 2 or ZODB 3 (which15:33
alga      goes with Zope 2) installed in site-packages or elsewhere on15:33
alga      Python's module search path (sys.path).  So make sure you have15:33
alga      no parts of Zope 2 or ZODB 3 on sys.path when running Zope 3!15:33
algaZope3/doc/INSTALL.txt15:34
tiredbonesalga, thanks very much! I hope that's my problem. I was just getting ready to order a motherboard.15:43
*** mgedmin has quit IRC15:48
algaignas said that your gcc was crashing, and that python has brouhgt the whole system down15:58
*** ignas has joined #schooltool15:59
algawrong ZODB version on pythonpath does not affect such things15:59
tiredbonesalga, the system wasn't crashing, but I couldn't run 'make test'.I was getting seg faults on build for BTree.17:01
tiredbonesalga, what do you mean here - wrong ZODB version on pythonpath does not affect such things17:02
algaI had an impression that it was not just the tests that were failing, that the compilations were also17:40
algasorry, my English is not at its straightest today17:41
tiredbones'make test' ran now I'm having prblems with 'make ftest' any help  -> http://pastebin.com/556054. I removed an old copy of Zope I had around.17:41
tiredbonesls17:42
algawhat if you start python2.4 and type in "import ZODB"?17:45
algaif it succeeds, ZODB.__file__17:45
tiredbonesalga, looky, looky. It succeed - '/usr/local/Zope-3.2/zope3/src/ZODB/__init__.pyc'17:47
tiredbonesalga, can I/should I  just dump ZODB?17:48
*** RockyBurt has quit IRC18:00
*** th1a has joined #schooltool18:18
algaOK18:27
algatiredbones: it looks like the correct version of ZODB...18:27
tiredbonesalga, So this is not my problem/18:28
*** Aiste has quit IRC18:28
tiredboneswhen I run 'make build update-translations following http://pastebin.com/556146.18:35
tiredboneswhen I run 'make build update-translations' i get the following http://pastebin.com/556146.18:36
povbot/svn/commits: * ignas committed revision 5759:19:16
povbot/svn/commits: Refactored DailyCalendarRowsView so it would be easier to implement a timezone timetable interaction bugs.19:16
ignassrichter, ping20:08
srichterpong20:12
ignasi am going through schooltool trying to fix some TZ bugs20:13
ignasand you are using  "self.date = datetime.date.today()20:13
ignas" in commendation20:13
ignasis it intentional ?20:13
ignasmost of the time the date should be taken with the users timezone or app timezone taken into account20:14
ignasi can't recall exactly now, but i am afraid that date.today() is in the server timezone20:14
ignasnot utc event20:14
ignaseven20:14
srichterfeel free to change it20:15
srichterI probably did not even think about it when I wrote it20:15
ignasthat's why i am asking you to think of which date you want in there20:16
ignasas i don't know what that date is used for20:16
ignasthe only test is checking that it is read only20:16
ignasand yes - date.today() returns a date in the server timezone20:16
srichterit is the date at which the commendation was made20:16
ignasnot really the date you want to use in a web application20:16
srichterthe timezone for that date is not important in my opinion20:17
srichterfor example, let's say you created the commendation at 1:00 am on February 2, 200620:18
srichterthen in my timezone it would be February 1, 200620:18
srichterI think it would be ok, if the commendation always shows it was created on February 2, 200620:19
srichteralso, we are talking about small schools here, so server tz == user tz20:19
ignaserr the problem is - that more likely scenario is - i am making a commendation 2006-02-02 and seeing it listed under 2006-02-01 in the list20:19
srichterand commendations is a demo package anyways, though it should document the right way of course20:19
ignasbecause iirc many unix/linux servers are using UTC as the default timezone20:20
srichteras I said, I did not even think about it, so feel free to change it to whatever is right20:20
srichterthen I at least know where to look the next time I am dealing with TZs20:21
ignasso which one is *righter* UTC or *application timezone* ?20:21
ignasguess should talk to th1a about these20:22
ignas:/20:22
srichteruser timezone is more correct20:24
ignasuser as in - the currently logged in user20:24
ignasthe principal20:25
srichtermmh, I guess it should see that it is Feb 2 for the user that did input the date and just always display Feb 220:25
srichteryes20:25
srichterwell, I take that back with the user; I think application timezone is pretty good20:25
ignasi guess the *right way* is storing whole UTC timestamp, and displaying it according to user preferences20:26
ignasonly the date part20:26
ignasso no info is lost, and it is easy to fix the code ;)20:26
srichterok20:29
th1aOK... back from my shower.20:33
ignasi guess i should write up some guidelines20:33
ignasfor datetime/date/timezone usage20:33
ignasin schooltool20:33
th1aignas:  That's exactly what I was thinking in the shower.20:34
th1aCommendations is tough in part because it is a trivial case.20:34
th1aSo nobody ultimately cares.20:34
th1aLet's think about something more important.20:34
ignasat the moment one guideline - "Store timezone('utc').localize(datetime.datetime.utcnow()) not the date in ZODB"20:35
th1aIf I'm a teacher, and I mis-set my personal timezone, when I enter attendance, it should be stored in the school's timezone.20:35
th1aAlthough, if I'm not mistaken, we can't explicitly set the timezone of the school at this point?20:36
ignaswe have "application timezone"20:36
ignasthough - you can set timezone to anything you want20:36
ignasyou will not change the "real time" of the event20:36
ignasyou might mess up the datetime.date20:37
ignasthat's why we should never store it in the ZODB20:37
th1aOK.  Where do you set application timezone?20:37
ignasclick on Manager in the breadcrumbs20:38
ignasclick Site prefferences20:38
ignasiirc20:38
ignasit is the application timezone setting, which means - untimezoned things like timetables, term end/start will act according to it, or are already doing that20:39
th1aOK.  That's in the trunk but not the releases.20:39
ignasyes20:39
th1aSo basically, the tradeoff is this:20:40
th1aIf a person is working outside the school's timezone, from there perspective, sometimes unexpected things will happen.20:40
th1aFrom their perspective.20:41
ignasnot really20:41
th1aBut everything will look right to the user in the regular timezone?20:41
ignasi don't think we have any glitches20:41
ignasi mean - i am working on bugs that app timezone enables fixes for20:42
ignasthey were flaged already because they were triggered by users not being in UTC20:42
th1aIf I can stop trying to think about this, I will happily do so.20:42
th1aignas:  Are there any design decisions to be made then?20:43
th1aThat you need my opinion on?20:43
ignasnot at the moment, there might appear some ... like - when i should use the user timezone and when i should use app timezone20:43
ignasbut not any i am aware of at the moment20:43
th1aWhen you say "use" what do you mean?20:43
ignasan example from the past:20:44
ignastimetable events had no timezone20:44
ignasquestion was - when should they be ?20:44
ignasanswer was - application timezone should be used for timetable events20:44
ignasas timezone support is flaky in some parts, i might find more places that are not using timezones or are using wrong ones20:45
th1aOK.20:46
*** shapr has quit IRC20:56
*** mgedmin has joined #schooltool21:00
ignasth1a, just found such a place21:05
th1aGo ahead.21:05
ignasth1a, when one is adding an emergency timetable change21:05
ignasone should see the today of his own or app ?21:06
th1aWhich day is displayed?21:06
ignasat the moment - the server date today21:06
ignasuser should see the today of the application i guess21:07
th1aYes.21:07
ignasthis stuff is confusing :/21:08
ignaspoorly configured schooltool might have usability problems ...21:08
ignasas probably any application ...21:08
ignasmaybe we should display the application timezone in the user preferrence dialog, to give them a hint21:09
th1aDo we have anything at this point that sets new users to the application timezone by default?21:10
ignasno21:10
ignasall users start with UTC iirc21:10
th1aI think that's a major bug.21:10
th1aWhy don't you implement that.21:11
ignasas soon as i'll finish with the timezone mess etria left21:11
th1a:-(21:12
th1aLessons learned, at least.21:12
ignastimezones are difficult, and tricky even if they don't look like that21:12
ignasdatetime has misleading API21:12
th1aUltimately, timezone support was a mistake.21:13
th1aBut it was kind of inevitable once we decided to create SchoolBell.21:13
ignaswell - it is difficult to implement/fix something you don't understand, now that i think that i *do* understand, it seems fixable21:14
ignasin a day or two21:15
ignasor three21:15
ignas;)21:15
ignasthough at the moment i am making it technically _correct_ not _good_21:16
th1aThe difference is?21:16
ignasif users will ask - "Why are events jumping when DST kicks in?" we will be able to answer - "Works as designed", not "It's a bug that was reported 5 times already, sorry."21:17
ignas;)21:17
ignasthere is a difference between a code that was intentionally written to behave in an acceptable manner, and the code that has small unintentional bugs left in there because of ignorance21:18
th1aI see.21:22
*** alga has quit IRC21:26
*** ignas has quit IRC21:53
*** auxesis has quit IRC22:33
*** auxesis has joined #schooltool22:39
*** mgedmin has quit IRC23:08
*** wrobel` has quit IRC23:10
*** jinty has joined #schooltool23:10
*** Aiste has joined #schooltool23:38
*** didymo has joined #schooltool23:58

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