[06:51] <TheMue> morning
[06:53]  * davecheney waves
[06:53] <davecheney> TheMue: https://codereview.appspot.com/6203083
[06:53] <davecheney> coming along
[06:54] <davecheney> http://paste.ubuntu.com/998421/
[07:33] <rogpeppe> TheMue, davecheney: yo!
[07:33] <TheMue> rogpeppe: Yo'  man.
[07:36] <rogpeppe> davecheney: looking good. one little question: is it possible to start a machine that's already been created?
[07:36] <rogpeppe> davecheney: i mean, will we ever want to actually do that?
[07:37] <davecheney> rogpeppe: good question, curretly the start machine and create machine.loop are closely tied
[07:38] <davecheney> similarly when a stop is successful, the machine will regestier itself so i can't accept more messages
[07:38] <davecheney> *deregister
[07:38] <rogpeppe> davecheney: if we *don't*', then i'm not sure there's a need for the "start" message - we can just start when the machine is created.
[07:38] <davecheney> rogpeppe: true, it's probably overengineered as it stands now
[07:38] <davecheney> i'm not doing any more work on it this evening
[07:39] <rogpeppe> davecheney: and the loop becomes a single channel receive...
[07:39] <davecheney> i'm tyring to fix the tests on https://code.launchpad.net/~dave-cheney/juju/go-watch-machines-topology/+merge/106294
[07:39] <rogpeppe> davecheney: cool.
[07:42] <davecheney> rogpeppe: I also have to implement so kind of backoff logic in there
[07:42] <rogpeppe> davecheney: yeah.
[07:42] <rogpeppe> davecheney: that should be straightforward though - the goroutines mean no state machine is necessary, which should make the logic nice.
[07:43] <davecheney> <- time.After(5 *time.Seconds) would do in a pinch
[07:44] <rogpeppe> davecheney: yeah. maybe add a touch of randomness too.
[07:45] <davecheney> rogpeppe: i'm thinking a sort of incresing backoff
[07:45] <davecheney> that you kind of hint by saying .Success() or .Failed()
[07:45] <davecheney> which increases or decreasese the delay
[07:45] <davecheney> so if things start to crap out, the delay between attempts grows
[07:45] <rogpeppe> davecheney: if you want to factor out the backoff strategy, you might want to have a look at attemptStrategy in environs/ec2, as a possible API example
[07:46] <davecheney> rogpeppe: that sounds like exactly what I want
[07:46] <rogpeppe> davecheney: it doesn't do exponential backoff
[07:46] <rogpeppe> davecheney: but the API works nicely and was much discussed at the time
[07:46] <davecheney> all the better to reuse it then
[07:48] <rogpeppe> davecheney: mind you, perhaps you never want to give up, in which case perhaps the API is overkill.
[07:51] <rogpeppe> davecheney: BTW did you see, someone discovered my shell? :-) http://debu.gs/entries/inferno-part-1-shell
[07:51] <davecheney> \o/ hacker news
[07:54]  * rogpeppe never looks at hacker news. one stream too many.
[07:56] <TheMue> rogpeppe: Any usage statistics for your shell? Download numbers?
[07:56] <rogpeppe> TheMue: absolutely no idea. probably in the low 20s :-)
[07:56] <davecheney> rogpeppe: i was going to say, it's probably not allowed to drink
[07:56] <rogpeppe> TheMue: noone uses it
[07:56] <TheMue> rogpeppe: Hehe, not even you?
[07:56] <davecheney> rogpeppe: do you know a guy called Chris Collins
[07:56] <rogpeppe> davecheney: occasionally.
[07:57] <rogpeppe> drink?
[07:57] <rogpeppe> davecheney: not that i can remember, why?
[07:57] <davecheney> he's a plan 9 fan here in AU
[07:57] <davecheney> he's also a hardware hoarder like you
[07:58] <rogpeppe> davecheney: problem is inferno lives in a walled environment. it's great for dealing with stuff inside that environment, but not great if you want to interact with the host system
[07:58] <rogpeppe> davecheney: i am *not* a h/w hoarder :-)
[07:58] <rogpeppe> davecheney: i just have a NeXT!
[07:59] <davecheney> rogpeppe: can the watcher.ContentWatcher return "" ?
[07:59] <davecheney> ie, return spuriously
[07:59] <rogpeppe> davecheney: it could return "" if the contents were ""
[08:00] <davecheney> what if ther were "" before
[08:00] <rogpeppe> davecheney: and i think if there's an error, the channel will be closed
[08:00] <davecheney> the problem i'm having atm is the watcher fires once, but the contents don't change
[08:00] <davecheney> so it gets out of phase with what the test expects
[08:00] <rogpeppe> davecheney: if the contents don't change, the watcher shouldn't fire
[08:00] <rogpeppe> davecheney: is that what you want?
[08:00] <davecheney> let me check the channel isn't closing
[08:01] <davecheney> watcher channel closed
[08:01] <davecheney> watcher_test.go:275:
[08:01] <davecheney> sonovabitch
[08:01] <davecheney> ok, let me find out why
[08:06] <davecheney> btw, /usr/share/zookeeper/bin/zkCli.sh
[08:07] <davecheney> ^ i'm sure you guys know about his
[08:07] <davecheney> this
[08:08] <rogpeppe> davecheney: it's really nasty. i wrote my own little cli for it.
[08:08] <davecheney> watcher channel closed: watcher: can't get content of node "/machines": zookeeper: existsw "/machines": zookeeper is closing
[08:09] <davecheney> urg
[08:09] <davecheney> rogpeppe: it is really nasty, you can't set a key that contains whitespace
[08:09] <rogpeppe> davecheney: nice informative error message though :-)
[08:09] <rogpeppe> davecheney: *really*!?
[08:09] <rogpeppe> davecheney: omg that's not nice
[08:09] <davecheney> rogpeppe: really.
[08:10] <davecheney> rogpeppe: i ended up adding code into the provisionng agent to populate zk for me
[08:10] <davecheney> as a test
[08:10] <rogpeppe> davecheney: oh, you mean the cli shell script
[08:10] <rogpeppe> davecheney: i thought you meant zk proper
[08:10] <davecheney> rogpeppe: nah, just zkCli
[08:11] <rogpeppe> davecheney: if you look at it, it's got so much abstraction in it it's not true. not worth using.
[08:11] <rogpeppe> davecheney: definitely written by a jobsworth.
[08:15] <davecheney> rogpeppe: right, problem fixed, was watching the wrong key
[08:15] <davecheney> but now I have another problem
[08:15] <davecheney> ... obtained *state.MachinesChange = &state.MachinesChange{Added:[]*state.Machine{(*state.Machine)(0xf8400c9360)}, Deleted:[]*state.Machine(nil)}
[08:15] <davecheney> ... expected state.MachinesChange = state.MachinesChange{Added:[]*state.Machine{(*state.Machine)(0xf8400daf00)}, Deleted:[]*state.Machine(nil)}
[08:15] <rogpeppe> davecheney: that's an easy one to fix
[08:15] <davecheney> *Machines don't define equility
[08:16] <rogpeppe> davecheney: just expect the pointer type
[08:16] <rogpeppe> davecheney: it's doing DeepEquals, right?
[08:16] <davecheney> mm
[08:16]  * davecheney reads the godoc for gocheck
[08:25]  * TheMue moved his office to the veranda due to the beautiful weather today.
[08:42] <rogpeppe> TheMue: the weather *should* be beautiful today, but the haar has come in. dull again.
[08:44] <TheMue> rogpeppe: We are to far away from coast for haar (about 50 to 80 km, depending on if the Jadebusen, a bay, is seen as coast too). So now it's sunny and warm.
[08:44] <TheMue> s/to far/too far/
[08:44] <rogpeppe> TheMue: we had the first decent sunshine in ages yesterday.
[08:46] <TheMue> rogpeppe: Hehe, that's England. ;) But we're also not very spoiled by the sun here.
[08:46] <rogpeppe> TheMue: it has been *particularly* bad in the last month.
[08:48] <TheMue> rogpeppe: We had a short sunny interrupt in March, but in total the spring is too late this year.
[08:48] <rogpeppe> TheMue: same here. must be the same across most of northern europe, i'd guess
[08:48] <TheMue> rogpeppe: Yep
[12:37] <niemeyer> Hello jujuers!
[12:40] <TheMue> niemeyer: Heya
[13:25] <Aram> evening.
[13:28] <niemeyer> Aram: Heya
[13:49] <andrewsmedina> niemeyer: morning
[13:58] <rogpeppe> niemeyer: hiya
[14:00] <niemeyer> Hey guys
[14:02] <andrewsmedina> niemeyer: I sent the code for review
[14:02] <niemeyer> andrewsmedina: That's great, thank you
[14:02] <andrewsmedina> niemeyer: :D
[14:07] <niemeyer> rogpeppe: ping
[14:07] <rogpeppe> niemeyer: pung
[14:07] <niemeyer> rogpeppe: Yo
[14:08] <niemeyer> rogpeppe: Just wondering what's the status of your branches
[14:08] <rogpeppe> niemeyer: how's tricks?
[14:08] <niemeyer> rogpeppe: You've mentioned you had a pre-req that was being merged in
[14:08] <rogpeppe> niemeyer: yeah, you LGTM'd that and i submitted on friday.
[14:08] <niemeyer> rogpeppe: Is the branch named trunk (!?) ready for review?
[14:08] <niemeyer> rogpeppe: Right, but did you repush the follow up?
[14:08] <niemeyer> s/repush/re-proposed/
[14:08] <rogpeppe> niemeyer: ahem, forgot to branch -m that one
[14:08] <rogpeppe> niemeyer: i *think* that was an orthogonal branch. let me check.
[14:09] <niemeyer> rogpeppe: Ok, just want to make sure I'm not reviewing something you don't want me to
[14:09] <rogpeppe> niemeyer: yes, i'd love a review of that on if poss.
[14:10] <niemeyer> rogpeppe: Sounds good, starting right away
[14:10] <rogpeppe> niemeyer: if i was able, i'd rename the branch "go-environs-simplify-provider-interface"
[14:10] <niemeyer> rogpeppe: Cool, no worries
[14:10] <rogpeppe> niemeyer: i think you'll like it BTW
[14:11] <niemeyer> rogpeppe: Sweet
[14:12] <niemeyer> rogpeppe: As an unrelated note that I just reminded, I pushed a goamz branch over the weekend to improve and fix s3 a bit
[14:12] <niemeyer> rogpeppe: I gave a try at using it for dreamhost's Objects service.. works!
[14:12] <rogpeppe> niemeyer: yeah, i'm intending to look at it. sorry about the breakage BTW!
[14:12] <niemeyer> rogpeppe: I mean, with the branch..
[14:12] <niemeyer> rogpeppe: No worries.. I think we all just have to be more diligent at running tests pre-submit
[14:13] <rogpeppe> niemeyer: maybe lbox submit's auto-merge functionality is really unnecessary, 'cos you should merge and test before submitting anyway
[14:15] <niemeyer> rogpeppe: Turns out it's quite boring to do that by hand all the time
[14:15] <rogpeppe> niemeyer: yeah, i guess.
[14:16] <niemeyer> rogpeppe: I know for sure.. been there :)
[14:16] <niemeyer> (for years!)
[14:16] <rogpeppe> niemeyer: but it certainly makes it easier to submit broken code...
[14:16] <niemeyer> rogpeppe: It makes it easier to submit any code.. broken or not
[14:16] <niemeyer> rogpeppe: Making that process more painful isn't a great way to solve the issue
[14:18] <rogpeppe> niemeyer: case: i merge, test, someone else submits a change to an API i'm using, i submit, lbox auto-merges => broken build.
[14:18] <TheMue> niemeyer: Any chance to take a look at https://codereview.appspot.com/6200044/ ?
[14:18] <rogpeppe> niemeyer: the gap between me testing and me submitting can be arbitrarily short
[14:18] <niemeyer> TheMue: There are great chances, yeah :)
[14:18] <niemeyer> TheMue: I've been reviewing the queue regularly
[14:19] <niemeyer> TheMue: So if it's in the active branches list, it will get reviewed
[14:19] <TheMue> niemeyer: Just wondered, because you already reviewed a follow-up.
[14:20] <niemeyer> rogpeppe: Sure, that's a problem.. let's fix it. We can do that without making our lives more painful.
[14:20] <TheMue> niemeyer: Right now I've finished Add…Relation() with tests as a next branch.
[14:20] <niemeyer> TheMue: Yeah, as I said, I've been reviewing regularly
[14:20] <niemeyer> TheMue: Every day
[14:20] <rogpeppe> niemeyer: is there a way to fix it without getting lbox to run the tests itself?
[14:20] <niemeyer> TheMue: I've also been ordering reviews by branch size
[14:20] <niemeyer> TheMue: If you want faster turn arounds, smaller branches will win
[14:21] <TheMue> niemeyer: OK
[14:21] <rogpeppe> i was thinking that branch size should be judged by bzr diff | grep '^>' | wc -l
[14:21] <niemeyer> rogpeppe: Branch sizes is ordered by diff size
[14:21] <rogpeppe> otherwise we get penalised for many small changes, and also for deleting code
[14:21] <niemeyer> rogpeppe: https://code.launchpad.net/juju/+activereviews shows the number of lines
[14:23] <niemeyer> rogpeppe: Eventually we can have that.. we'll have to write logic that checks out branches, analyzes them, and builds a list in our preferred fashion
[14:23] <niemeyer> rogpeppe: Meanwhile, Launchpad has that nice column :-)
[14:56] <niemeyer> rogpeppe: Very nice indeed
[14:56] <rogpeppe> niemeyer: cool, thanks
[14:56] <niemeyer> rogpeppe: Some trivial suggestions only
[14:56] <rogpeppe> niemeyer: am just currently doing the awkward merge between that branch and the one submitted on friday
[14:58] <niemeyer> TheMue: Ah, I've already reviewed most of that branch on Friday, btw
[14:58] <rogpeppe> niemeyer: i'm a bit surprised that goyaml conventions for naming are different from json and xml
[14:58] <niemeyer> TheMue: I've purposefully not submitted the review because I wanted to look through it again after the weekend
[14:59] <niemeyer> TheMue: You've (silently?) refactored significantly the way Python stored information about the endpoints, and I want to see that again with a fresh mind today
[14:59] <rogpeppe> niemeyer: that case changing stuff was deliberately removed from them to make the mapping clearer, i think.
[14:59] <rogpeppe> niemeyer: i'll remove the tags anyway though
[14:59] <TheMue> niemeyer: Yes, that's a result of the discussion between William and me during UDS.
[15:00] <niemeyer> TheMue: Ok, this is a major change, though
[15:00] <niemeyer> TheMue: It shouldn't be submitted silently, without even a note in the description
[15:01] <niemeyer> TheMue: I'm still thinking through it. At this point just saying I'd appreciate a note next time.
[15:01] <TheMue> niemeyer: OK, will handle it more carefully next time.
[15:01] <niemeyer> TheMue: Thanks
[15:01] <niemeyer> rogpeppe: xml had stuff that was a *lot* more magical
[15:02] <niemeyer> rogpeppe: json too, IIRC
[15:02] <rogpeppe> niemeyer: still, i do like the "no magic at all" approach
[15:02] <rogpeppe> niemeyer: it makes the code more transparent.
[15:02] <rogpeppe> IMHO
[15:02] <niemeyer> rogpeppe: There's no magic in goyaml.. it's the lowercased name.
[15:02] <niemeyer> rogpeppe: If it doesn't match, it doesn't
[15:02] <rogpeppe> niemeyer: does that mean you can't marshal to an Uppercased name ?
[15:03] <niemeyer> rogpeppe: That no
[15:03] <niemeyer> rogpeppe: Erm
[15:03] <niemeyer> rogpeppe: No
[15:03] <rogpeppe> niemeyer: so it applies in one direction but not the other?
[15:03] <niemeyer> rogpeppe: If you want that, you need to use a tag
[15:04] <niemeyer> rogpeppe: It makes sense (to me, anyway) because most yaml is lowercase
[15:04] <rogpeppe> niemeyer: i'll remove the tags, but let me lodge an objection for the future. it's nice if marshalling packages are consistent like this.
[15:04] <niemeyer> rogpeppe: Same thing with mgo
[15:04] <niemeyer> rogpeppe: MongoDB is massively lowercase
[15:04] <niemeyer> rogpeppe: So goyaml and bson are consistent ;)
[15:04] <rogpeppe> niemeyer: i think having a non-bijective transformation is asking for trouble
[15:05] <niemeyer> rogpeppe: Not sure about what you mean. I've just said it's bijective.
[15:05] <niemeyer> rogpeppe: The marshaling name is the lowercased field name.
[15:06] <rogpeppe> niemeyer: ah. so i *can't* marshal to an upper-cased name?
[15:06] <niemeyer> rogpeppe: You have to use a tag name.
[15:06] <niemeyer> Erm.. s/name//
[15:06] <rogpeppe> niemeyer: i see.
[15:06] <rogpeppe> niemeyer: sorry, i misunderstood
[15:06] <rogpeppe> niemeyer: that's not too bad, i guess.
[15:07] <niemeyer> rogpeppe: Yeah, that's how I feel too.
[15:07] <niemeyer> Anyway, lunch time
[15:07] <niemeyer> Back in a bit
[15:07] <niemeyer> TheMue: Will cover your branch first thing in the afternoon
[15:08] <TheMue> niemeyer: Thx a lot
[15:16] <rogpeppe> niemeyer: not sure about "LoadConfig" as a name. how about NewConfig ?
[15:29] <niemeyer> rogpeppe: +1
[15:29] <rogpeppe> niemeyer: cool, done already :-)
[15:47] <rogpeppe> niemeyer: you might want to have a brief once-over of environs/interface.go before i submit, as i didn't quite use the comment text you suggested.
[15:55] <rogpeppe> lunch
[16:09] <niemeyer> rogpeppe: Looking again.
[16:14] <niemeyer> rogpeppe: Replied
[16:18] <rogpeppe> niemeyer: thanks. actually i think it can be simpler still: // Every provider must accept the "name" and "type" attributes, the environment name and provider type.
[16:19] <niemeyer> rogpeppe: That's misleading. It's not A and B, C and D.
[16:19] <niemeyer> rogpeppe: If you're happy with the suggestion, can we please go with it?
[16:20] <rogpeppe> niemeyer: i'm not keen on the "with" in your suggestion. am trying to think of a better phrasing.
[16:20] <niemeyer> rogpeppe: Alright, please use whatever you fancy then
[16:20] <niemeyer> rogpeppe: If "with" is unacceptable I can't really improve on it
[16:21] <rogpeppe> niemeyer: it reads oddly, sorry, i can't quite say why.
[16:21] <rogpeppe> niemeyer: how about "Every provider must accept the name of the environment ("name") and the environment type ("type")."
[16:21] <niemeyer> rogpeppe: Sucks
[16:22] <rogpeppe> hrm
[16:22] <rogpeppe> niemeyer: what about s/with/holding/
[16:22] <rogpeppe> ?
[16:22] <niemeyer> rogpeppe: "provide the foo argument with the key" is extremely usual
[16:23] <niemeyer> rogpeppe: holding is equally usual
[16:23] <niemeyer> rogpeppe: (which means, I'm fine with it too)
[16:24] <rogpeppe> niemeyer: cool, i'll go with that, and ponder why my "awkward-english" alarm went off for "with" :-)
[16:24] <niemeyer> rogpeppe: Please let me know if you find out
[16:24] <niemeyer> rogpeppe: and thanks
[16:24] <TheMue> So, off for the moment. Next branch is in.
[16:25] <rogpeppe> niemeyer: something to do with the fact there are two keys, i think.
[16:25] <rogpeppe> niemeyer: but can't pin it down more than that...
[16:26] <niemeyer> rogpeppe: Doesn't parse as related in my head
[16:26] <niemeyer> or, as Kevin would say, in my "heeeed"
[16:26] <rogpeppe> :-)
[16:29] <rogpeppe> niemeyer: in the end, i'm not really sure how "holding" is better than "giving", but i'm going with it anyway.
[16:29] <niemeyer> rogpeppe: It doesn't *give* anything to anyone.. it contains, and is.
[16:31] <rogpeppe> niemeyer: one use of the word "give" is "to impart or communicate"
[16:32] <rogpeppe> niemeyer: which is how i was using it.
[16:32] <niemeyer> rogpeppe: Try to put "communicates" or "imparts" there..
[16:32] <niemeyer> rogpeppe: It's bad too.
[16:32] <rogpeppe> / Every provider must accept the "name" and "type" attributes, communicating the environment name and provider type respectively.
[16:33] <rogpeppe> seems to work ok to me.
[16:33] <rogpeppe> apart from the length of "communicate" :-)
[16:33] <niemeyer> rogpeppe: Still sounds bad to me. But we don't have to agree on that.
[16:33] <rogpeppe> niemeyer: it's fine. i'll try to avoid it in the future...
[16:34] <niemeyer> rogpeppe: Thakns
[16:40] <rogpeppe> niemeyer: submitted. thanks a lot for the review.
[16:44] <niemeyer> rogpeppe: np
[16:53] <niemeyer> robbiew: Do you know if we'll have that meeting in 7 mins?
[16:53] <robbiew> no clue...I can't make it due to a conflict though
[16:53] <robbiew> niemeyer: it looks like a lot of folks declined, so perhaps not
[16:54] <niemeyer> robbiew: There are 20 people in that call.. it seems likely that lots of folks will decline :)
[16:54] <robbiew> lol
[16:54] <robbiew> good point
[16:56] <rogpeppe> niemeyer: micro branch for review: https://codereview.appspot.com/6219054
[16:56] <niemeyer> rogpeppe: Neat, LGTM
[16:56] <rogpeppe> niemeyer: thanks
[16:57] <rogpeppe> niemeyer: yay, fastest turnaround ever!
[16:57] <niemeyer> rogpeppe: Small branches FTW! :-)
[17:40] <rogpeppe> niemeyer: a larger branch for review: https://codereview.appspot.com/6198064
[17:40] <niemeyer> rogpeppe: Cheers
[17:40] <rogpeppe> niemeyer: though it's not nearly as large as it appears.
[17:41] <rogpeppe> niemeyer: i'm off for the day. see you tomorrow!
[17:41] <niemeyer> rogpeppe: Have a good one
[22:04] <niemeyer> Stepping out for a while
[23:06] <andrewsmedina> gt