Thursday, 29 November 2012< ^ >
arjan has set the subject to: Zotonic - the Erlang Content Management Framework
Room Configuration

[00:19:49] Maas leaves the room
[08:55:16] andreas.stenius joins the room
[08:56:01] Maas joins the room
[09:49:20] Maas leaves the room
[09:54:33] maas.maarten.zeeman joins the room
[13:05:13] <andreas.stenius> Hi, I've been forced to look at z_db.erl, and have a few notes I'd like comments on...
[13:06:04] <andreas.stenius> First, in order to be able to avoid sprinkle client code with try/catch, I need to add a {error, Err} -> Err clause to this case: https://github.com/zotonic/zotonic/blob/master/src/dbdrivers/postgresql/z_db.erl#L275
[13:06:41] <andreas.stenius> I think this is "the right thing" to do...
[13:08:36] <andreas.stenius> And as a spin off from this, I looked at the other case's in this file, and think that perhaps this change would be beneficial for q1 as well...?
[13:09:02] <andreas.stenius> oh, bah, now I see that he could just as well have called z_db:equery instead...
[13:09:20] <andreas.stenius> never mind this, then.
[13:10:58] <andreas.stenius> I do have one thing still lurking.. in z_db:transation1/2, the call to pgsql_pool:return_connection/2 isn't guarded in a after clause, so it may not be called under all circumstances...
[13:11:16] <maas.maarten.zeeman> If you need to add exception handling you can also throw it in a transaction/2. Or not?
[13:12:30] <maas.maarten.zeeman> Indeed. That should be rolled into a with_transaction I think
[13:12:31] <andreas.stenius> No, I want to avoid having to handle exceptions, That was the whole point. The thing is already in a transaction, but I may get an occassional error, which is to be expected, and taken care of
[13:12:45] <maas.maarten.zeeman> aha
[13:12:53] <andreas.stenius> Yeah, I was just thinking that it might be a good idea..
[13:13:46] <andreas.stenius> but since the q call is simply a wrapper for a equery call unwrapping the results, could just as well skip that step... :)
[13:14:02] <andreas.stenius> and call equery directly
[13:15:35] <maas.maarten.zeeman> The db part is tricky. Had the connection pool filled up because of a oom restart of postgres. It was working on the transaction log, but the queries where just fired.
[13:16:56] <maas.maarten.zeeman> brr. it didn't recover on its own.
[13:17:27] andreas.stenius goes to lunch...
[13:17:35] <maas.maarten.zeeman> bon appetit
[13:17:39] <andreas.stenius> :)
[14:12:44] maas.maarten.zeeman leaves the room
[14:12:50] maas.maarten.zeeman joins the room
[14:22:52] Arjan leaves the room
[14:37:13] <Marc Worrell> When you edit a page in the admin: now there is a button to copy one language to another.
[14:37:31] <Marc Worrell> Makes translating easier :-)
[14:37:31] <andreas.stenius> :)
[14:38:00] <Marc Worrell> Had to rename the ids of i18n input/textarea elements
[14:38:21] <Marc Worrell> they were not valid html before "title$ar" is now "title—ar"
[14:38:36] <andreas.stenius> ah, ok
[14:38:50] <maas.maarten.zeeman> 8-)
[14:38:51] <Marc Worrell> couldn't do anything with jquery and the old ids
[14:39:08] <maas.maarten.zeeman> There is a trick for that.
[14:39:23] <Marc Worrell> yes?
[14:39:33] <andreas.stenius> Marc Worrell: do you agree about using with_transaction in z_db:transaction1/2.. ?
[14:39:47] <maas.maarten.zeeman> have to look it up. I have to look it up.
[14:40:01] <andreas.stenius> to make sure the connection is always returned...
[14:40:29] <Marc Worrell> @andreas: sounds fine to me :-) a transaction is a transaction, isn't it?
[14:40:52] <Marc Worrell> @maas recursive lookup?
[14:41:02] <maas.maarten.zeeman> Starting to repeat myself.
[14:41:03] <andreas.stenius> yeah, I meant to write "with_connection" I think it is... :p, but still
[14:41:46] <maas.maarten.zeeman> If you have those id's you can escape the character.
[14:43:11] <maas.maarten.zeeman> #title\$ar would have worked I think.
[14:43:16] <Marc Worrell> Now also on 0.9dev: http://www.mediafonds.nl
[14:44:12] <Marc Worrell> @maas: wow, escaping in ids, the start of the slope downwards
[14:44:20] <Marc Worrell> double \\, triple \\\
[14:44:29] <maas.maarten.zeeman> :-D
[14:44:43] <maas.maarten.zeeman> There are a lot of special characters too.
[14:45:09] <Marc Worrell> And, please sign here for our dear customer and the dutch culture: http://petities.nl/petitie/mediafonds-moet-blijven
[14:45:36] <maas.maarten.zeeman> !"#$%'()*+,./:;?@
[14:45:46] <maas.maarten.zeeman> Already done :-)
[14:45:54] <Marc Worrell> looks like you are cursing :p
[14:46:31] <maas.maarten.zeeman> Had to do escaping. When we sync events some existing ids are just goofy.
[14:49:03] <maas.maarten.zeeman> have to go get the kids from school
[14:49:19] <Marc Worrell> have fun with the kids :)
[14:49:21] <maas.maarten.zeeman> see you tonight at tty
[14:51:29] <Marc Worrell> i hope so, have to finish some work as well
[15:36:06] <maas.maarten.zeeman> Pff. Yes, me too. Almost done for the day. Multi frame synchronization.
[16:22:26] maas.maarten.zeeman leaves the room
[16:35:23] maas.maarten.zeeman joins the room
[18:13:01] maas.maarten.zeeman leaves the room
[18:51:59] maas.maarten.zeeman joins the room
[18:52:40] <maas.maarten.zeeman> Hmm. Not going to cross functional this evening. Bummer.
[20:27:39] <Marc Worrell> same bummer here
[20:27:45] <Marc Worrell> work…. work… work...
[20:27:50] <Marc Worrell> and Mr T was a bit late to bed
[20:34:09] <Marc Worrell> Hei Maas, vraagje
[20:34:32] <Marc Worrell> For Women on Waves I need some popup with lots of text
[20:34:57] <Marc Worrell> So a dialog is not really good.
[20:35:21] <Marc Worrell> I was thinking of something like an "overlay" - with scroll for content
[23:06:17] maas.maarten.zeeman leaves the room
[23:09:11] maas.maarten.zeeman joins the room
[23:13:25] <maas.maarten.zeeman> Something like fancybox?
[23:13:25] andreas.stenius leaves the room
[23:29:21] maas.maarten.zeeman leaves the room
Powered by ejabberd Powered by Erlang Valid XHTML 1.0 Transitional Valid CSS!