StevenK | wgrant: Would you hate me for using lp.services.webapp.adapter for this request munging? | 00:13 |
---|---|---|
wgrant | StevenK: adapter is more to do with the DB | 00:17 |
StevenK | wgrant: I can add lp.services.webapp.utils if you wish, I can't see anything close-ish | 00:18 |
wgrant | StevenK: Or in publisher? | 00:19 |
StevenK | publisher works | 00:21 |
StevenK | wgrant: http://pastebin.ubuntu.com/1614625/ | 00:45 |
wgrant | StevenK: You'll probably only want to refetch when you're called from the API | 00:46 |
wgrant | (by using eg. @callwith(from_api=True)) | 00:46 |
wgrant | Otherwise adding an attachment or release file from the UI will find a request that lacks what it needs, or the field might have a different meaning | 00:46 |
StevenK | No, the field name is different | 00:46 |
wgrant | Right now, yes | 00:46 |
StevenK | It's field.<foo> from the UI | 00:46 |
wgrant | Then someone changes it and the world breaks | 00:47 |
wgrant | Far better to be explicit here | 00:47 |
wgrant | When committing evil, you want to be *really* sure that it's not going to have unintended consequences | 00:47 |
wgrant | Also, get_raw_form_value_from_current_request or something | 00:47 |
wgrant | refetch_file_content does not well convey the magnitude of the evil | 00:48 |
StevenK | wgrant: omg_it_burns_and_refetch ? | 00:48 |
wgrant | StevenK: Might even be an idea to assert in the function that it's an API request | 00:48 |
wgrant | Just in case | 00:48 |
wgrant | It might eventually be needed outside API requests, but the added paranoia would feel nice right now | 00:49 |
StevenK | wgrant: And what do you suggest as a name? | 00:50 |
wgrant | get_raw_form_value_from_current_request? | 00:51 |
wgrant | Maybe throw a 'horrid', 'evil', 'vile' or 'unsafe' in there somewhere | 00:51 |
StevenK | Which is horribly long | 00:54 |
wgrant | Good | 00:56 |
wgrant | Lucky it only has two callsites :) | 00:56 |
StevenK | The import is 80 characters | 00:56 |
StevenK | And now buildmailman fails? | 01:14 |
StevenK | wgrant: buildmailman dies due to: | 01:28 |
StevenK | no lists == nothing to do, exiting | 01:28 |
StevenK | make[1]: Leaving directory `/home/steven/launchpad/lp-sourcedeps/sourcecode/mailman' | 01:28 |
wgrant | StevenK: Is that a problem? | 01:33 |
StevenK | Yes, since make run fails | 01:33 |
wgrant | Fails how? | 01:33 |
StevenK | make: *** [compile] Error 1 | 01:34 |
wgrant | Have you tried deleting lib/mailman and rerunning? | 01:34 |
StevenK | That's the next line | 01:34 |
StevenK | Compiling /home/steven/launchpad/lp-branches/handle-invalid-unicode-in-query-string-redux/lib/mailman/Mailman/versions.py ... | 01:34 |
StevenK | No updates are necessary. | 01:35 |
StevenK | make[1]: Leaving directory `/home/steven/launchpad/lp-sourcedeps/sourcecode/mailman' | 01:35 |
StevenK | make: *** [compile] Error 1 | 01:35 |
StevenK | wgrant: ^ That's after deleting lib/mailman | 01:43 |
wgrant | StevenK: Perhaps make clean | 01:44 |
StevenK | wgrant: make clean && make lead to the no lists == nothing to do error | 01:46 |
StevenK | Handy. Something in my diff causes it | 02:01 |
wgrant | StevenK: Hm, but lp.services.webapp.publisher is fairly widely imported | 02:03 |
wgrant | So there should be minimal circular issues | 02:03 |
StevenK | I'll binary search through the diff after lunch | 02:04 |
StevenK | WAT | 03:06 |
StevenK | % bzr di lib/lp/services/webapp/publisher.py | head -n 37 | tail -n 1 | 03:07 |
StevenK | +from lp.services.webapp.servers import WebServiceClientRequest | 03:07 |
StevenK | That is what causes buildmailman to lose its mind | 03:07 |
StevenK | So I guess it's circular, but eh .... | 03:08 |
StevenK | And now the FieldStorage is empty :-( | 03:25 |
* StevenK mutters at IProductRelease._getFileObjectAndSize | 03:56 | |
StevenK | wgrant: It asserts it is passed a file or StringIO | 03:57 |
wgrant | StevenK: You're not giving it a StringIO? | 04:34 |
StevenK | FieldStorage returns an object that identifies itself as cStringIO.StringO | 04:35 |
StevenK | Ah, the critical bug didn't get re-opened when you reverted the fix? | 04:37 |
wgrant | No, I forgot to | 04:37 |
StevenK | Eh | 04:37 |
StevenK | I'll just link the High bug then | 04:37 |
wgrant | No | 04:38 |
wgrant | Reopen | 04:38 |
wgrant | I think | 04:38 |
StevenK | And then close the two of them? | 04:38 |
wgrant | It fixes both | 04:38 |
wgrant | So why not :) | 04:38 |
StevenK | wgrant: https://code.launchpad.net/~stevenk/launchpad/handle-invalid-unicode-in-query-string-redux/+merge/146773 | 04:45 |
StevenK | But I've just realized I don't have an XXX | 04:45 |
wgrant | StevenK: Reviewing cjwatson's branch atm (finally!), will do that after | 04:46 |
StevenK | Let me file a bug and add an XXX to both callsites. | 04:46 |
StevenK | Since you asked me to on the call this morning | 04:47 |
wgrant | Yeah | 04:47 |
wgrant | It's clearly a terrible hack, so deserves an XXX or three | 04:47 |
StevenK | wgrant: Against lazr.restfulclient ? | 04:48 |
wgrant | StevenK: LP | 04:50 |
wgrant | The hack is in LP | 04:50 |
lifeless | flacoste: o/ | 06:13 |
StevenK | wgrant: Do I get a review now? | 07:01 |
wgrant | StevenK: You run it through StringIO in one case but not the other? | 07:04 |
StevenK | wgrant: Yes. IBug.addAttachment just wants to read() from it, whereas IProductRelease.add_file actually cares if it's a StringIO or file. | 07:05 |
wgrant | StevenK: Ah | 07:05 |
wgrant | StevenK: If there's a launchpadlib-based test for add_file, can you extend it to verify correct behaviour? | 07:05 |
wgrant | XXX and bug reference in the Function of Doomâ„¢ too, pls | 07:06 |
* StevenK peers at this horrible doctest | 07:08 | |
wgrant | Even if there isn't one already, they're pretty short to write (but long to run), so it's probably worth adding one | 07:08 |
StevenK | wgrant: There are two sections that add a PRF to firefox, just need to work out how to get the content of the file easily | 07:09 |
StevenK | Changing the content of one of the strings would be easy | 07:10 |
StevenK | '\x1f\x0cf\xff' seems good enough | 07:11 |
adeuring | good morning | 08:50 |
jtv | Guten Morgen adeuring | 08:58 |
adeuring | hi jtv! | 08:59 |
czajkowski | ello | 09:31 |
jtv | Hi there czajkowski | 10:08 |
czajkowski | jtv: hey hows things? | 10:11 |
jtv | czajkowski: nice and busy. | 10:13 |
jtv | Also, more expensive than last year. :) | 10:13 |
czajkowski | why's that? | 10:14 |
jtv | Just a general observation. Things are more expensive than last year. Apply to any given year. | 10:15 |
jml | jtv: deflation has been known to happen. | 10:22 |
czajkowski | jtv: I just moved out of london, it brought it down a meer fraction of cost | 10:22 |
jtv | jml: Mostly local though. For the true pessimist there is always a lead lining _somewhere_ in the world. | 10:22 |
jml | jtv: :) | 10:23 |
jtv | Pessimism: because if failure is your goal, you really can't lose. | 10:23 |
=== slank_away is now known as slank | ||
=== matsubara is now known as matsubara-lunch | ||
=== matsubara-lunch is now known as matsubara | ||
=== Ursinha is now known as Ursinha-afk | ||
=== Ursinha-afk is now known as Ursinha | ||
=== Ursinha is now known as Ursinha-afk | ||
=== Ursinha-afk is now known as Ursinha | ||
=== matsubara is now known as matsubara-afk |
Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!