/srv/irclogs.ubuntu.com/2016/10/05/#juju-dev.txt

natefinchaxw: the bug about cookies not getting deleted is what I'm working on :)00:31
alexisb menn0, axw, wallyworld, katco just sent a prosed tech board agenda item00:50
alexisb please let me know if you have questoins/concern about my request00:50
wallyworldok00:50
natefinchaxw: https://cdn.meme.am/instances/500x/72177725.jpg01:00
menn0alexisb: ok01:13
menn0axw: ping01:29
axwmenn0: pong01:33
menn0axw: regarding https://github.com/juju/juju/blob/master/api/apiclient.go#L57501:34
menn0axw: it looks like when the conn is closed another Ping call is attempted before the heartbeatmonitor can finish01:34
menn0axw: should there be a short circuit in the <-s.closed case so it just does close(s.broken); return?01:35
menn0axw: this isn't causing a specific issue, i'm just poking around in the area01:35
* axw looks01:36
axwmenn0: yeah, I think so01:36
menn0axw: ok cool.01:37
menn0axw: i'm also going to try out adding handling for the websocket conn's Dead channel01:37
alexisbmenn0, axw, wallyworld any questions before I log off>01:37
alexisb?01:37
axwalexisb: sorry just got back, looking now01:38
wallyworldalexisb: why are you guys voting for trump?01:38
axwmenn0: SGTM01:38
menn0alexisb: I think your tech board item is clear enough01:38
alexisbto amuse you wallyworld01:38
wallyworldlol01:38
menn0although it'll blow out the meeting beyond an hour :)01:38
alexisband because I cannot eat a turd sandwich01:38
alexisbmenn0, yes do the best you can01:39
alexisbif we can get the start of a list I can work with folks individually on details01:40
menn0axw: i'm seeing cases in my HA testing where the api-caller takes quite a while to notice that the apiserver has stopped because the conn is only tried every ping timeout and I guess the ping attempt takes a while to time out too01:40
axwalexisb: sounds good. I don't think we'll get it all done in one meeting of course, but we can make a start01:40
menn0axw: checking the underlying websocket Dead might speed things up01:40
alexisbaxw, understood and thank you01:40
alexisbalrighty all I am off for the night chat with you tomorrow01:40
menn0alexisb: good night01:40
axwgood night01:40
axwmenn0: hrm, what channel are you talking about?01:41
* menn0 finds01:42
menn0axw: sorry I said the websocket conn01:42
menn0axw: I meant rpc.Conn - it has a Dead() method01:43
axwmenn0: ah right01:43
axwwallyworld: is it https://github.com/juju/juju/pull/6373 that I'm reviewing?01:47
* axw was half asleep in standup01:47
wallyworldaxw: yeah, ta01:47
natefinchaxw, wallyworld:  any thoughts on this? https://github.com/juju/persistent-cookiejar/pull/16#pullrequestreview-281336301:55
wallyworldnatefinch: i'm not too sure; i don't know a lot about cookies offhand01:59
menn0thumper, wallyworld or axw: https://github.com/juju/juju/pull/637901:59
wallyworldmenn0: i'll swap https://github.com/juju/names/pull/7601:59
natefinchwallyworld: np01:59
axwnatefinch: sorry, likewise. I think you're going to have to interrogate rogpeppe101:59
natefinchaxw: kk02:00
menn0wallyworld: fair enough02:00
wallyworldmenn0: that one is a pre-req for a much bigger juju core change to remove @local02:00
wallyworldwhich i've done but need to write upgrade steps, yay02:01
menn0wallyworld: understood02:01
menn0wallyworld: sorry, I just remembered I need QA steps on that02:02
* menn0 adds02:02
wallyworldmenn0: that's one think i dislike about gh reviews, no qa steps section. plus all the other disadvantages. when are we going to go back to something better like reviewboard?02:02
menn0wallyworld: we're still in our 2 week trial. after that we get everyone's opinions/votes and see where we land.02:03
babbageclunkmenn0: Oops couldn't sleep02:03
wallyworldmenn0: i've been away for 2 weeks, i was hoping it would be done and dusted :-)02:04
menn0wallyworld: maybe the trial's over then? We'll have to check the date when we started.02:05
menn0babbageclunk: haha :)02:05
menn0babbageclunk: just b/c you can't sleep doesn't mean you have to work :)02:06
menn0wallyworld: QA steps added02:08
wallyworldta02:08
wallyworldthat's anothe thing - now we are foced to pollute commit messages with QA steps02:09
wallyworldsince there's no separate section02:09
wallyworldmenn0: lgtm. i like simple fixes like that02:16
menn0wallyworld: thanks - figuring out what was going on was anything but simple but the fix was straight forward02:16
wallyworldmenn0: it reminds me of that joke about the car mechanic02:17
menn0wallyworld: and some of the other changes I'd like to do around this are a lot less simpler :)_02:17
menn0wallyworld: your change LGTM. I had actually reviewed it a while ago but forgot to end the review.02:22
wallyworldmenn0: ta. am still writing the upgrade steps anyway02:22
babbageclunkmenn0: It doesn't look like the pool gets hit if I try to do something with a removed model, but I think that might be because the client store knows the model's gone away.02:24
babbageclunkmenn0: Or rather, it's because it tries to find the model by name first from the controller.02:27
babbageclunkmenn0: Is there a way to destroy the model from a different client so that the modeluuid is still in the client store?02:27
babbageclunkmenn0: I'm beginning to think I should do the refcounting anyway - relying on implementation details of the api server to ensure that the state isn't in use when we try to close it seems fragile.02:31
babbageclunkmenn0: And even if it does today there's no guarantee it will in the future.02:32
babbageclunkmenn0: Oops, out of battery - send me an email if you have strong feelings about the above?02:44
menn0babbageclunk: that all sounds good to me02:46
thumpermenn0: do you still need a teddy bear?03:10
menn0thumper: have been looking into other things but yes03:10
menn0thumper: now?03:10
thumpersure03:11
thumperhangout?03:11
menn0thumper: 1:1?03:12
thumperthere already03:12
menn0ok03:12
wallyworldaxw: i think we can drop migrateLegacyAccounts() for accounts.yaml now right? i think it was for beta13->14?03:23
axwprobably, looking03:23
wallyworldi be doing an implementation to migrate the @local stuff03:24
axwwallyworld: yep, please drop what's there03:24
wallyworldwill do ta03:24
axwwallyworld: it would be nice if we had some general client-side upgrade steps. maybe in some distant future03:25
wallyworldyeah03:25
veebersmenn0: would you happen to know where I might be able to file a bug against mongostat that I got from http://repo.mongodb.org? The most recent changes output a little bit (unexpected)04:59
axwwallyworld: gotta go pick up my car, will bbs05:54
wallyworldok05:54
wallyworldthe new one?05:54
axwwallyworld: yeah just had to take it for its first service05:54
wallyworldok05:55
=== frankban|afk is now known as frankban
menn0jam: tech board?08:04
jammenn0: yep, just got 2fa'd, brt08:04
macgreagoirrogpeppe1: This is to fix one you mentioned to me last week, in case you'd like to look ;-) https://github.com/juju/juju/pull/638108:38
=== rogpeppe1 is now known as rogpeppe
rogpeppemacgreagoir: looking08:45
macgreagoirCheers08:46
rogpeppemacgreagoir: LGTM - that was a hard one :)08:46
macgreagoir:-D08:47
macgreagoirIf it were OpenStack, I'd get to ODS for free!08:47
babbageclunkvoidspace: ping?10:04
voidspacebabbageclunk: pong10:24
babbageclunkvoidspace: hey, do you know about the AllModelWatcher?10:25
voidspacebabbageclunk: not really, sorry10:25
voidspacebabbageclunk: don't think I've ever looked at it10:25
babbageclunkHmm.10:26
voidspacebabbageclunk: what's up with it, what do you need to know?10:28
babbageclunkvoidspace: Trying to change the StatePool so it closes the State objects it holds when the corresponding model goes away.10:29
voidspacebabbageclunk: ah :-)10:29
voidspacebabbageclunk: sounds like fun10:29
babbageclunkvoidspace: It's the source of a memory leak when someone does lots of add/destroy models.10:29
voidspaceright10:31
babbageclunkvoidspace: worryingly, I can see that the AllModelWatcher contains a StatePool, so adding an AllModelWatcher to the StatePool seems like a bad idea.10:31
voidspacebabbageclunk: so important for OIL but not for anyone in real life10:31
voidspacehah, yes10:31
voidspacebabbageclunk: so maybe make the change in the AllModelWatcher calling back into the StatePool10:32
voidspacebabbageclunk: or can you have multiple state pools, not all associated with an AllModelWatcher10:32
babbageclunkvoidspace: yes that10:32
babbageclunkvoidspace: there's also one inside the API server.10:32
voidspacebabbageclunk: gah, you either need a registry or you need a new watcher10:33
babbageclunkvoidspace: Probably a new watcher - it looks like the AllModelWatcher hoovers up way more than this one would care about.10:33
voidspacebabbageclunk: a new watcher is more ju-thonic10:33
babbageclunkvoidspace: I only want to be notified when a model is removed.10:34
babbageclunkjujuic?10:34
voidspaceheh10:34
voidspaceModelRemovalWatcher10:34
babbageclunkyeah, I guess.10:35
babbageclunkvoidspace: Hah, I guess that's State.WatchModels then10:36
voidspacecool10:36
babbageclunkvoidspace: Thanks!10:36
babbageclunkwallyworld: ping?11:05
wallyworldhey11:06
babbageclunkwallyworld: I'm trying to work out how to add a model watcher to the StatePool.11:06
wallyworldi've not done anything with the state pool per se. i've done watchers, but on mgo collections11:07
voidspacemgz: ping11:08
wallyworldi can take a look at the code11:08
babbageclunkwallyworld: Does that mean I need to make StatePool into a worker?11:08
babbageclunkwallyworld: Thanks - with Will gone and Dimiter out I'm not sure who to bug about this stuff over here.11:09
wallyworldbabbageclunk: so the state pool manages a collections of states i assume. but that's not a db/mgo construct is it?11:10
babbageclunkwallyworld: no, I don't think so (not sure what you mean though)11:11
wallyworldbabbageclunk: so normally our watchers are constructs that notify when something in the db changes11:12
wallyworldeg adding to a collection11:12
babbageclunkwallyworld: At the moment it's a cache of States, but there's no way to have the States get closed when the model is removed, so there's a leak.11:12
babbageclunkwallyworld: Yeah, I *think* State.WatchModels will give me the signals I want.11:13
wallyworldbabbageclunk: dumb question not having seen the code - why can't we close state objects when they are removed from the cache?11:13
babbageclunkwallyworld: At the moment nothing removes them. (Except when the pool itself is closed, at api server shutdown time.)11:13
wallyworldoh, i see, a cache that is not managed correctly11:14
wallyworldand you want to know when a model object is removed from state11:14
babbageclunkonly two hard problems in computering.11:14
babbageclunkyup11:14
wallyworlddo we should have a model watcher on state11:15
wallyworldbut could we do something in the undertaker?11:15
wallyworlddo we have an existing process than deals with dying models?11:15
wallyworldthat we can hook in to?11:15
babbageclunkwallyworld: hang on, looking at what the undertaker listens to.11:16
wallyworldmay be prudent just to do something as part of the undertaker workflow; but not sure without looking through the code to see the dying model workflow11:16
wallyworldbbiab, got to go get kid from band practice11:16
perrito666k, need to step out for the next ~4 hs, ill be available on mail11:47
mgzvoidspace: hey, can I help?12:22
voidspacemgz: still struggling to connect to company VPN12:33
voidspacemgz: Spads has been helping me in #is - I'm about to try US gateway12:33
voidspacemgz: I get "Could not find source connection" in /var/log/syslog for UK gateway12:34
mgzvoidspace: gotcha12:34
mgzif you don't get anywhere with the vpn, come back and poke me again12:34
voidspacemgz: so thanks, I'll weep loudly and gnash my teeth if it doesn't work12:35
voidspaceheh, thanks12:35
mgzbecause we have a machine in canonistack we use to let our ci setup jump through12:35
mgzthat is an alternative to getting vpn working12:35
natefinchrogpeppe: can we talk cookies?13:03
rick_h_mhilton: ^ have a sec for natefinch ?13:26
urulamanatefinch, rick_h_: rogpeppe is afk for lunch. he'll be back in 20min or so13:28
voidspacerick_h_: grabbing coffee, with you in 513:29
rick_h_voidspace: stuck in another call, will be a bit late13:29
voidspacerick_h_: cool13:29
voidspacemgz: I get the same error with the US VPN gateway13:50
voidspacemgz: "Could not find source connection"13:50
voidspacemgz: and even though "us-mfoord VPN" is on in network manager it remains "Not connected"13:51
voidspacemgz: can you help me diagnose?13:51
rogpeppenatefinch: sure13:52
natefinchrogpeppe: I know you said that the cookies don't need to round trip... except that they do with RemoveCookie13:52
natefinchrogpeppe: thus - https://github.com/juju/persistent-cookiejar/pull/1613:53
rogpeppenatefinch: hmm, i'd forgotten that RemoveCookie existed. let me have a look.13:54
mgzvoidspace: what's the final ip you're trying to get to?13:54
mgzwe may as well try the low-fi method13:54
voidspacemgz: I'm trying to get access to vsphere13:54
voidspacemgz: so 10.245.0.131 I think13:54
rogpeppenatefinch: how are you intending to use it?13:55
mgzvoidspace: okay, this works for me13:56
mgz(well, I get prompted for a password, but I presume you can get by that)13:56
voidspacemgz: I have the vsphere creds from cloud-city13:56
natefinchrogpeppe: when we log out of a controller, we need to remove the cookie we saved for the controller, to force the user to re-enter their password13:57
rogpeppenatefinch: how are you planning on getting that cookie?13:57
rogpeppenatefinch: scratch that, it's obvious :)13:57
natefinchrogpeppe: I hope your obvious solution is the same as mine13:58
rogpeppenatefinch: i think you'll need to use AllCookies13:58
rogpeppenatefinch: and search through for any cookies with a matching host13:59
natefinchrogpeppe: isn't that what Cookies(net.URL) is for?13:59
rogpeppenatefinch: not really13:59
rogpeppenatefinch: that method is for getting cookies to send as part of a web request14:00
rogpeppenatefinch: i think it's best to keep to the standard implementation for that14:00
natefinchrogpeppe: right, which is what we'd send up as authentication, which means those are the ones that we want to remove14:00
rogpeppenatefinch: it might be nice to have a RemoveAll(url) method14:01
rogpeppenatefinch: which would remove all cookies that would be sent to the given URL14:01
natefinchhow is that not this?14:01
natefinchhopefully they'll recognize that yoyu14:01
natefinchoops, wrong paste14:01
natefinchfor _, c := range jar.Cookies(st.cookieURL) {14:01
natefinchj.RemoveCookie(c)14:01
natefinch}14:01
katconatefinch: standup time14:02
rogpeppenatefinch: because the Cookies method doesn't fill in the domain name14:02
natefinchthat's the BUG14:02
rogpeppenatefinch: and that seems to be deliberate14:02
rogpeppenatefinch: then raise it in golang.org/issue14:02
katcovoidspace: standup time14:02
voidspacekatco: omw14:03
natefinchrogpeppe: it did seem deliberate, which is why I posted on golang-nuts about it, but no one has responded yet. I could go directly to filing an issue, might get a better response14:04
rogpeppenatefinch: i think the answer is probably the answer i gave you - you don't need to encode the domain name when sending a cookie14:05
natefinchrogpeppe: but it also prevents you from updating a cookie.  Being able to round trip is usually good practice, to prevent surprising behavior14:06
rogpeppenatefinch: this document is relevant: String returns the serialization of the cookie for use in a Cookie header (if only Name and Value are set) or a Set-Cookie response header (if other fields are set). If c is nil or c.Name is invalid, the empty string is returned.14:08
rogpeppes/document/comment/14:08
rogpeppenatefinch: so if we change the implementation of Cookies, we'll be breaking that14:08
mhiltonnatefinch, rogpeppe: you seem to be having the discussion I was about to start. I'm on the side of the Cookies function should only fill in the values that get sent in an HTTP request. If you want different functionality then I think you want a different function.14:09
rogpeppemhilton: yup14:09
rogpeppenatefinch: that's the doc comment on Cookie.String BTW14:09
natefinchmhilton. rogpeppe: well, then RemoveCookie is useless, and we should remove it14:10
natefinchor... nearly useless I guess14:10
rogpeppenatefinch: it's not useless14:10
rogpeppenatefinch: you can use it with AllCookies14:10
natefinchwell then allcookies is doing the wrong thing according to what you said above14:11
rogpeppenatefinch: AllCookies isn't designed for sending web requests14:11
rogpeppenatefinch: it's not part of the CookieJar interface14:11
natefinchrogpeppe: it's a function called AllCookies on a thing that implements CookieJar14:11
rogpeppenatefinch: yes14:11
rogpeppenatefinch: and?14:11
natefinchrogpeppe: if you think no one is ever going to use cookies from that list to send in a web request, you're more optimistic than most devs I've met14:12
rogpeppenatefinch: FWIW i think both AllCookies and RemoveCookie could be better documented14:12
rogpeppenatefinch: i'm optimistic. why would you do that? net/http uses the CookieJar implementation directly - there's no need to add cookies yourself.14:13
natefinchI don't think GetCookies(u) | RemoveCookie(c) is an unreasonable thing to think will work.  The fact that it doesn't cost me a few hours of confusion.14:13
natefinchthe old adage is to make it hard/impossible to do the wrong thing, and we're making it really easy to do the wrong thing.14:14
rogpeppenatefinch: i think we've pointed out the reason why you can't have that14:14
rogpeppenatefinch: i think the best answer is to improve the docs14:17
natefinchrogpeppe: That's fine... but then RemoveCookie shouldn't be there.  It's misleading.  I think it would be better to remove RemoveCookie and AllCookies, and instead have RemoveAll(url) and RemoveAll(func(c cookie)) or something.14:17
rogpeppenatefinch: AllCookies is useful for other reasons too14:17
natefincher func(cookie) bool14:17
rogpeppenatefinch: and if you can see a cookie, it's useful to be able to remove it.14:18
natefinchrogpeppe: the fact that it returns cookies in a different format than Cookies(url) is *going* to cause confusion and bugs.  It already has.14:18
rogpeppenatefinch: well, it returns the same format that's used for SetCookies14:18
rogpeppenatefinch: and for a Set-Cookie response header14:19
rogpeppenatefinch: it should definitely be documented better, and I think we could easily have a RemoveAll(url) method14:20
rogpeppenatefinch: i'm sorry you've had issues with it14:20
rogpeppenatefinch: but i don't think the current semantics need to be changed14:21
natefinchrogpeppe: it sounds like it's really just a problem with the design of http.Cookie and the CookieJar... Having String() return significantly different things based on what values are set seems like a bad design... which then makes GetCookies(u) have to work weirdly, and the whole thing cascdes.14:22
rogpeppenatefinch: maybe, but that's ancient history and we can't change it now.14:23
natefinchrogpeppe: the best idea for now, seems to be to making a RemoveCookies(url) seems like a good compromise14:24
rogpeppenatefinch: yeah, I'd accept a PR to that effect14:25
rogpeppenatefinch: for the time being you could just iterate through AllCookies as I suggested14:26
rogpeppenatefinch: it's not like there's a performance issue with doing that.14:26
natefinchrogpeppe: that's true.  Just seems to encode too much knowledge into the caller.14:27
rogpeppenatefinch: we're not going to break it. relax :)14:28
natefinchrogpeppe: it's not that I'm afraid we'll break it, it's just ugly... and if I have to write that code somewhere, I'd rather write it in the place that deals with cookies, especially since we may need to do the same thing somewhere else.14:29
rogpeppenatefinch: i'd put it in logout.go14:30
rogpeppenatefinch: i think it's reasonable that that code knows where the various auth information is stored14:31
natefinchrogpeppe: we don't currently have an easy way to get the current controller url or the current cookie file... I had planned on putting Logout() on api.Connection, since it has the Login function, and it already has the cookie jar and the url.14:32
rogpeppenatefinch: you can trivially get the current controller URL by calling store.ControllerByName14:34
rogpeppeapi.Connection doesn't have enough information to be able to log out14:35
natefinchrogpeppe: it has the persistent cookie jar and the url we're using to log in.... does it need more than that?14:37
rogpeppenatefinch: it doesn't necessarily have a persistent cookie jar14:37
natefinchrogpeppe: when would it not?14:37
rogpeppenatefinch: when someone makes a connection that's not using a persistent cookie jar. That's set up at a higher level, and api.Connection should not assume that it has one.14:38
rogpeppenatefinch: sorry, my connection just dropped for some reason14:39
rogpeppenatefinch: i think it's better that the code that's responsible for setting up the persistent cookiejar should be responsible for cleaning it up14:39
rogpeppenatefinch: BTW you can trivially get the persistent cookie jar with logoutCommand.APIContext() in the Jar field14:40
rogpeppenatefinch: FWIW persistent-cookiejar is a bit of a hack. it would be nice to replace it some time, and ISTM that introducing a dependency on it inside the API client code is not a good way to make that easier.14:42
rogpeppenatefinch: in general, anything that needs a dynamic type coercion should be viewed with suspicion.14:43
natefinchrogpeppe: that's fine.  I figured the parity with login would be good, but it's fine not to14:43
natefinchrogpeppe: Oh yeah, absolutely.  I hate to do it14:43
redirmorning juju-dev15:10
babbageclunkredir: morning!15:11
babbageclunkredir: Hey, what happened with WaitAdvance?15:11
redirbabbageclunk: it landed on friday IIRC15:12
babbageclunkredir: but no pushback or argybargy?15:21
redirbabbageclunk: not yet15:22
redirbabbageclunk: I'm just back from swapdays today15:22
babbageclunkredir: oh right15:22
babbageclunkredir: cool15:22
redirbabbageclunk: how's move preparations going?15:26
babbageclunkredir: scary!15:27
redirbabbageclunk: I bet. That is a long move15:27
babbageclunkredir: and getting really close! Lots of things to cancel and organise.15:27
redirbabbageclunk: we made a transcontinental move last year this time. I am so glad it went smoothly and we're done with it.15:29
redirhope yours is as painless as can be15:29
babbageclunkredir: yeah, I'm really looking forward to it being done. Thanks"15:29
babbageclunk!15:29
redirkettle is whistling. bbiam15:30
alexisbmorning redir15:40
alexisbredir, we should connect when you have a moment15:41
rediralexisb: OK, going through email15:41
redirI'll ping you when done?15:41
alexisbredir, sure and I have a few meetings this morning as well15:43
rediralexisb: I'll look for a slot15:43
rediralexisb: wanna ping me after 10?15:55
alexisbsure15:56
alexisbredir,15:56
rogpeppei've just proposed some changes to the juju register command to allow registration of controller with officially signed certs. reviews appreciated. https://github.com/juju/juju/pull/638216:01
=== frankban is now known as frankban|afk
=== rogpeppe is now known as rogpeppe1
=== rogpeppe1 is now known as rogpeppe
=== rogpeppe is now known as rogpeppe1
=== rogpeppe1 is now known as rogpeppe
babbageclunkkatco: ping?16:51
katcobabbageclunk: pong16:52
babbageclunkkatco: hey, I've been making some changes to StatePool to do refcounting.16:52
katcobabbageclunk: lucky you ;p how's it going?16:52
babbageclunkkatco: Would you mind taking a look at the current state of it?16:53
katcobabbageclunk: sure16:53
babbageclunkkatco: ok I think, although I've backed off from trying to make the StatePool watch models and remove items from itself.16:54
katcobabbageclunk: yeah i don't think the statepool would be responsible for that as it's just a cache. if we went that route it would be a separate watcher16:55
babbageclunkkatco: it's used in the API server and in WatchAllModels, and they use different types for life management.16:55
babbageclunkkatco: menn0 had suggested I do that, but I think I'd need to convert the API server to use a catacomb first, maybe?16:56
babbageclunkkatco: not really sure about that16:56
redirrogpeppe: looking16:56
rogpepperedir: thanks!16:57
rogpepperedir: there's some fun stuff in there :)16:57
babbageclunkkatco: Ok, pushed - https://github.com/juju/juju/compare/master...babbageclunk:pool-memleak?expand=116:57
katcobabbageclunk: tal. not sure about the catacomb question either. i think i need more context/concrete code to ponder over16:57
babbageclunkkatco: thanks! Sorry, I have to rush home now so can't chat about it, but I'll check comments/email about it and be back online later.16:59
voidspacerick_h_: ok :-)17:01
voidspacerick_h_: was just writing you an email... but you've answered it17:01
rick_h_voidspace: :)17:01
alexisbredir, ping17:04
rediralexisb: po17:06
redirng even17:06
alexisb:)17:06
redircan't tab complete pong in weechat yet.17:06
redirlocation alexisb ?17:07
alexisb1x1 HO17:07
alexisbbrt17:07
alexisbhttps://hangouts.google.com/hangouts/_/canonical.com/alexis-bruemmer17:09
alexisbredir, ^^17:09
rogpepperedir: get anywhere with that review? :)17:22
redirrogpeppe: on hold in meeting bbiab17:22
rogpepperedir: np17:22
rogpepperedir: i'm about to stop for the day, but look forward to your comments in the morning.17:23
cmarswhich collection has an application's config?17:33
redirrogpeppe: cool17:43
rediri mean: ack17:43
cmarsah, it's `settings`17:49
* alexisb changes locations, back online in a few minutes17:52
rick_h_voidspace: dooferlad ping, question in an irc channel about forcing juju traffic onto a specific address/interface.17:52
rick_h_voidspace: dooferlad is there some method of forcing that?17:52
perrito666I have put up a PR that mostly has tests https://github.com/juju/juju/pull/638417:59
alexisbperrito666, would this bug (https://bugs.launchpad.net/juju/+bug/1605714) potentially be fixed with this PR: https://github.com/juju/juju/pull/632118:39
mupBug #1605714: juju2 beta11: LXD containers always pending on ppc64el systems <oil> <oil-2.0> <juju:Triaged by rharding> <https://launchpad.net/bugs/1605714>18:39
perrito666alexisb: mm, I dont know if fixed, the containers might be in broken instead of fixed18:41
perrito666of pending18:41
perrito666but I am not sure what is causing it18:41
alexisbok18:41
mupBug #1630728 opened: user add/remove borked <juju-core:New> <https://launchpad.net/bugs/1630728>19:34
mupBug #1630737 opened: juju should use internal vpc network address space when connected to vpc  via vpn <juju-core:Incomplete> <https://launchpad.net/bugs/1630737>19:34
perrito666rick_h_: I am starting to think we need a juju unremove-user19:44
thumperperrito666: ew19:44
natefinchlol19:45
natefinchjuju undo19:45
rick_h_perrito666: heh, I'd think reactive maybe, but yea. that's always the way I guess19:45
perrito666thumper: well our remove user does not really remove users (that is a feature) and users want to remove and then re-add, so19:45
rick_h_perrito666: I think the thing is the why is it a normal workflow, and yea sometimes mistakes happen and users need a way out19:45
katcothumper: hey quick q19:46
katcothumper: https://github.com/juju/juju/pull/6377/19:47
katcothumper: what is our standard way of returning friendly multi-line errors to users?19:47
katcothumper: macgreagoir is creating a new error and not wrapping the old one; it seems like there should be a better way19:48
thumperotp19:49
thumperlook shortly19:49
katcothumper: no worries ta19:49
natefinchkatco: my thought was that any error from a cmd.Run method can basically be considered direct output to a user, and so we don't have to worry too much about the nitty gritty19:49
katconatefinch: what about --debug where the stack and cause would be shown?19:50
natefinchkatco: does debug do that?  I didn't realize :)  I think  Wrap does the right thing, if you want a new message but keep the same stack19:51
katconatefinch: yeah i use --debug all the time to track down the root of an error19:52
katconatefinch: i think Wrap is the right thing here, but thumper has done a lot of work around user-friendly multi-line errs, so thought i'd check in19:53
natefinchmna... I can't believe our logout tests don't actually log in first... sigh20:04
rogpeppe1redir: thanks for the review. good point about the feature tests - i always forget that some tests are far removed from the package they're testing.20:04
rogpeppe1natefinch: ha ha20:04
natefinchrogpeppe1: details, right?20:05
rogpeppe1natefinch: :)20:05
konobihowdy. I'm having a problem with 4096bit SSH keys as reported in https://bugs.launchpad.net/juju/+bug/1543283 -- The bug is marked as fixed/released, but I'm seeing the same behaviour with 2.0-rc2-elcapitan-amd6420:06
mupBug #1543283: [Joyent] 4k ssh key can not be used: "cannot create credentials: An error occurred while parsing the key: asn1: structure error: length too large" <juju:Fix Released> <https://launchpad.net/bugs/1543283>20:06
konobi(this is via juju-quickstart, btw)20:06
natefinchkonobi: does it happen if you don't use quickstart?20:07
konobinot sure, what would be a way to validate?20:10
konobi`ERROR detecting credentials for "joyent" cloud provider: credentials not found`20:11
konobialong with `ERROR there was an issue examining the environment: cannot create credentials: An error occurred while parsing the key: asn1: structure error: tags don't match (16 vs {class:0 tag:14 length:30 isCompound:true}) {optional:false explicit:false application:false defaultValue:<nil> tag:<nil> stringType:0 timeType:0 set:false omitEmpty:false} pkcs1PrivateKey @2`20:12
natefinchcould be a bug, but might also be a problem with the format of the key in the credentials.yaml file20:15
konobiwell, with joyent/triton it uses http-signatures for credentials20:16
natefinchkonobi: ahh, is the key encrypted?20:18
natefinchI betcha that's the problem20:18
konobiit is... but my ssh-agent is running just fine20:20
konobiin the meantime, unencrypting should work for now20:20
konobibut yeah, i'd generally be using high strength ECDSA20:21
natefinchI don't think juju itself supports ssh-agent.... I see some stuff about quickstart supporting it, but I'm honestly not sure how that works20:24
natefinchasking on #juju might get you better help with quickstart.  The bug you saw was for juju, not quickstart, so it's possible quickstart has the same problem we already fixed in the core of juju20:24
konobiit's the same errors as from that ticket20:30
alexisbthumper, are you actively doing anything for htis bug: https://bugs.launchpad.net/juju/+bug/162576820:32
mupBug #1625768: github.com/juju/juju/state go test timeout <ci> <intermittent-failure> <regression> <unit-tests> <juju:In Progress by thumper> <https://launchpad.net/bugs/1625768>20:32
thumperalexisb: not any more, I sped up the slowest 320:32
thumperand that made things pass under the time limit again20:32
alexisbyep20:33
alexisbI am going to move it to high and to 2.1, as CI still sees it failing but not at a critical rate20:33
thumperveebers: pign20:48
rediranyone see this error when bootstrapping aws before? http://paste.ubuntu.com/23281590/20:52
veebersthumper: pong, what's the haps? :-)20:54
thumperkatco: commented, and suggested wrap20:54
katcothumper: ta, tal20:54
thumperveebers: I have a fix (I think) for some windows and s390 test failures20:55
thumperand would like to confirm20:55
thumpercan we get access to the machines, grab my branch and run the test to see?20:55
veebersthumper: yep, we can do that.20:56
thumperveebers: this issue http://reports.vapour.ws/releases/issue/57f1cae8749a5660b085163f20:56
redirreboot brb21:06
konobihuh, seems like it chooses id_rsa in my .ssh folder over the one it's configured with =0/21:07
redirphtphtpht failed to bootstrap model: cannot start bootstrap instance: no "xenial" images in us-west-1 with arches [amd64]21:51
konobiokay... it appears that juju just doesn't want to use the keys it was told to22:06
konobi(for bootstrap that is)22:08
konobidon't suppose folks who work on the joyent cloud provider backend are around at all?22:32
katcothumper: is it OK if an error message is multi-line? should we instead print things out to stderr and return the standard formatted error?22:42
thumperkatco: I think it's fine, but I also think that it would make sense to get general agreement on approach for these types of responses, and then apply it everywhere22:43
thumperI'm in two minds22:43
thumperI can see benefits of both ways22:43
katcothumper: it's just bugging me for some reason22:43
thumperkatco: so here's an alternative approach22:44
katcothumper: i think because we throw away the original error (maybe ok) but then create a message that's unlike all other errors22:44
thumperthe common.PermissionError should take a command context22:44
thumperand write out to that22:44
thumperand then have the function return a silent error22:44
thumperso it doesn't get emitted22:44
thumperto be honest...22:45
thumperif we are wanting to have standard multiline nice emitting of errors22:45
thumperit makes sense to me for those functions to take the error and command context22:45
katcothumper: (or just an io.Writer)22:45
thumperthat way you aren't wrapping or hiding22:45
thumperagreed22:45
thumpera writer would also be fine22:45
katcothumper: i think that's what's bothering me: we're not trying to create a new error with a better message, we're really trying to print something nice out to the user22:46
thumperkatco: listen to that niggling22:46
katcothumper: and i think we're conflating the two22:46
thumperkatco: it is bothering you for a reason22:46
thumpertrust it22:46
thumperagreed22:46
thumperI'll back you on this22:46
katcothumper: as you said, maybe a function that take an io.Writer to write to and is called from the Run()s, and then do we still print the returned error? i think it would be ok?22:47
thumperI think the 'nice writer func' should write all the error info22:47
thumperand we convert the error into a silent one22:48
thumperotherwise we'll get things emitted out of order22:48
thumperwhich is why the error is being replaced with long text22:48
konobithumper: any idea if someone on IRC is familiar with the joyent stuff at all? I'm dealing with it now, but I'm also a former joyent engineer, so I'm much more familiar with how the api there works22:48
thumperso the command infrastructure will write the full text22:48
thumperkonobi: not me sorry22:48
katcothumper: ok, i can get behind that. function that writes out message to user + original error message and swallows the error?22:49
thumperno22:49
thumperit can't swallow it fully22:49
thumperotherwise the command will have rc of 022:50
katcoah just errors.Wrap(err, "") ?22:50
thumperrather than 122:50
katcoyeah22:50
thumperthere is a silent error type in cmd22:50
thumperwhich doesn't get emitted22:50
katcowe probably still need to wrap the error for the stacktrace in --debug22:50
thumperyeah22:50
thumperwrap the error with a silent one22:51
thumperso errors.Cause is a silent error22:51
thumperthat should work22:51
katcook thanks for talking through that with me, i'll leave that feedback22:51
thumperalso...22:51
thumperwe may want to have an ansiterm.Writer rather than io.Writer22:51
thumperso we could colorize22:51
thumperjust a thought22:51
* thumper thinks22:52
thumperno22:52
katcowould we ever want to colorize that?22:52
katcoyagni principle22:52
thumperwell, ERROR is shown in red22:52
thumpereverywhere else22:52
thumperbecause the cmd package logs the error22:52
thumperit starts getting a little messy22:52
katcothumper: ack22:55
=== ben_ is now known as benk01

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