Sunday, 2012-09-23

*** Joins: paulr (~IceChat09@cpc1-enfi15-2-0-cust580.hari.cable.virginmedia.com)01:33
*** Joins: e66 (~quassel@27.147.181.37)01:59
*** Joins: dhx1 (~dhx1@60-241-62-124.tpgi.com.au)05:12
*** Joins: EPG (~EPG@pC19EB788.dip.t-dialin.net)05:50
EPGim trying to implement some kind of approval of issue reports. i have an anonymous reporter account enabled, issues are private by default (approval would be setting them to public by an admin). first problem was that the anonymous user could access his own (private) reports, i solved this by checking user id in access_has_bug_level(). However anonymous can still _list_ the private bugs. where can i prevent this?05:55
EPGok, modifiying $t_public_view_state_check did the job06:31
EPGget_bugnotes_count seems to be dead code07:20
EPGhow can i clear the bug_cache?07:33
*** Joins: romer628 (~romer628@cpe-76-180-59-236.buffalo.res.rr.com)10:02
*** Parts: romer628 (~romer628@cpe-76-180-59-236.buffalo.res.rr.com) ()10:03
*** Joins: kirillka (~Miranda@48-230-55-95.baltnet.ru)10:32
*** Quits: e66 (~quassel@27.147.181.37) (Read error: Connection reset by peer)10:44
GitHub9[mantisbt] rombert pushed 1 new commit to master-1.2.x: http://git.io/Yqtn5g11:12
GitHub9[mantisbt/master-1.2.x] Fix #14737: Date filters do not work with match type = any condition  - Robert Munteanu11:12
GitHub137[mantisbt] rombert pushed 1 new commit to master: http://git.io/GWe3ug11:12
GitHub137[mantisbt/master] Fix #14737: Date filters do not work with match type = any condition  - Robert Munteanu11:12
*** Quits: kirillka (~Miranda@48-230-55-95.baltnet.ru) (Quit: kirillka)11:23
*** Joins: kirillka (~Miranda@48-230-55-95.baltnet.ru)11:24
GitHub71[mantisbt] rombert pushed 1 new commit to master: http://git.io/40l1nA12:17
GitHub71[mantisbt/master] bug_report: fix selection of default status and resolution - Robert Munteanu12:17
GitHub23[mantisbt] rombert pushed 1 new commit to master-1.2.x: http://git.io/_putyw12:17
GitHub23[mantisbt/master-1.2.x] bug_report: fix selection of default status and resolution - Robert Munteanu12:17
*** Quits: kirillka (~Miranda@48-230-55-95.baltnet.ru) (Quit: kirillka)12:24
*** Joins: kirillka (~Miranda@48-230-55-95.baltnet.ru)12:25
*** Quits: kirillka (~Miranda@48-230-55-95.baltnet.ru) (Quit: kirillka)12:50
paulrwheres dregad13:05
*** Joins: dregad (~dregad@203-236.193-178.cust.bluewin.ch)13:37
paulrlo13:37
dregadheard a cow on my blackberry ;)13:37
paulrwhat db backends do you have access to ?13:37
paulrblackberry eww13:37
paulri've got a new android phone13:38
dregadnot my choice13:38
dregadcompany phone13:38
dregadits free ;)13:38
dregadat home I have mysql and postgres13:38
paulri was more thinking the obscure ones13:38
paulr:P13:38
dregadat work, oracle13:39
paulri've just dumped db_prepare_bool from db brnach13:39
dregadthat will kill postgres support unless you have a smart replacement13:40
paulrnono13:41
paulrfor my branch13:41
paulrso oracle, you can test?/code?13:43
dregadin theory yes but atm the setup on my dev box is borked13:44
dregadand I lack of time to fix it13:45
*** Quits: EPG (~EPG@pC19EB788.dip.t-dialin.net) (Quit: EPG)13:47
paulri see13:49
paulrwell, i might upgrade my work setup to mantis 2 soon13:49
dregaddid you get a chance to speak with dhx113:49
dregadhe's been back for a few days now13:49
dregadand i really think the 2 of you should put your work together and pull at the same rope13:50
paulri'd probably be inclined to dump "1.3" and "next"13:53
dregadaccording to dhx1, next contains a lot of your initial work on your 2.0 branch and he mentioned cherry-picking the rest13:56
paulrthere's around 250 commits since then13:57
dregadwhat if they're all applied13:58
paulrwell, gl with that13:58
paulralso, some (~3-4 at last count) of the commits in 1.3/next should be reverted IMO13:59
paulrdo you have any thoughts on exceptions?14:10
dregadlike them14:12
dregadmuch easier and cleaner programming14:12
paulrwould you say we should have more or fewer?14:12
paulrer14:12
paulri.e. should we have like14:12
paulruser not found exception14:13
paulrproject not found14:13
paulror just14:13
paulr'not found'14:13
dregadshort answer is "it depends"14:13
dregadgeneric = fewer of them = less maintenance14:14
dregadbut may make handling them more complex14:14
dregadthere's pros & cons for both sides of arguments14:15
paulri'm thinking instead of using $g_foo for config14:52
paulr$config['foo']  might be more sensible14:52
paulrbut can't decide14:52
dregadwhy change?14:55
dregad(i like arrays but it seems like a huge effort for little benefit)14:55
paulra) fewer global variables14:56
paulrb) could cache the global config array for performance14:56
dhx1paulr, dregad: hi :)14:56
dregadhi david14:56
paulrc) for 2.0, would be nice to get rid of global variables14:56
paulrdhx1: your still alive then ;p14:57
dregadi said the same thing last week ;)14:57
dhx1haha14:57
dhx1paulr, what part of 'next' needs to go IMO... fine granularity exceptions?14:58
dhx1IYO14:58
paulrthe file system layout14:59
dhx1agreed that can change14:59
dhx1I wasn't going to worry about that sort of stuff until closer to an eventual release though15:00
paulrshould a global $config array be called $config15:00
* paulr ponders15:00
paulri'm guessing 'yes'15:01
paulri.e. you'd use15:01
paulr$config['hostname']= 'localhost';15:01
dhx1is an array the right data structure?15:01
paulrinstead of $g_config15:01
dhx1remember that project and user-specific config may override it15:02
dhx1so a lot of the overhead is in those checks15:02
paulrthat gets pulled out of db and stored as an array atm though right? :P15:02
paulrso atm, we have something like15:02
paulrlets say we want "config1"15:02
paulrwe call config_get("config1");15:03
paulrthat goes15:03
paulr$user = currentuser();15:03
paulr$project = currentproj();15:03
paulrthen basically goes15:03
paulrif $cachedconfig[$user][config1]; return;15:03
paulrif $cachedconfig[$project][config1]; return;15:03
paulrok, we didn't find so:15:03
paulrreturn get_global15:03
paulrwhere that does return $GLOBALS['g_' . config1]15:04
dhx1I see what you mean15:04
paulrso i'd be proposing we do exactly the same but make get_global just do15:04
paulrreturn;15:04
paulror more15:04
paulrargh15:04
paulrget global would be cachedoncfig[-1,-1]15:04
dregadI like doncfigs ;)15:05
paulras a by-product you lose all the global variables15:05
dregadmakes sense15:05
paulrand arguably you could serialize the global config to disk/ram if you didn't want to parse it on load15:05
paulrin terms of "is an array the right type"15:06
paulri'd probably argue that whilst $config->hostname is cleaner to type15:06
paulrdoes it make sense for db values15:07
paulrhaving said that15:07
paulr$config->hostname is less likely to have people cause syntax errors15:07
paulrand pulled from db to an array or object is probably about the same15:07
dhx1syntax/readability is critical IMO15:07
paulrso $config->db_username?15:08
paulrMantisConfig::db_username15:08
paulr$config->username15:12
paulr^ simple15:12
paulrdregad/dhx: makes more sense?15:12
paulr*most15:12
dhx1the only problem is that $config can no longer be used as a local variable15:12
paulr$CFG then15:13
dregadI like the idea of using objects for config15:17
dregadre: naming - $MantisConfig ?15:17
paulrjust need to check i dont break require_api with this15:24
dhx1I'd like to stop adding "Mantis" to variable/class names15:24
dhx1it's a sign that namespacing isn't being used correctly15:24
dhx1other than that, agreed with dregad15:25
dhx1require_api will disappear when everything is converted to objects15:25
dhx1(ie. use autoloading)15:25
dhx1well... not everything will turn into an object... :)15:25
* dregad is not familiar with namespacing15:25
dhx1use \MantisBT\Exception\User\UserNotFound15:26
dhx1etc15:26
dhx1that way you import a small segment of MantisBT (or other library) code at a time15:26
* dregad is reading up on it15:26
dregadin this context, i agree that Mantis prefix doesn't make sense15:28
dregadi was concerned about collision on a common name like 'config'15:29
dregadnamespaces makes that irrelevant15:29
paulrok, that might be quick and easy to do15:34
paulr$t_new_globals = array_diff_key( get_defined_vars(), $GLOBALS, array( 't_existing_globals' => 0, 't_new_globals' => 0 ) );15:36
paulrdhx1: i can ignore that right?15:36
paulras that's for globals defined by class15:37
paulrnot config variabls15:37
paulrwell, might need some proofreading15:44
paulrbut might also be done ;/15:44
paulror well, semi-d one15:44
paulr$MantisConfig->hostname = 'localhost';15:44
paulr$MantisConfig->db_type = 'pdo_mysql';15:44
dregadgotta go - i'm way past bedtime15:45
dregadttyl15:45
paulrmm, me too soon15:45
*** Quits: dregad (~dregad@203-236.193-178.cust.bluewin.ch) (Quit: A fine is a tax for doing wrong. A tax is a fine for doing well.)15:46
*** Quits: dhx1 (~dhx1@60-241-62-124.tpgi.com.au) (Quit: Leaving)15:56
*** Quits: paulr (~IceChat09@cpc1-enfi15-2-0-cust580.hari.cable.virginmedia.com) (Quit: OUCH!!!)16:12
*** Joins: romer628 (~romer628@cpe-76-180-59-236.buffalo.res.rr.com)16:50
*** Parts: romer628 (~romer628@cpe-76-180-59-236.buffalo.res.rr.com) ()16:50
*** Quits: sdfjkljkdfsljkl (~sdfjkljkd@static.96.23.63.178.clients.your-server.de) (Remote host closed the connection)17:00
*** Joins: sdfjkljkdfsljkl (~sdfjkljkd@static.96.23.63.178.clients.your-server.de)17:00
*** Joins: intripoon (~quassel@manz-590f3335.pool.mediaWays.net)18:54
*** Quits: intripoon_ (~quassel@manz-590f0fb4.pool.mediaWays.net) (Ping timeout: 246 seconds)18:57
*** Joins: romer6281 (~romer628@cpe-76-180-59-236.buffalo.res.rr.com)22:07
*** Joins: kirillka (~Miranda@195.242.142.17)22:26
*** Joins: giallu (~giallu@fedora/giallu)23:42

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