Monday, 2011-09-12

*** Joins: soustruh (~Miranda@169.211.broadband13.iol.cz)02:30
*** Joins: Rixie (~Rixie@188.177.20.182)02:38
*** Joins: giallu (~giallu@mail.moldiscovery.com)02:45
*** Quits: giallu (~giallu@mail.moldiscovery.com) (Changing host)02:45
*** Joins: giallu (~giallu@fedora/giallu)02:45
*** Quits: giallu (~giallu@fedora/giallu) (Ping timeout: 240 seconds)02:55
*** Joins: giallu (~giallu@fedora/giallu)03:07
*** Joins: dregad (~dregad@wwwgate1.merck.de)03:10
*** Joins: asm89 (~asm89@unaffiliated/asm89)03:25
*** Joins: dhx1 (~anonymous@60-242-108-164.static.tpgi.com.au)03:39
*** Quits: asm89 (~asm89@unaffiliated/asm89) (Remote host closed the connection)04:34
*** Joins: asm89 (~asm89@unaffiliated/asm89)04:39
* dregad pings dhx105:23
dregadhi David05:23
dregadback in august I asked you to have a look at some changes to admin checks05:24
dregadyou replied on mailing list, that I should use htmlspecialchars() to escape values printed to user05:26
*** Joins: sgimeno (~sgimeno@163.117.206.10)05:28
dregadreferring to display of full path in the error message in case of failed check05:31
dregadI'm not sure if I should encode the string that is assigned to the info array,05:35
dregador if the string should be escaped by check_print_test_row function05:35
dregadwhich seems more generic, but maybe there are other implications that I'm not aware of05:36
dregadwhat is your advice05:37
dhx1dregad: hey05:48
dhx1dregad: do you have a changeset on github?05:49
dregadthe code you have already reviewed https://github.com/dregad/mantisbt/tree/improve-checks-13x05:51
dhx1ah yes05:52
dhx1dregad: I'd probably prefer escaping to be done in check_print_info_row() etc functions05:53
dhx1dregad: of course, some of our checks may be sending through HTML characters (italics, etc)... so we'd need to remove that formatting05:54
dregadsomething like this05:54
dhx1hmmm05:54
dhx1maybe not05:54
dregadecho '<br /><em>' . htmlspecialchars( $p_info[$p_pass] ) . '</em>';05:54
dhx1we're placing useful links in those messages05:54
dhx1so it might be best to use htmlspecialchars(...) on a per-check basis when user supplied input is given05:55
dhx1paths, configuration values, etc05:55
dregadok05:55
dhx1I'll probably rewrite admin/check in the next branch anyway05:56
dregadshould I bother with this fix then ?05:56
dhx1I think so05:58
dhx1given that most of the work is done05:58
dhx1just needs to htmlspecialchar() escaping from what I can see05:58
dhx1https://github.com/dregad/mantisbt/commit/3d4d79e34e38b6c8c13d2e2c0a858b9f0cc4d62b#L0R8105:58
dhx1and line 8305:58
dhx1if merging, cherry-pick instead05:59
dhx1of merging05:59
dhx1because that branch will bring in extra stuff we don't want (12x, etc)05:59
dregad:-O05:59
dregadI know05:59
dregadbut this code is mostly copy/paste from similar, existing checks05:59
dregadnevermind that last comment - before you were always printing a string (the config name) and not the actual config's value06:02
dhx1ok :)06:08
dregaddhx1: sanity check please ?06:45
dregadhttps://github.com/dregad/mantisbt/compare/master...improve-checks-13x06:45
dregad(note - this is a forced update, 12x is gone - and I'll make this a single commit to Master after)06:47
dhx1looks ok to me07:02
dhx1my only comment is that htmlspecialchars() should ideally be wrapped around each variable07:03
dhx1rather than the whole string07:03
dhx1more of a code readability and maintainability issue07:03
dhx1it makes it more obvious which variables are 'unsafe'07:03
dregadok, I'll fix that07:14
dregaddone07:24
dhx1:)07:28
dhx1feel free to commit the resulting patch ;)07:28
dhx1I have one I'm going to commit after you07:28
dregadactually I meant to keep it for my own benefit only :-P07:28
dhx1haha07:31
GitHub88[mantisbt] dregad pushed 1 new commit to master: http://git.io/X7FhqQ07:45
GitHub88[mantisbt/master] Improve directory validation in admin checks - Damien Regad07:45
dregadhere you go07:45
dhx1thanks07:48
dregaddhx1 - if you get the chance, can you also let me know which is the better branch to fix the attachment indicator issue that we discussed some days ago08:12
dregad1- https://github.com/dregad/mantisbt/commits/fix-attach-column-1327608:13
dregad2- https://github.com/dregad/mantisbt/commits/remove-show_attachment_indicator08:13
dregadI think 2 is better08:13
dhx1dregad: I prefer removing the unwanted configuration value08:45
dhx1however I'm not sure whether we can merge attachment/attachment_count... still have to look into it08:45
dregadi did not find any diverging uses, nor issues in my testing08:47
dregadlet me know if you think otherwise08:48
dhx1ok, will try to get onto it tomorrow08:56
dhx1sorry about the delay08:56
dhx1have been spending all my MantisBT time on the 'next' branch08:56
dregadno worries08:56
dregadI'm trying to clean up my backlog08:56
dregadnew responsibilities coming up, so likely to have less time to spend on Mantis at work :(08:57
dhx1ah :(09:03
dhx1thanks for all your help recently09:03
dhx1I'll try to help with the backlog09:04
dregadi'll still be around don't worry09:15
dhx1good to hear :)09:15
GitHub140[mantisbt] davidhicks pushed 20 new commits to next: http://git.io/iZxj2g09:15
GitHub140[mantisbt/next] Implement IssueReadOnly exception - David Hicks09:15
GitHub140[mantisbt/next] Implement RelationshipNotFound exception - David Hicks09:15
GitHub140[mantisbt/next] Implement RelationshipLoopbackDisallowed exception - David Hicks09:15
dhx1almost finished replacing the old error system... just a few exceptions to go09:16
dhx1then some rework of the error handler09:16
dhx1next up: focus on Paul's database work (a lot to do)09:17
dhx1after those items I'd like to merge next into master (after extensive testing)09:17
dhx1and then continue with some other project(s) with MantisBT (mostly code modernisation to OO)09:18
*** Joins: paul___ (52c6fa08@gateway/web/freenode/ip.82.198.250.8)09:25
dhx1paul___: hi *waves*09:26
GitHub189[mantisbt] davidhicks pushed 1 new commit to next: http://git.io/uIYtCQ09:26
GitHub189[mantisbt/next] Use correct error constants in CustomField* exceptions - David Hicks09:26
*** Joins: JonMarkGo (~Jon@ool-18bfe16f.dyn.optonline.net)09:33
jreesedhx1: you've been busy :P09:33
dhx1jreese: :)09:34
dhx1jreese: they're all small commits though09:36
dhx1(which makes it easy to revert anything that's wrong)09:37
jreeseyeah09:38
dhx1jreese: while you're here, I was wondering why we went with phputf8 over PHP's built in mbstring support?09:41
dhx1jreese: was it purely a case of mbstring not being in standard PHP installations prior to PHP 5.2 or 5.3 or whatever?09:41
jreesebecause the mbstring module isn't guaranteed to be available, so we fall back to phputf8 when mbstring isn't installed09:41
dhx1oh my mistake, it's still not a standard (built-in) extension09:42
dhx1I thought they'd added it to PHP 5.309:42
jreeseI don't know why they've haven't made it part of the core build, it's pretty dumb imo09:43
dhx1probably because PHP6 with it's superhero UTF8 abilities was always just around the corner? ;)09:44
jreeselol, right09:44
jreeseseems PHP6 == Perl6 these days09:44
dhx1they gave up AFAIK... and are working on incremental 5.x series updates09:44
dhx1the good news is that they're finally switching to git!09:44
jreeseyeah, except they're still munging it to work with their stupid development workflow09:45
dhx1the bad news... it's still PHP... I'd love type safety, function overloading, etc...09:45
dhx1hah09:45
jreesedhx1: it already has type safety of function arguments if you want it09:45
jreesegranted, it's not used by any of teh core APIs, but it is available09:46
dhx1jreese: yeah it's got some limited support here and there09:46
* dhx1 wonders why people don't just use C++ (a simple version) with a library that does FastCGI, etc handling09:47
dhx1other than no compilation needed for development work...09:48
jreesesetting up fastcgi is th esort of effort that makes PHP so simple to deploy by comparison09:48
jreeseand PHP's built-in templating system (ie, <?php ?>) is its biggest feature09:49
jreeseand it's core library is already familiar to anyone who knows C or Perl09:49
dhx1although it's funny that many PHP users try to avoid that feature by using overly complex data model abstractions09:50
jreesenot that I think PHP is a good language09:50
dhx1the only thing I like is the preg_ functions ;)09:50
jreesebut deploying PHP is fantastically easy with apache/mod_php09:50
jreeseeither way, I've gotten to teh point where I won't personally choose PHP for anything I write in the future09:51
dhx1which are standard in C++11 (informal name at the moment): https://secure.wikimedia.org/wikipedia/en/wiki/C%2B%2B11#Regular_expressions09:51
jreeseall of PHP's warts are more annoying than the deployment hoops of other languages09:51
dhx1mod_php is discouraged anyway09:52
jreesedhx1: C++ has always had PCRE09:52
dhx1FastCGI is _the_ way09:52
dhx1jreese: true, but as a separate library (libpcre, Boost, whatever)?09:52
jreeseit's only the way if you prefer complicated deployment09:52
dhx1distributions have made it fairly easy09:53
jreeseyou can't just drop php files into a webroot and watch it work if you're using fastcgi09:53
dhx1I can?09:53
jreesenot for any sort of multi-vhost setup, afaik09:53
dhx1unless I misunderstood09:53
jreesethe moment you want more than one vhost, your fastcgi setup starts ballooning in complexity09:54
dhx1you should still be able to do that... but you'd probably need to run multiple pools of FastCGI daemons under a different user account for each website09:54
jreeseyes, that's my point09:54
dhx1yeah09:54
dhx1in the days of virtual private servers though, shared hosting is less common09:54
jreeseI run 12 different vhosts on my vps, I don't want to run 8 different fastcgi pools09:55
dhx1you don't have to... it's more of a security/separation issue09:55
dhx1so websites can't access each other on the disk09:55
jreeseesp when mod_php requires zero configuration, and APC basically makes it fast enough that fastcgi doesn't make that big of a difference09:56
jreesealso, tbh, I get better memory performance from apache/mod_php than apache/fastcgi09:57
*** Parts: Rixie (~Rixie@188.177.20.182) ()09:58
dhx1the main reason mod_php is discouraged (AFAIK) is for the same benefit you mentioned - shared memory09:59
dhx1again I think it is mostly from a security perspective... shared memory = shared PRNG, ability for all your sites to come to a crashing halt at once, etc09:59
jreesewell, using multiprocess apache, one crash doesn't bring down the whole apache instance, and shared prng is the least of my worries tbh10:00
dhx1yeah10:00
jreesemy point is just that I don't want to spend hours setting up and maintaining nginx/fastcgi setups when apache/mod_php does it all by default, and imo performs just as well10:02
jreesemaybe if I was paid to set up and maintain webservers, I'd think differently10:02
dhx1yep10:02
jreesemodwsgi is easier to deal with than fastcgi, and it still has a lot of pain points10:03
jreeselike needing to touch the .wsgi file to get the webserver to reload the instance when I make changes in development10:04
jreeseI was actually tempted to write a script that would just sit around in a webroot looking for changes to .py file so that it could automatically touch the .wsgi file10:05
dhx1hah, it must use caching10:09
dhx1should be able to turn that off so that each reload hits the disk?10:09
jreeseit's not caching10:09
jreeseit has to do with the way python/ruby types of systems work; when modwsgi loads the app, it compiles everything and starts a long-running process that waits for the webserver to proxy requests to it10:10
jreeseso by default, that wsgi container never restarts until the server restart10:11
jreeseat least in modwsgi, the only option is to have it restart when the .wsgi file is touched, because it can't know if any of the other files are touched, because wsgi doesn't force the .py files be anywhere that the server knows about10:12
jreeseand it seems to be that way on every wsgi module/container, even with nginx10:12
dhx1aha10:12
jreeseideally, during development, modwsgi would start up the container on each request, and then immediately stop it, but that would be a lot of work in cases where web apps use a lot of ajax or other sorts of constant interaction10:14
jreeseso the best they can really do is watch tho .wsgi file for changes to know when to reload the container10:14
jreeselong-polling message systems like comet, etc would provide even more issues with that sort of approach10:15
dhx1hmm, messy ;)10:15
jreesethe real problem is developing on a server that's also a production box :P10:15
dhx1if they're running on a Linux system they should at least use inotify to monitor files on the disk for changes10:16
*** Quits: soustruh (~Miranda@169.211.broadband13.iol.cz) (Quit: visit http://wormscesky.cz)10:16
jreesewhen testing on a local dev machine, you generally use a purpose-bulit development server/container like paste or cherrypy, but then you may have to deal with differences between your development and deployment envirnoments10:16
jreesedhx1: but like I said, the web server has no way to know what files are being used by the container, because it's basically running an externel python interpreter to run the webapp10:17
jreeseand an `import foo` in python can pull files from just about anywhere depending on where modules are installed, your python's PATH environment, etc10:18
jreesethe only way the server can know what files are being used is if it implements a python interpreter itself to parse all the files :P10:19
dhx1hmm10:19
jreesecomplicated systems are complicated :P10:19
dhx1:)10:20
dhx1on that note, I'm out10:20
dhx1will be around later to finish off the work on error handling in the 'next' branch10:20
jreesecheers10:20
dhx1until later10:20
dhx1cya10:20
*** Quits: paul___ (52c6fa08@gateway/web/freenode/ip.82.198.250.8) (Quit: Page closed)10:21
*** Joins: T-One (~T-One@213.33.91.2)10:22
T-Onehello10:22
T-Onesmall prolbem here, i've copied a mantis 1.1 with all the config files and attachments + sqldb to a new server, it looks like mantis works quite well but all the attachments are just given as (attachment missing)10:24
jreeseT-One: if you changed filesystem paths, you will need to manually update your database's attachment table to fix the paths it has stored10:24
T-Onei didnt change the file path, its given as " $g_absolute_path_default_upload_folder = 'upload/';" in the config and i can access this path directly via http://<ip>/upload10:26
T-Onein the mysql-db all those files are listed in the mantis_bug_file_table with values like "upload/29ffc78295273f9426ecf1f541c46ac1"10:27
jreeseT-One: I'm not sure offhand, I just know that that moving mantis aronud can cause it to be looking in the wrong place for attachments on disk =\10:30
jreesesorry10:30
T-Onecould it be a permission problem too?10:34
jreesepossibly, the webserver account will need read access to the files10:34
jreeseor whatever account the php files are executed as10:34
T-Oneah ok, just read access, thats given....10:35
*** Quits: dhx1 (~anonymous@60-242-108-164.static.tpgi.com.au) (Remote host closed the connection)10:42
*** Quits: asm89 (~asm89@unaffiliated/asm89) (Quit: bye!)11:16
T-Onecould someone please check the layout of their diskfile part in the bug_file_table11:26
T-Onemine are given this way: upload/beide\dman\ab8225bb66586f8c8bfa7f542b5ad15911:26
T-Oneand i think thats not correct11:26
T-Onethey should be saved as upload/beide/dman/ab8xxxxx11:26
T-Oneyep got it, file paths are incorrect11:29
T-Onebecause the first install is from a windwos apache server, and then migrated to linux....11:30
dregadjreese: hi12:14
dregaddo you have any idea why, in 1.3.x, I get "XML Parsing Error: not well-formed", whenever an error occurs (looks like there is an extra </div> at the end)12:16
dregadNote- I have E_USER_ERROR => 'halt' (no problem if I set it to 'inline')12:21
*** Quits: giallu (~giallu@fedora/giallu) (Ping timeout: 260 seconds)12:42
*** Quits: siebrand (~siebrand@5353A6DC.cm-6-4c.dynamic.ziggo.nl) (Quit: siebrand)13:12
*** Joins: siebrand (~siebrand@5353A6DC.cm-6-4c.dynamic.ziggo.nl)13:13
*** Joins: kirillka (~Miranda@37-224-55-95.baltnet.ru)13:33
jreesedregad: because dhx thought it was a good idea to use a strict XHTML doctype, even though I urged him otherwise :P13:47
*** Quits: DarkStar851 (~DarkStar8@142.163.169.117) (Read error: Connection reset by peer)14:15
*** Joins: DarkStar851 (~DarkStar8@142.163.169.117)14:15
*** Joins: Paul24 (~IceChat09@2001:470:9310:aaaa:f5bf:62c:1767:fa95)14:21
*** Joins: giallu (~giallu@fedora/giallu)14:27
*** Joins: cgraefe (5f75d16b@gateway/web/freenode/ip.95.117.209.107)14:52
*** Quits: wolog (~wolog@wolog.info) (*.net *.split)15:24
*** Quits: brucelee (~adsfasdf@c-67-160-201-8.hsd1.ca.comcast.net) (*.net *.split)15:24
*** Quits: PennStater (~Aaron@unaffiliated/pennstater) (*.net *.split)15:24
*** Joins: brucelee (~adsfasdf@c-67-160-201-8.hsd1.ca.comcast.net)15:24
*** Joins: PennStater (~Aaron@unaffiliated/pennstater)15:25
*** Quits: PennStater (~Aaron@unaffiliated/pennstater) (Excess Flood)15:25
*** Joins: PennStater (~Aaron@unaffiliated/pennstater)15:25
*** Quits: PennStater (~Aaron@unaffiliated/pennstater) (Excess Flood)15:25
*** Joins: PennStater (~Aaron@unaffiliated/pennstater)15:26
*** Quits: PennStater (~Aaron@unaffiliated/pennstater) (Excess Flood)15:26
*** Joins: PennStater (~Aaron@unaffiliated/pennstater)15:27
*** Quits: PennStater (~Aaron@unaffiliated/pennstater) (Excess Flood)15:27
*** Joins: PennStater (~Aaron@unaffiliated/pennstater)15:27
*** Quits: PennStater (~Aaron@unaffiliated/pennstater) (Excess Flood)15:27
*** Joins: wolog (~wolog@wolog.info)15:30
*** Joins: PennStater (~Aaron@unaffiliated/pennstater)15:34
*** Joins: soustruh (~Miranda@ip-86-49-121-75.net.upcbroadband.cz)16:08
*** Joins: asm89 (~asm89@unaffiliated/asm89)16:32
*** Joins: polariw (~polariw@50-73-189-218-pennsylvania.hfc.comcastbusiness.net)16:37
*** Quits: polariw (~polariw@50-73-189-218-pennsylvania.hfc.comcastbusiness.net) (Quit: Leaving)16:46
Paul24mo17:04
*** Quits: asm89 (~asm89@unaffiliated/asm89) (Quit: bye!)17:20
*** Joins: Ragnor (~Ragnor@dslb-092-072-244-211.pools.arcor-ip.net)17:40
*** Quits: soustruh (~Miranda@ip-86-49-121-75.net.upcbroadband.cz) (Quit: visit http://wormscesky.cz)18:20
*** Quits: Paul24 (~IceChat09@2001:470:9310:aaaa:f5bf:62c:1767:fa95) (Quit: Clap on! , Clap off! Clap@#&$NO CARRIER)18:25
*** Quits: cgraefe (5f75d16b@gateway/web/freenode/ip.95.117.209.107) (Ping timeout: 252 seconds)18:38
*** Quits: giallu (~giallu@fedora/giallu) (Ping timeout: 260 seconds)19:12
*** Quits: scribe9343423 (~scribe934@static.96.23.63.178.clients.your-server.de) (Remote host closed the connection)20:00
*** Joins: scribe9343423 (~scribe934@static.96.23.63.178.clients.your-server.de)20:00
*** Joins: ComputerNewbie (~adsfasdf@c-67-160-201-8.hsd1.ca.comcast.net)21:22
*** Quits: brucelee (~adsfasdf@c-67-160-201-8.hsd1.ca.comcast.net) (Ping timeout: 260 seconds)21:25
*** Quits: kirillka (~Miranda@37-224-55-95.baltnet.ru) (Read error: Connection reset by peer)21:36
*** Joins: kirillka (~Miranda@37-224-55-95.baltnet.ru)21:36
*** Joins: ToffeePops (~chatzilla@202.20.3.13)22:41
*** Quits: JonMarkGo (~Jon@ool-18bfe16f.dyn.optonline.net) (Ping timeout: 250 seconds)23:51

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