[00:46] <poolie> where did the ec2 script go?
[00:47] <poolie> i'm guessing lp-dev-utils
[00:47] <wgrant> Yes, in there
[00:51]  * poolie is trying to finish https://code.launchpad.net/~mbp/launchpad/925597-dkim-from/+merge/98976
[01:02] <lifeless> have a good weekend y'all
[01:20] <StevenK> wallyworld: Can I borrow your eyes for a moment?
[01:21] <wallyworld> StevenK: sure, so long as you return them, and it depends on what you use them to look at
[01:21] <StevenK> wallyworld: http://pastebin.ubuntu.com/927290/ is one of my JS files, make lint reports "59: Expected ';' and instead saw '}'."
[01:22] <wallyworld> StevenK: you need to terminate the } with a ;
[01:22] <wallyworld> since that block is a statement and all statements need to be terminated with a ; in js
[01:22] <StevenK> Ah.
[01:23] <wallyworld> one of the reasons to prefer python :-)
[01:24] <StevenK> Oh, bah. Y.one('[name="field.information_type"]'); is only matching the first radio button with that name. :-(
[01:24] <wallyworld> do you want all of them or a specific one?
[01:24] <rick_h> StevenK: that's what .one does :)
[01:25] <StevenK> rick_h: Silence! :-P
[01:25] <rick_h> /one/all
[01:25] <wallyworld> what he said
[01:25] <StevenK> rick_h: s/one/all/   # perhaps? :-)
[01:25] <rick_h> sorry, was this in vimscript or something else :P
[01:25] <StevenK> rick_h, wallyworld: .all returns an array?
[01:25] <wallyworld> rick_h: ignore the pedant :-)
[01:25] <rick_h> hey, 'pseudocode' is legit
[01:25] <wallyworld> a NodeList
[01:26] <wallyworld> which you can call .each() on etc
[01:26] <rick_h> nodelists are nice, act like nodes
[01:26] <StevenK> Can I say .on('change', ) on it?
[01:26] <wallyworld> i'd use event delegation
[01:26] <wallyworld> instead
[01:26] <rick_h> you can say that on the nodelist, but yea, delegate ftw
[01:27] <wallyworld> attach a handler to the containing div or whatever and use a selector in the delegate() to choose what to listen to
[01:27] <rick_h> assuming they're all from a common parent node
[01:27] <wallyworld> StevenK: look at examples in shareetable.js
[01:27] <StevenK> The radio button list is coming from Zope's form handling
[01:28] <wallyworld> there should be a parent node you can use
[01:28]  * wallyworld has to run away to drop the kid at the occupational therapist. back in ~30
[01:29] <StevenK> wallyworld: It's in a table, so the parent node is ... difficult to get.
[01:29] <StevenK> Oh, wait a sec, there's a table inside another.
[01:37] <StevenK> rick_h: Hmmm, maybe I'm going about this all wrong
[01:42] <rick_h> how so?
[01:43] <StevenK> rick_h: If I put the change function on all nodes, I'm not sure how to reach in and get which radio button is selected
[01:43] <bigjools> wallyworld: fancy a liquid lunch today?
[01:43] <rick_h> so when you delegate you tell it you only care about 'input[name...]' nodes that change
[01:43] <rick_h> StevenK: and then when your callback is called, 'this' is the node that changed
[01:44] <rick_h> StevenK: http://yuilibrary.com/yui/docs/event/#delegation
[01:48] <poolie> is there an easy way to get a person by email, requiring that the email be verified?
[01:50] <rick_h> poolie: there's 'admin = getUtility(IPersonSet).getByEmail(ADMIN_EMAIL)' usage
[01:50] <wgrant> I don't think that validates.
[01:50] <rick_h> but you'll have to check the validated status of the email after you get hte person back I think
[01:51] <poolie> in my test for bug 925597 my current (not live) code is accepting mail from unverified addresses
[01:51] <_mup_> Bug #925597: From address is ignored if DKIM is supported <email> <regression> <Launchpad itself:In Progress by mbp> < https://launchpad.net/bugs/925597 >
[01:51] <poolie> which what a simple getPrincipalByLogin(addr) does
[01:51] <poolie> mm i think i should just check it
[01:51] <poolie> thanks
[01:58] <StevenK> rick_h: I'm not doing delegation yet.
[02:11] <poolie> wallyworld, could i get an incremental review on https://code.launchpad.net/~mbp/launchpad/925597-dkim-from/+merge/98976 ?
[02:16] <wallyworld> poolie: sure
[02:17] <wallyworld> bigjools: i ate on the way back from dropping lachie off at the dr :-(
[02:17] <bigjools> wallyworld: what part of liquid didn't you understand? :)
[02:18] <wallyworld> lol
[02:18] <poolie> :)
[02:18] <poolie> yay bne
[02:18] <wallyworld> bigjools:  i have to play soccer tonight but i could be persuaded to have one or two or three
[02:19] <poolie> btw i'm probably going to be up there on about the 11th of june
[02:20] <wallyworld> poolie: excellent. make sure you keep some time free to come over for dinner or something
[02:20] <bigjools> I trust we'll see you for a wee drinkie
[02:20] <poolie> :) please keep some beer for me
[02:20] <bigjools> Dan Murphy's is going to get more custom
[02:20] <wgrant> Hmmm
[02:20] <wgrant> We have a lot of old private bugs that probably shouldn't be private.
[02:24] <wallyworld> poolie: 2 comments 1. preload_dns_response. i'd prefer response_type to default to 'valid' instead of None
[02:24] <poolie> good idea
[02:25] <wallyworld> poolie: 2. i'd like to see tests for all the new code paths introduced for checking the email address
[02:25] <wallyworld> not just the 'this is not active'' case
[02:25] <poolie> oh, person with no account, etc
[02:25] <wallyworld> yeah
[02:25] <poolie> mm
[02:25] <poolie> fair point
[02:25] <wallyworld> bigjools: when you going to Dan's?
[02:26] <wallyworld> poolie: sorry to be picky on your last day
[02:26] <bigjools> when I run out of OSH
[02:26] <wallyworld> i'm surprised you have any left
[02:26] <lifeless> you Mosh ?
[02:26] <bigjools> war rationing
[02:27] <poolie> hm
[02:27] <poolie> i wonder if those can actually be hit or if i'm just over cautios
[02:27] <wallyworld> poolie: i'm not sure tbh
[02:28] <wallyworld> poolie: you could always put in asserts if we think those conditions should be impossible to hit
[02:29] <poolie> plain 'assert' or if/raise pseudo assert?
[02:29] <lifeless> if raise
[02:29] <lifeless> is what our style guide says
[02:29] <lifeless> OTOH the odds of running with -O are < 0.
[02:29] <StevenK> lifeless: What time is your flight?
[02:30] <lifeless> 1510
[02:30] <poolie> i'm guessing he's in the lounge
[02:30] <lifeless> don't ask when I started work this morning :)
[02:30] <StevenK> poolie: Given the airnz.co.nz hostname ...
[02:30] <timrc> I have a package waiting to build on staging in 59 seconds for about 4 hours
[02:31] <lifeless> are there live builders for it ?
[02:31] <poolie> can anyone tell me off hand if address.person = None or person.account = None is likely to happen?
[02:31] <wgrant> address.person = None is impossible
[02:31] <lifeless> ahh :)
[02:31] <wgrant> person.account = None is likely
[02:31] <lifeless> this is a special area of hell reserved for conflated services
[02:31] <lifeless> which we're trying to untangle
[02:32] <wgrant> timrc: staging doesn't do builds
[02:32] <lifeless> poolie: a valid person has an account
[02:32] <StevenK> No Soyuz services on staging at all, in fact.
[02:32] <lifeless> poolie: (which may not help you)
[02:32] <wgrant> StevenK: buildd-manager runs, for TTBJs
[02:32] <StevenK> wallyworld: css-selector should be what?
[02:32] <poolie> the question is should i add tests for getting mail from an address corresponding to a person with no account
[02:32] <timrc> $?@!
[02:32] <timrc> k
[02:32] <poolie> at the moment it will just basically reject it but it's not tested
[02:33] <StevenK> wallyworld: You've got span in there
[02:33] <poolie> well
[02:33] <wallyworld> StevenK: should be what you need to capture clicks from the nodes you want
[02:33] <poolie> if it's not tested, perhaps i should say the behaviour is undefined :)
[02:33] <lifeless> poolie: that will happen in real life, so I'd say yes.
[02:33] <lifeless> auntil we fix up the cruft
[02:33] <StevenK> wallyworld: Right, but I've not used them before, so how do I match the radio buttons?
[02:33] <poolie> so test for person with no account, not for an address with no person?
[02:33] <poolie> k
[02:34] <wgrant> poolie: EmailAddress.person is NOT NULL since January
[02:34] <wallyworld> StevenK: something like "input[name='field.foo']"
[02:34] <poolie> ah ok
[02:34] <wgrant> You may still see some code that assumes it can be null. I didn't catch everything.
[02:34] <poolie> the interface still says required=False
[02:34] <wgrant> Like that.
[02:34] <poolie> shall i change it in this branch?
[02:34] <wgrant> Please.
[02:34] <wgrant> There were about 10 branches in that series; there was a *lot* to change.;
[02:34] <StevenK> required=True may have some test fallout
[02:35] <poolie> or maybe separately?
[02:35] <wallyworld> StevenK: should be no need to further qualify with type=radio
[02:36] <wallyworld> poolie: i'd do it separately given the unknown test fallout
[02:36] <wallyworld> and since it's your last day and ideally we want this to land first time :-)
[02:37] <StevenK> poolie: I'm a little annoyed at this UI branch I'm working on, I'm happy to cowboy a branch that changes it and toss it at ec2
[02:37] <poolie> indeed
[02:37] <poolie> k
[02:38] <wallyworld> StevenK: let me know if you want me to look at anything with your ui stuff
[02:38] <StevenK> poolie: This is in EmailAddress ?
[02:39] <poolie> yes IEmailAddress.person (required=False)
[02:39] <poolie> in my branch
[02:39] <poolie> it may just be out of date
[02:39] <StevenK> wgrant said he missed it accidently
[02:42] <wgrant> mm
[02:42] <wgrant> I'd be realised surprised if there was test fallout
[02:42] <wgrant> But maybe
[02:47] <lifeless> well the DB requires it
[02:47] <lifeless> so the only fallout could be of the form construct; assign; flush
[02:47] <wgrant> Exactly
[02:47] <wgrant> And I doubt anything uses the interface
[02:47] <wgrant> We don't use formlib on EmailAddresses
[02:49] <wgrant> uhm
[02:49] <wgrant> r15086 is odd
[02:49] <wgrant> I think someone mistakenly commented out bouncer.start()
[02:49] <lifeless> wahuh
[02:50] <wgrant> The revision was an attempt to make the test more reliable
[02:50] <wgrant> But I think it made it always fail instead :)
[02:51]  * wgrant fixes
[02:53] <wgrant> That works a bit better
[02:56] <poolie> wallyworld, ok, i added a test for a person with no account
[02:56]  * wallyworld looks
[02:59] <StevenK> wallyworld: Ah ha, it doesn't work because Y.one('#radio-button-widget'); is null
[03:00] <wallyworld> StevenK: sounds plausible depending on how the ui is set up
[03:00] <wgrant> I hope this is a YUI test :)
[03:01] <StevenK> wallyworld: # is for class?
[03:01] <wallyworld> StevenK: # is for id
[03:01] <wallyworld> . is for class
[03:04] <wallyworld> poolie: looks pretty good i think. 2 nitpics. imports need to be alphabetical, person = self.factory.makePerson(...) - person is not used so you don't need to make the assignment
[03:04] <poolie> k
[03:05] <wallyworld> thanks for making all the requested changes
[03:07] <poolie> which import is wrong?
[03:08] <wallyworld> +from lp.services.mail.incoming import (
[03:08] <wallyworld> + InactiveAccount,
[03:08] <wallyworld> + authenticateEmail,
[03:08] <wallyworld> + )
[03:08] <poolie> ah, case-insensitive sort is required?
[03:09] <wallyworld> i thought so but now i am doubting myself
[03:09] <lifeless> there is a tool that will do it
[03:09] <lifeless> and yes, case insensitive
[03:09] <wgrant> utilities/format-imports
[03:09] <wgrant> Also utilities/format-new-and-modified-imports
[03:09] <lifeless> they should be in lp-dev-utils
[03:15] <poolie> which machine runs incoming.py again?
[03:15] <wgrant> loganberry
[03:28] <poolie> wallyworld, ok, i'll send it up
[03:28] <wallyworld> poolie: i was just about to mark it approved in anticipation of the last few changes being made :-)
[03:29] <wallyworld> poolie: i've approved it. did you want me to land it so that i can follow up if there's any issues?
[03:29] <poolie> that'd be good, thanks!
[03:29] <poolie> i have one more mail thing in progress so i'll go on to that
[03:29] <poolie> gl
[03:30] <wallyworld> np. i'll wait for your changes to be pushed and then throw it at ec2
[03:31] <poolie> ok, pushed
[03:33]  * wallyworld lands
[05:20] <poolie> Getting distribution for 'storm==0.19.0.99-lpwithnodatetime-r406'.
[05:20] <poolie> An error occurred when trying to install storm 0.19.0.99-lpwithnodatetime-r406. Look above this message for any errors that were output by easy_install.
[05:20] <poolie> does this mean something?
[05:21] <wgrant> poolie: Is your download-cache up to date?
[05:22] <poolie> i did just update it..
[05:22] <poolie> i have an r406 tarball
[05:22] <poolie> ah it's ok
[05:22] <poolie> i made a new chroot and it didn't have ccache, and my $CC points to it
[05:23] <wgrant> Ah
[05:23] <wgrant> That would do it indeed.
[05:28] <wallyworld> wgrant: just to double check - i got 3 ec2 runs rejected because of a pgbouncer error - that's fixed right?
[05:30] <wgrant> wallyworld: Yup
[05:30] <wallyworld> thanks, will lp-land the fuckers
[05:30] <wgrant> Why does each test in test_bugtask_search execute more than 400 queries :/
[05:35]  * StevenK stabs TAL, and then twists the knife.
[06:36] <poolie> wallyworld, my attempted landings of that branch get errors connecting to postfix
[06:36] <poolie> OperationalError: could not connect to server: Connection refused
[06:36] <poolie>        Is the server running on host "localhost" (127.0.0.1) and accepting
[06:36] <poolie>        TCP/IP connections on port 52425?
[06:36] <poolie> maybe it's just transient
[06:37] <wgrant> poolie: There should be a single failure like that
[06:37] <wgrant> I fixed it a couple of hours ago
[06:37] <wallyworld> poolie: there was a bad commit by someone which commented out the startup of pgbouncer
[06:37] <wallyworld> poolie: that has been fixed now
[06:37] <poolie> i launched these a couple of hours ago
[06:37] <poolie> ok
[06:37] <poolie> but probably before your fix
[06:37] <poolie> thanks
[06:37] <wallyworld> poolie: if that's the only error then you are good to lp-land
[06:37] <poolie> i'll leave it with you
[06:38] <poolie> 23m to go :)
[06:38] <wgrant> :(
[06:38] <wallyworld> poolie: np. what's the url? this is a different one than the mp i landed earlier?
[06:39] <poolie> it's the one you sent earlier
[06:39] <poolie> depending when you launched, you may have already caught the fix
[06:39] <poolie> i fired off an ec2 test earlier in parallel with your reviews
[06:39] <wallyworld> oh right, i haven't got the email from ec2 yet
[06:40] <wallyworld> still 1 hour to go before i get the failure email
[06:41] <poolie> you can look on its web server
[06:42] <wallyworld> poolie: sure, i was just saying out loud why i didn't realise about the failure yet :-)
[06:43] <wallyworld> wgrant: sorry, just noticed your branch, looking now
[07:00] <wallyworld> wgrant: did you know the current storm egg has the Row function?
[07:00] <wgrant> Oh, does it?
[07:00] <wgrant> That's handy.
[07:00] <wallyworld> yeah :-)
[07:06] <wallyworld> wgrant: perhaps it would be better, in searchClause() in TestBugTaskTagSearchClauses, to only call convert_storm_clause_to_string if the thing in not None and return None otherwise and then test_empty() can just assertIsNone which seems more natural and doesn't need the explanatory text
[07:06] <wgrant> wallyworld: Possibly, yeah
[07:06] <wallyworld> poolie: goodbye and good luck
[07:06] <poolie> thanks, same to you
[07:06] <wallyworld> poolie: hopefully see you around 11th June :-)
[07:07] <poolie> yep :)
[07:08] <adeuring> good morning
[07:10] <wgrant> poolie: Likewise, good luck and hopefully I'll run into you at some point!
[07:11] <poolie> yep
[07:12] <StevenK> poolie: It's a bit sad that I'm tied up for the next two weekends. :-(
[07:12] <poolie> one more critical bugfix for the road https://code.launchpad.net/~mbp/launchpad/893612-mail-too-big/+merge/101865
[07:12] <poolie> yeah it would have been nice to see you too
[07:12] <StevenK> poolie: But, have a great time on your travels, and have fun storming the Googleplex.
[07:12] <poolie> but, someone else will need to land it
[07:12] <poolie> thanks
[07:13]  * wallyworld looks at poolie's one for the road
[07:13] <StevenK> wallyworld: Right next to the poolie's one for the kerb?
[07:13] <wallyworld> lol
[07:14] <StevenK> And then another one for the other kerb?
[07:14] <StevenK> And then you still have two nature strips, footpaths, street lights ...
[07:15] <wallyworld> poolie: with incoming size check, shouldn't there be a place where the check is not done anymore and so some code should be cut out?
[07:16] <poolie> mm good point
[07:17] <wallyworld> poolie: i'd understand if you didn;t want to do it. i can pick it up if you like
[07:17] <poolie> i added a comment apologizing for doing it twice
[07:17] <poolie> but we should just delete it
[07:18] <wallyworld> i think so. so long as all mail processing goes through the code path that now does the check
[07:19] <poolie> ok fixed
[07:19]  * wallyworld hit refresh and taps fingers waiting for the new diff
[07:21] <wallyworld> as the blackboard said to mr squiggle - "hurry up"
[07:21] <poolie> upside down!
[07:22] <poolie> now that would be a nice april fools hack
[07:22] <poolie> at least for aussies
[07:22] <poolie> i wonder if you can get there in css
[07:22] <wallyworld> wgrant is too young to get that reference :-)
[07:25] <wallyworld> poolie: r=me, i will land. thank you.
[07:26] <poolie> thanks mate
[07:26] <poolie> good night and good luck
[07:26] <poolie> see you in a while
[07:26] <wallyworld> yes, will do
[07:29] <wgrant> wallyworld: I just get it :)
[09:10] <StevenK> jml: No QA? :-)
[09:10] <StevenK> :-( , rather
[09:11] <jml> StevenK: sorry, no. I got caught up in other things.
[11:16] <bac> morning adeuring  ... much reviewing today?
[11:17] <bac> adeuring, it is the first friday we've both been here in a very long time
[11:25] <adeuring> morning bac, not much to review today. ANd I must admit that simply forgot to add myself to the topic the last weeks...
[11:51] <jml> benji: I decided to take the nuclear option on ThreadsafeForwardingResult: testing it so hard that the bugs glow. See https://code.launchpad.net/~jml/testtools/tsfr-fixup/+merge/10189
[12:04] <benji> jml: interesting, looking at it now
[12:32] <benji> jml: the branch looks good, the comment at the top of  test_only_one_test_at_a_time is probably the single most valuable thing in the branch and would have saved me many hours, perhaps even a day of flailing
[12:32] <jml> benji: :)
[12:32] <benji> jml: the other test methods could really use similar descriptions of why the test is important and what it demonstrates
[12:33] <jml> benji: I tried to tell you that thing on IRC yesterday.
[12:33] <jml> or in the MP or somewhere
[12:33] <benji> jml: you succeeded :)  the day of flail preceded that
[12:33] <jml> having it in the code ++
[12:33] <jml> heh, good to know
[12:46] <jml> benji: have just pushed some documentation and comment tweaks: r263
[12:46] <benji> I'll take a look.
[12:46] <jml> benji: you might also be interested in https://code.launchpad.net/~jml/testtools/wrap-result-in-concurrent-suite/+merge/101902 and https://code.launchpad.net/~jml/testtools/tagger/+merge/101904
[12:49] <jml> anyway, now all of that is out of my head, I will return to my irregularly programmed schedule.
[12:49] <benji> jml: is there any reason not to always tag tests run concurrently?
[12:50] <jml> benji: I don't know, to be honest.
[12:50] <jml> benji: I thought about it.
[12:50] <benji> hmm, I don't know if subclassing will work for us because we don't controll the code running subunit (it's testr)
[12:51] <jml> benji: well, I don't think there's a reason for testr not to always tag tests that run concurrently :)
[12:52] <jml> benji: the reason (to give it too grand a name) I didn't tag tests automatically is because this approach felt more like "here's a bunch of components that you can assemble at will", which is more in keeping with some internal, vague, design aesthetic I have
[12:53] <benji> jml: I suppose we could do it that way.  When do you expect these three branches to land?
[12:53] <jml> benji: testtools has a 24hr timeout on code reviews.
[12:54] <benji> jml: meaning that if they aren't reviewed in 24 hours they are assumed approved?
[12:54] <jml> benji: so, I guess some time tomorrow, unless lifeless responds with deep objections.
[12:54] <jml> benji: right.
[12:54] <benji> k
[12:55] <jml> benji: obviously we allow for post-merge reviews, and I'd certainly like to get a second opinion from lifeless before a release.
[12:55] <benji> makes sense
[13:00] <deryck> Morning, folks.
[13:01] <rick_h> morning
[13:02] <jml> hmm.
[13:02] <jml> I guess this leaves a natural opening for a subunit tool that takes multiple input streams and generates one output stream.
[13:32] <deryck> abentley, ping for standup
[13:33] <jml> I'm getting tracebacks running webservice tests, to do with the google service
[13:33] <jml> http://pastebin.ubuntu.com/927931/
[13:36] <jml> ah, maybe that's because I didn't update my /etc/hosts file
[13:37] <jml> (wow, the things you forget!)
[13:40] <benji> the things we forget are the things we shouldn't be expected to remember <0.2 wink>
[13:46] <jml> https://code.launchpad.net/~jml/launchpad/expose-commercial-on-create-ppa/+merge/101907
[13:46] <jml> 1 line patch.
[13:46] <jml> flacoste: hello
[13:46] <flacoste> hi jml
[13:46] <jml> flacoste: may I please have a LoC exception for https://code.launchpad.net/~jml/launchpad/expose-commercial-on-create-ppa/+merge/101907
[13:46] <jml> flacoste: also, if you could review & land it, that'd be great too.
[13:49] <flacoste> jml: i'm kind of swamped today, so i may look for the exception, but review and land will have to be delegated
[13:50] <jml> flacoste: no worries. it's a one-line patch, if that helps.
[13:53] <jml> abentley: you moved ec2test to lp-dev-utils, right? how do I run the tests there?
[13:53] <abentley> jml: I was using nosetests.
[13:56] <jml> abentley: any PYTHONPATH mangling required? (it seems to depend on 'lp'?)
[13:57] <abentley> jml, no.  I run "nosetests ec2test" and it seems happy.  I think there are two failing tests.
[13:58] <jml> abentley: oh, there are failing tests in trunk? What failures do you  get?
[13:58] <abentley> jml: https://pastebin.canonical.com/64277/
[13:59] <jml> abentley: cool. those are the ones I get. thanks.
[13:59] <abentley> jml: IIRC, fakemethod is also provided by bzr-pqm.
[14:00] <jml> abentley: ta.
[14:18] <jml> abentley: different API, it seems.
[14:19] <jml> FakeMethod in bzr-pqm (at least the version on the system that comes via rocketfuel-setup) doesn't have call_count.
[14:19] <abentley> jml: doh.  I guess we should have been more aggressive about switching this code to bzr-pqm originally.
[14:20] <jml> abentley: well this particular thing is just about using a home-rolled mocking library, right?
[14:20] <abentley> jml: Yes.
[14:22]  * jml is tempted to re-implement
[14:22] <jml> brb
[14:40] <jml> abentley: https://code.launchpad.net/~jml/lp-dev-utils/fix-tests/+merge/101916
[14:41] <abentley> jml: I said earlier that PYTHONPATH does not need to be set.  What makes you say it does?
[14:41] <jml> abentley: because setting it makes the test pass.
[14:41] <abentley> jml: Which tests does it make pass?
[14:42] <jml> abentley: ec2test.tests.test_remote.TestDaemonizationInteraction.test_daemonization
[14:42] <jml> abentley: the error indicates that it can't find ec2test.remote
[14:42] <jml> abentley: but of course, ec2test.remote exists and is perfectly easy to find, if you have PYTHONPATH set so that the 'ec2test' package is discoverable.
[14:46] <abentley> jml: When I want subprocesses to have the same pythonpath as the current process, I usually set it in the code that invokes the subprocess.
[14:47] <jml> abentley: well, not when you're hacking on Launchpad you don't. You use ./bin/py.
[14:47] <abentley> jml: I can use bin/py when I'm hacking on Launchpad.
[14:48] <jml> abentley: so you suggest converting turning sys.path into an env var and passing that through in the code that spawns the subprocess?
[14:48] <abentley> jml: Yes.
[14:49] <jml> abentley: got a shell quoting function handy?
[14:50] <abentley> jml: I don't understand why I would need one.  Are you saying that python shell-expands the contents of PYTHONPATH?
[14:50] <rick_h> deryck: ping, do you have a sec? I'm not seeing tests for any of these cases and I'm feeling like I must be missing something
[14:50] <rick_h> I'm wearing grep out I think
[14:52] <abentley> jml: Testing shows python does not shell-expand PYTHONPATH.  It does not expand $PETER in this example: http://pastebin.ubuntu.com/928037/
[14:53] <rick_h> oh man, nvm...having a monday for a friday. limiting to .py files won't find a bunch of tests :/
[14:53] <rick_h> deryck: ^
[14:56] <jml> abentley: what if sys.path has paths that have a space or a colon.
[14:58] <jml> space seems to work
[14:58] <cjwatson> shell quoting when spawning subprocesses is a really bad idea
[14:58] <cjwatson> use the functions that don't require shell quoting instead ...
[14:58] <abentley> cjwatson: agreed.
[14:59] <jml> OEK
[14:59] <jml> OK
[14:59] <cjwatson> e.g. subprocess.Popen and friends let you pass env=, so you copy os.environ and replace the keys you want directly
[14:59] <jml> Pretend I didn't say shell quoting. How do you safely turn sys.path into a value for PYTHONPATH that works regardless of what crazy paths are in sys.path?
[14:59] <abentley> cjwatson: Sure.
[15:01] <deryck> rick_h, sorry, was on call.
[15:02] <deryck> rick_h, I'm just about to step in another call.  can we chat after that?
[15:02] <rick_h> deryck: I think I'm ok now. Sorry for the ping
[15:02] <abentley> jml: I don't know how to escape colons in a PATH.  Looking into it.
[15:02] <deryck> rick_h, dude, no worries.  always ping when in doubt.  sorry it took me so long to reply.
[15:02] <cjwatson> AFAICS there's no way to wedge an entry containing os.pathsep into PYTHONPATH.
[15:03] <cjwatson> The good news is that, since it can't have got into sys.path via PYTHONPATH, the only way such a directory would be on sys.path is if you put it there yourself.
[15:08] <jml> fsvo 'you'
[15:08] <abentley> cjwatson: Exception: https://pastebin.canonical.com/64293/
[15:09] <jelmer> is it still impossible to rename teams with PPAs that have been deleted, but were published in the past?
[15:10] <jml> anyway, I've pushed up an os.pathsep.join(sys.path) version and updated the docs.
[15:11] <abentley> jml: I think you can also update testr.conf
[15:12] <jml> abentley: I tried. It fails when cwd isn't in PYTHONPATH
[15:13] <jml> abentley: I can't speak for nosetests, but I'm pretty sure trial adds '.' to the sys.path as a convenience.
[15:13] <abentley> jml: I saw 123 tests.  Are you seeing only 84?
[15:13] <jml> abentley: trial shows 88
[15:14]  * jml runs w/ nosetests
[15:15] <jml> abentley: 125 w/ nosetests
[15:17] <jml> abentley: I think that's because nosetests incorrectly discovers the TestRequest tests (from test_remote) inside remote_daemonization_test.py
[15:18] <jml> abentley: which imports TestRequest in order to get at a helper function.
[15:18] <abentley> jml: Okay, cool.  So long as we know why it happens.
[15:19] <jml> abentley: it's a little fiddly to extract, because the helper relies on bzrlib.TestCase*'s make_branch_and_tree
[15:19] <jml> I really should have pushed harder to get that stuff extracted out of the TestCase inheritance hierarchy.
[15:21] <jml> brb
[15:28] <abentley> jml: r=me
[15:28] <jml> abentley: thanks. How do I land it?
[15:28] <abentley> jml: We just push to that branch.
[15:29] <jml> \o/
[15:29] <jml> abentley: I don't have commit access to that branch.
[15:29] <abentley> jml: I will do it, then.
[15:29] <jml> abentley: thanks.
[15:31] <abentley> jml: I am going to add .testrepository to the list of ignored files.
[15:31] <jml> abentley: good call. I think I have it in my global ignore
[15:32] <jml> oh that reminds me
[15:32] <jml> bac: thanks for the review. can you please submit my branch to ec2 test?
[15:34] <abentley> jml: landed.
[15:35] <jml> abentley: thanks.
[15:40] <rick_h> 362877
[15:41] <abentley> rick_h: 32568
[15:42] <rick_h> abentley: bah, my secret it out
[15:45] <abentley> adeuring: chat?
[15:45] <adeuring> abentley: sure. mumble?
[15:46] <abentley> adeuring: sure.
[15:55] <rick_h> deryck: sanity check time, I'm not seeing the sendmail.simple_sendmail work through the IMailer and so stub.test_emails no longer works.
[15:55] <rick_h> deryck: in checking out how the sendmail it seems to be straight monkey patching/revert? http://paste.mitechie.com/show/616/
[15:56] <rick_h> deryck: so I should be doing this in the doctest for checking the notification emails? or am I not seeing the magic pretty way to do it like stub.test_emails?
[15:59]  * deryck is readying back, thinking.....
[16:02] <deryck> rick_h, stub.test_emails is how we normally inspect mail in doctest.  and that doesn't work when calling sendmail in process.  I get that problem right?
[16:03] <rick_h> deryck: right, sendmail.simple_sendmail doesn't hit the stub.test_mails bit
[16:04] <rick_h> deryck: and it looks like it's because it doesn't use/implement the IMailer interface that stub is working against
[16:04] <deryck> rick_h, right.  it's just a function that calls sendmail directly, IIRC.
[16:04] <rick_h> deryck: basically updating hte doctest to monkey patch and restore sendmail.simple_sendmail is ugly as can be and tossing out a last ditch effort I'm missing something
[16:05] <rick_h> deryck: right, looks like it
[16:05] <deryck> rick_h, yeah, 1) I wouldn't monkey patch in doctest. I'd create a doctest helper if needed, and 2) we have to have something for this already, let me look more....
[16:06] <rick_h> deryck: rgr on 1, figured I'd need to do that since I'm updating several doctests to get this tested for each notification
[16:15] <deryck> rick_h, so I really thought when someone is subscribed to a bug, that we send them a notification in process in this same way....
[16:15] <deryck> rick_h, kind of a wart I'm recalling that we sent mail in process.
[16:16] <deryck> rick_h, and the testing is the same it seems. see: lib/lp/bugs/stories/bugs/bug-add-subscriber.txt
[16:16] <deryck> rick_h, so either, I'm wrong and we don't do it in process, or you can look there and work out what is different about that test that it works.
[16:17] <rick_h> deryck: ok, will look there. Probably using a different method of sending the emails than the simple_sendmail
[16:17] <rick_h> deryck: thanks
[16:22] <deryck> rick_h, so the subscription stuff does use the event system to trigger sending mail, but it still just wraps a callback that calls sendmail directly, which is at heart the same thing you're doing....
[16:23] <deryck> rick_h, see lp.bugs.subscribers.bug.send_bug_details_to_new_bug_subscribers to see how the mail is sent....
[16:23] <deryck> rick_h, and the stub mailer works fine there.
[16:23] <rick_h> deryck: looking
[16:29] <deryck> rick_h, should we high bandwidth this in a hangout?
[16:29] <rick_h> deryck: sorry, trying to pdb to see if I'm actually hitting the email code like I think I am and so is stub emails blank because simple_sendmail doesn't hit it, or my code isn't working like I think it should
[16:30] <rick_h> except in doctest having a hard time seeing if I'm hitting pdb because of hte block of code I think I am
[16:30] <rick_h> pdb doensn't show me the line num of the doctest in the path so not sure if it's a test before/after the one I'm trying to see
[16:30] <deryck> rick_h, yeah, that's why I was thinking hangout.... we could step though the paths together.
[16:30] <rick_h> deryck: sorry, long way of saying give me a few min
[16:31] <rick_h> deryck: k, hangout is ok then
[16:31] <deryck> rick_h, yeah, let's do, just to possibly save you some frustration.
[16:31] <rick_h> deryck: ok, we can try :)
[16:55] <rick_h> ok, if in doubt, transaction.commit!
[17:54] <bac> hi abentley , i'm finding when i run out tests within an lxc that many (perhaps all) of the celery tests fail with a timeout.  can you give me some advice on tracking this down?
[17:54] <bac>  s/out/our
[17:54] <abentley> bac: with you in a minute.
[17:55] <abentley> bac: Okay.
[17:56] <abentley> bac: So, the timeout is emitted from a line that says something like responses[0].wait ?
[17:56] <bac> http://paste.ubuntu.com/927046/
[17:56] <bac> abentley, yeppers
[17:57] <bac> abentley, ignore the 'whoami' errors, those have been resolved
[17:57] <bac> only interested in the timeouts
[17:58] <abentley> bac: So this means that rabbitmq did not send a message saying the job was processed in 30 seconds.
[17:58] <abentley> bac: possible causes: celeryd did not start correctly
[17:58] <abentley> bac: celeryd was not listening to the correct rabbitmq instance
[17:59] <abentley> bac: Not sure what else.
[17:59] <bac> abentley, should celeryd be running outside of the tests?
[18:00] <abentley> bac: No, the tests that need it will start it.  lp.services.job.tests.celeryd is a context manager that starts and stops celeryd.
[18:00] <bac> ok
[18:01] <abentley> bac: does this happen if you restrict the tests to just ones using celery (e.g. "-t Celery") ?
[18:03] <bac> abentley, let me try
[18:04] <abentley> bac: I am guessing that if all the celery tests run on process, they work, but if they run on different processes they don't.
[18:04] <abentley> s/run on process/run on one process/
[18:05] <abentley> bac: rebooting.  Back in a sec.
[18:09] <abentley> bac: My best guess is that celeryd will be using the RabbitMQ config associated with another process.
[18:11] <abentley> bac: To test this, we could print celeryd's Popen.stderr.  That will indicate the broker config.  The Popen object is yielded by lp.services.job.tests.celeryd.
[18:11] <bac> ok
[18:11] <abentley> bac: in some tests, it's referred to as "proc".
[18:12] <bac> abentley: Total: 12 tests, 2 failures, 5 errors in 5 minutes 25.011 seconds.
[18:12] <abentley> bac: Okay, cool.  We can reproduce it, then.
[18:15] <abentley> bac: lp.code.model.tests.test_branch.TestBranchJobViaCelery.test_branchChanged_via_celery show a "Function not implemented" OS error.
[18:15] <abentley> bac: That may be the root cause of all of this.
[18:17] <bac> abentley, where do you see that FNI error?
[18:18] <abentley> bac: line 279 of your paste.
[18:18] <abentley> bac: reconstructed: http://pastebin.ubuntu.com/928292/
[18:19] <bac> abentley, hey, that makes sense as there is a problem with lxc and semaphores
[18:19] <abentley> bac: yay?
[18:20] <bac> abentley, cool, thanks for the pointer
[18:20] <abentley> bac: np.
[18:23] <abentley> bac: if celeryd is incompatible with lxc, I guess the options are 1. fix lxc, 2. fix celeryd, 3. run celery tests outside lxc.
[18:24] <abentley> 4. run celeryd outside lxc, run tests that use it inside lxc.
[18:44] <SpamapS> Hey we're getting ready to bump the 'charms' distribution from oneiric->precise .. which means a LOSA running the script that does that. I forget who I need to ping to get that done.
[18:44] <SpamapS> flacoste: any ideas? ^^
[18:45] <james_w> SpamapS, copying branches, or just setting the precise as the default release?
[18:45] <flacoste> james_w: he probably wants to copy branches also
[18:45] <flacoste> or rebase them
[18:46] <james_w> SpamapS, either way saying "webops ping" will get you a friendly webops (neé LOSA) to help when it is time
[18:46] <SpamapS> I want to do both
[18:46] <james_w> (sorry webops)
[18:47] <SpamapS> we need to shift dev focus to precise, and copy all the oneiric branches to precise.
[18:47] <SpamapS> so they'll know the script to do it?
[18:47] <SpamapS> also will the mass copy process just ignore anything that has already diverged in precise?
[18:47] <SpamapS> I asssume yes
[18:54] <james_w> SpamapS, https://wiki.canonical.com/InformationInfrastructure/OSA/LPHowTo/BranchUbuntu?highlight=%28branch%29|%28distro%29
[18:54] <james_w> that's the script we use for Ubuntu
[18:54] <james_w> I don't know how it handles existing branches though
[18:56] <james_w> it looks like it might not handle it all that well
[20:10] <bac> abentley, i just saw this commit message of yours and had to laugh:  "There's no j in Launchpad."
[20:10] <abentley> bac: :-)