/srv/irclogs.ubuntu.com/2013/03/21/#launchpad-dev.txt

StevenKwgrant: Thoughts about http://pastebin.ubuntu.com/5632908/ for bug 888049 ?01:05
_mup_Bug #888049: garbo-frequently logged an oops <oops> <Launchpad itself:Triaged> < https://launchpad.net/bugs/888049 >01:05
StevenKIf you say it's good, I'm going to self-review the branch and land, but want your thoughts first.01:06
wgrantStevenK: It's not ideal, but it's probably OK01:16
wgrantWe might want some sort of threshold01:16
wgrantBut this is probably OK for now01:16
StevenKwgrant: Threshold? For what?01:18
StevenKThat warning only fires if a tuner is getting killed because the script is.01:18
wgrantStevenK: Sure01:19
wgrantStevenK: But we probably sort of want to warn if it legitimately doesn't finish01:19
wgrantBut not if it was blocked all the time01:19
wgrantAnyway, this seems OK01:19
wgrantfor now01:19
StevenKOh, wait a moment.01:34
StevenKThe bug is about the looptuner warning, not the script warning.01:35
=== heroux_ is now known as heroux
StevenKwgrant: https://code.launchpad.net/~stevenk/launchpad/garbo-abort-info/+merge/15459205:29
wgrantStevenK: Can you adjust the logger's level so the tests can test what they're testing?05:32
StevenKwgrant: It's a nice plan, but doesn't love me much.05:42
StevenKwgrant: http://pastebin.ubuntu.com/5633274/ fails05:51
StevenKwgrant: The INFO lines aren't printed, but everything else for those blocks is05:51
wgrantStevenK: What if you pass a custom logger into the tuner?05:56
StevenKIf I create a BufferLogger, set its level to INFO and then make use of loop.log.use(), it also doesn't print INFO line05:57
wgrantStevenK: Even if you print the content of the buffer?05:59
StevenKwgrant: http://pastebin.ubuntu.com/5633308/06:09
wgrantStevenK: I would suggest overriding the tuner's log argument06:12
wgrant"""        Why a custom BatchNavigator is required is a great mystery and06:15
wgrant        should be documented here.06:15
wgrant        """06:15
StevenKwgrant: http://pastebin.ubuntu.com/5633323/06:26
StevenKAnd oh dear06:26
wgrantStevenK: Have you looked at the script logging infrastructure to see how it does the level override?06:28
wgrantIt probably has some custom filter preventing setLevel from working06:29
StevenKwgrant: I had a little bit of a dig, but not much.06:30
StevenKThe logger stuff is ... odd06:30
czajkowskialoha08:45
jamfrankban: looking here: https://launchpad.net/~gophers/+related-projects there is "golxc" is that something that should stay in ~gophers or move to ~juju?08:57
frankbanjam: I don't know, I suggest to ask on #juju-dev09:12
jamsorry frankban, I was in the wrong window. Thanks for understanding09:12
jam(I was looking for Frank in #juju-dev, but didn't notice the irc window)09:13
frankban:-)09:13
=== yofel_ is now known as yofel
=== almaisan-away is now known as al-maisan
=== al-maisan is now known as almaisan-away
=== wedgwood_away is now known as wedgwood
=== Ursinha_ is now known as Ursinha
=== Gwaihir_ is now known as Gwaihir
=== Ursinha is now known as Ursinha-afk
=== Ursinha-afk is now known as Ursinha
=== deryck is now known as deryck[lunch]
=== deryck[lunch] is now known as deryck
marcoceppiHi all, I'm having a weird issue using launchpadlib on Windows21:23
marcoceppiWhenever I run the script using launchpadlib I get this SSL error http://paste.ubuntu.com/5635134/21:24
marcoceppiHappens on Windows Server 2012 on EC2 and a local Windows 7 machine21:24
wgrantmarcoceppi: You probably need to override the CA certificate list path21:30
marcoceppiwgrant sounds straight forward, would this need to happen in the code or on the machine?21:31
wgrantmarcoceppi: SYSTEM_CA_CERTS in lazr.restfulclient._browser21:33
marcoceppiwgrant I replaced C:\Python27\Lib\site-packages\httplib2\cacerts.txt with latest from upstream without success.21:34
wgrantmarcoceppi: You'll need to change the path in the module that I referenced.21:35
marcoceppiwgrant: thanks21:35
marcoceppiwgrant: so, bascially because SYSTEM_CA_CERTS is hardcoded n lazr.resfulclient._browser it'll just never be portable beyond Ubuntu?21:39
wgrantmarcoceppi: There's no standard way to find a list of CA certifactes, unfortunately. A list of fallbacks could be added if someone interested did it, but that's all we have today.21:42
=== Ursinha is now known as Ursinha-afk
marcoceppiwgrant I've got a small patch that'll at least make lazr.resfulclient work on non-debian/ubuntu platforms while maintaining proper ubuntu support https://code.launchpad.net/~marcoceppi/lazr.restfulclient/system-ssl-certs/+merge/15482122:10
wgranterm22:14
wgrantWhen did httplib2 become not totally insane...22:14
wgrantHuh, that actually works22:14
wgrantI guess someone must have finally convinced Python people that making it extremely awkward to use HTTPS was actually a stupid idea :)22:15
wgranthttplib2.CA_CERTS has only existed for about a year, it seems22:15
wgrantmarcoceppi: It might be worth having it the other way around22:15
marcoceppiwgrant FWIW, CA_CERTS works on Windows, though I haven't tested that path directly on Ubuntu22:16
wgrantSee if httplib2.CA_CERTS is importable, and if it is use that. Otherwise catch the ImportError and use the hardcoded path22:16
marcoceppiwgrant, ah that makes more sense. I'll update my merge request22:16
wgrantmarcoceppi: The path is correct on Ubuntu too; the reason we didn't use it is that it didn't exist22:16
wgrantEveryone hardcoded their own paths because httplib2 was stupid :/22:16
wgrantBut they finally saw sense22:16
marcoceppiglad they wised upppppp22:17
marcoceppiwow, keyboard lag22:17
wgrantHeh22:17
marcoceppiwgrant merge updated22:19
wgrantmarcoceppi: Hm, actually, look at the NEWS entry in http://bazaar.launchpad.net/+branch/lazr.restfulclient/revision/13422:24
wgrantmarcoceppi: Maybe httplib2's been fixed, if it works on Windows for you?22:24
marcoceppiIt does work on Windows for me now, however I realize I don't have a standard cacerts.txt file. I downloaded a new one from upstream. Let me see what was bundled22:25
marcoceppi*let me try what came bundled22:25
marcoceppiNope, the one that came with httplib2 that was downloaded earlier today works fine22:26
marcoceppiI'm able to get responses from lp, etc. So rev 134 just needs to be reversed?22:27
wgrantWhich version of httplib2 are you using?22:27
wgrantFor safety we might want to go with what you originally had, since old Ubuntu releases might have a bad httplib2.22:28
marcoceppi0.8-py2.722:28
wgrantAh22:28
wgrantWe have 0.7.2ish22:28
marcoceppiAh, so the original commit would have been better22:28
marcoceppiActually, shouldn't the import of CA_CERTS still throw an ImportError if it's not in 7.2ish22:29
wgrantEr yeah22:29
wgrantWith the ImportError catching22:29
wgrantIndeed22:29
* marcoceppi double checks22:30
wgrantSo if the existing hardcoded path exists, use that. Otherwise try to import httplib2.CA_CERTS and use that.22:30
wgrantSo basically what you had before, except with the CA_CERTS import guarded22:30
marcoceppiwgrant cool, I'll update the merge again22:31
wgrantThanks.22:31
marcoceppiSo, for the catch, shouldn't it actually raise an error. Because there's no CA_CERTS, and no hardcoded path available22:32
marcoceppiI feel like it'd be better to throw a more sane error there than just having the current error which is really misleading22:33
wgrantPossibly. Even the ImportError would probably be more sensible than what's there now22:34
wgrantSo maybe don't catch the exception, but only try the import if the hardcoded path doesn't exist?22:34
marcoceppiwgrant: ack22:34
StevenKWhich then results in people having to know why _browser is throwing an ImportError22:34
wgrantStevenK: It's going to be fairly clear22:35
wgrantBecause the line will be 'from httplib2 import CA_CERTS' :)22:35
czajkowskiStevenK: morning22:35
StevenKczajkowski: HAI22:37
=== Ursinha-afk is now known as Ursinha
marcoceppiwgrant: rebased and resubmitted the merge request https://code.launchpad.net/~marcoceppi/lazr.restfulclient/system-ssl-certs/+merge/15482622:41
marcoceppiThanks for the help!22:44
wgrantmarcoceppi: looks good, but I have suggested an optional change in the MP22:44
wgrantI see you've already signed the contributor agreement, so I can land this right away if you want22:44
marcoceppiwgrant: I'll just implement your change, and you can feel free to land22:44
wgrantThanks, will do22:44
marcoceppiwgrant: awesome, this will help move things along22:46
wgrantmarcoceppi: Actually, I've just had yet another thought23:08
wgrantIt presumably defaults to CA_CERTS internally...23:08
marcoceppipresumably23:08
wgrantBut it wouldn't really be any cleaner to avoid overriding the default, so I guess this is fine23:09
wgrantNevermind :)23:09
marcoceppiHopefully when all ubuntu distros are at >httplib2-0.8 this whole workaround can just be dropped. At least until httplib2 does something silly again23:10
wgrantAll supported releases should have httplib2.CA_CERTS already, I think, but I don't want to rely on it just yet.23:11
wgrant(0.7.2 was backported to -security on the basis that the old one was basically impossible to secure)23:12
* marcoceppi nods23:12
StevenKwgrant: What was your objection about http://pastebin.ubuntu.com/5635613/ ?23:43
wgrantStevenK: I don't think I saw that.23:55
wgrant'cause that's basically ideal :)23:55

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