/srv/irclogs.ubuntu.com/2009/10/12/#launchpad-reviews.txt

=== abentley1 is now known as abentley
=== ursula is now known as Ursinha
=== jtv changed the topic of #launchpad-reviews to: on call: — || reviewing: — || queue: [jtv] || This channel is logged: http://irclogs.ubuntu.com
=== mrevell is now known as mrevell-lunch
=== bigjools is now known as bigjools-phone
stubrockstar: Do you want to review https://code.edge.launchpad.net/~stub/launchpad/replication/+merge/13203 since it is your bug?13:09
=== bigjools-phone is now known as bigjools
=== mrevell-lunch is now known as mrevell
=== EdwinGrubbs2 is now known as EdwinGrubbs
=== barry` is now known as barry
=== barry` is now known as barry
=== stub1 is now known as stub
=== intellec` changed the topic of #launchpad-reviews to: on call: intellectronica || reviewing: — || queue: [jtv] || This channel is logged: http://irclogs.ubuntu.com
=== intellec` changed the topic of #launchpad-reviews to: on call: intellectronica || reviewing: adeuring || queue: [jtv] || This channel is logged: http://irclogs.ubuntu.com
=== intellec` is now known as intellectronica
intellectronicaadeuring: why `device['E'].get('SUBSYSTEM')` and not `device['E']['SUBSYSTEM']` ?16:20
intellectronicaadeuring: or is it not a get from a dictionary-like object?16:20
adeuringintellectronica: it is a dict. Let me check, if we can guaraty if SUBSYSTEM is always defined....16:21
intellectronicaright16:21
adeuringintellectronica: no, SUBSYSTEM is _not_ always defined.16:22
adeuringintellectronica: to reproduce: udevadm info --export-db16:22
intellectronicaah ok, so get might return None16:22
adeuringintellectronica: exactly16:22
intellectronicaI'd supply the extra parameter, just for readability16:22
adeuringintellectronica: do you mean a sort of an explicit marker?16:23
intellectronicaadeuring: device['E'].get('SUBSYSTEM', None)16:23
adeuringintellectronica: hrmm... I am not generally opposed to that, but IÄ'd gues that other reviewers might suggest to remove the second parameter ;)16:24
intellectronicaadeuring: the docstring of is_scsi_device can terminate on the first line, no?16:24
adeuringintellectronica: right, changed16:24
intellectronicaadeuring: you think so? i'll leave it for you to decide, but i think explicit is better than implicit16:24
adeuringintellectronica: as I said, I don't have a definite opinion on this. Something for the reveiwer meeting?16:25
intellectronicasure, or we can even ask barry what he thinks16:26
* barry thinks it's all wrong! oh wait...16:27
intellectronicai don't feel strongly about this, it meant literally what i would do16:27
intellectronicabarry: abel writes dict.get('sumfin') and i like dict.get('sumfin', None)16:28
intellectronicabecause i always forget what the default behaviour is16:28
barryintellectronica: i don't think you need that.  every python developer knows .get() returns None by default if the key is missing :)16:28
barryintellectronica: that's deeply ingrained in python dna :)16:28
barryhowever, if it's possible that 'sumfin' is in the dict with a value of None, then it's much better to do something like:16:29
barrymissing = object()16:29
barrydict.get('sumfin', missing)16:29
adeuringbarry: that's not the case here16:29
barryadeuring: cool.  in that case .get('foo') is fine16:29
intellectronicaadeuring: you see, i'm talking nonsense. clearly i'm not (genetically speaking) a python developer :)16:30
adeuringintellectronica: ;) the point is that you can deevelop Python genes ;)16:30
barryintellectronica: too much javascript will rot your brain16:30
intellectronicaadeuring: other than that docstring it all looks great. r=me16:35
adeuringintellectronica: thanks!16:35
=== intellectronica changed the topic of #launchpad-reviews to: on call: intellectronica || reviewing: - || queue: [jtv] || This channel is logged: http://irclogs.ubuntu.com
=== intellectronica changed the topic of #launchpad-reviews to: on call: intellectronica || reviewing: jtv || queue: [] || This channel is logged: http://irclogs.ubuntu.com
nhandlerDoes anyone know what file sets the 'Invalid value' error message for the subscription fields?16:38
=== intellectronica changed the topic of #launchpad-reviews to: on call: intellectronica || reviewing: - || queue: [] || This channel is logged: http://irclogs.ubuntu.com
intellectronicabigjools: would you like me to review first-ppa-name-bug-439305 ?16:39
bigjoolsintellectronica: ah yes please, forgot to ask about that!  I have a couple possible changes though, perhaps I can discuss them with you after you've looked at it16:40
intellectronicabigjools: sure16:41
=== andrea-bs_ is now known as andrea-bs
intellectronicabigjools: your branch looks fine to me. what changes did you want to make?16:49
bigjoolsfirst, I was considering filling the "name" field with "ppa" if it's the first PPA16:50
bigjoolsso it's a sensible default16:50
bigjoolssecond, I might change the interface description to make it more obvious that the name will be part of the repo URL16:50
bigjoolsand also possibly change the displayname description so the user knows it will be part of the GPG key descriptiojn16:51
intellectronicabigjools: yes, all three changes sound like very good ideas16:55
bigjoolsintellectronica: okay, thanks, do you want to see another diff with that in?16:56
intellectronicabigjools: ye16:58
intellectronicayes16:58
bigjoolscoming right up16:58
bigjoolsintellectronica: what's the right way of pre-filling a form field?16:59
intellectronicabigjools: in the view, default_values is a dict with an entry for every field you want to pre-fill17:00
bigjoolscool, ta17:00
bigjoolsintellectronica: hmm is it possible to conditionally change the field descriptions on the form?  part three above only applies to the first created PPA17:05
intellectronicabigjools: yes, but it's hackish. you need to create a new field, and then create a new fields object with the original field omitted and the new one inserted instead of it17:06
bigjoolsurg17:07
bigjoolsIIRC there is another way to add more text on the form?17:07
intellectronicabigjools: nothing i can think of17:08
noodles775intellectronica: I'm guessing you'll be finishing soon too, but if I'm wrong, there'll be an MP of mine arriving in a minute if you've time.17:08
intellectronicamaybe ask one of the resident zope mavens?17:08
intellectronicanoodles775: i can fit one more review17:09
noodles775intellectronica: thanks! Note - I won't be around, so feel free to re-prioritise :)17:09
=== noodles775 changed the topic of #launchpad-reviews to: on call: intellectronica || reviewing: - || queue: [noodles] || This channel is logged: http://irclogs.ubuntu.com
intellectronicanoodles775: np17:09
* bigjools looks for a maven17:10
bigjoolsI think they all have a holiday17:11
=== intellectronica changed the topic of #launchpad-reviews to: on call: intellectronica || reviewing: noodles || queue: [] || This channel is logged: http://irclogs.ubuntu.com
intellectronicabigjools: i think gary_poster is around17:21
bigjoolsintellectronica: default_values didn't work17:22
intellectronicamaybe it's called something different? let me find an example for you17:23
bigjoolsthanks17:23
intellectronicabigjools: sorry, i've misled you. it's actually called initial_values. see lib/lp/bugs/browser/bugtarget.py for example17:24
bigjoolsintellectronica: got it, thanks17:25
gary_posterbigjools: not sure what I'm a maven of, but I am around.  I am kind of trying to sneak lunch in though.  But if you ask me something or other I'll try to get back quickly17:25
bigjoolsgary_poster: real quick one!  is there a way to conditionally get some extra text on a form, or preferably change the value of a form field's description 17:26
=== EdwinGrubbs is now known as Edwin-lunch
intellectronicagary_poster: i suggested creating a new field and and a new fields collection with the new field replacing the old one, but we didn't know if there's an easier way to do it17:27
gary_posterbigjools, intellectronica: what intellectronica said sounds like the right basic idea.  it's possible we are already creating a one-off field collection for the request, in which case you can just change it in place, which would make it shorter, at least.17:31
gary_posterbut that would just be an optimization of the same basic idea17:31
bigjoolsgary_poster: is there a property on the field I can poke then?17:32
* bigjools boggles at the number of requests in .dev for a simple page17:34
bigjoolsintellectronica: is there a trick to getting the initial_values property called?  Mine isn't :/17:35
bigjoolsoh fuck17:35
bigjoolsI need to spell it right of course17:35
intellectronicanoodles775: r=me. it would be great to convert that sqlo query to storm, but that's beyond the scope of the branch. everything else looks great17:39
bigjoolsheh the BUDQ17:41
intellectronica?17:42
=== intellectronica changed the topic of #launchpad-reviews to: on call: intellectronica || reviewing: - || queue: [] || This channel is logged: http://irclogs.ubuntu.com
bigjoolsBig Ugly Dispatcher Query17:45
bigjoolsintellectronica: http://pastebin.ubuntu.com/291713/18:02
intellectronicabigjools: i suspect that the way you've written initial_values, the value will be overridden even if filled by the user before submissions (say if there's an error in another field). is that the behaviour you want?18:04
bigjoolsintellectronica: I don't understand18:04
intellectronicabigjools: if you submit the form and make an error, the form is displayed again with the values you've used before. if you always override initial_values, the previously entered value won't be retained (which is the default behvaiour), because you're looking at the value on the context, which hasn't changed18:06
bigjoolsah i see18:06
intellectronicabigjools: i suspect that's what wil happen. i'm not 100% sure, but i haven't tried18:06
bigjoolsI'll check it out and see what happens18:07
intellectronicacool18:07
intellectronicaeverything else looks fine. i take you've decided that manipulating the field's description dynamically is to much of a hassle?18:07
bigjoolsyes, the return on investment is small18:08
intellectronicai agree18:08
bigjoolsintellectronica: actually the value is retained, despite initial_values18:09
bigjoolsso it's all good!18:09
intellectronicabigjools: excellent. r=me then18:09
bigjoolsintellectronica: great, thanks for your advice and review18:09
intellectronicaand with that i shall end my review shift. i think i've been more trouble than help as a reviewer today :-/18:10
bigjoolshehe18:10
=== intellectronica changed the topic of #launchpad-reviews to: on call: - || reviewing: - || queue: [] || This channel is logged: http://irclogs.ubuntu.com
bigjoolsfud time here18:10
=== bigjools is now known as bigjools-afk
gary_posterbigjools-afk: if you can get to a widget then you are home free: set the .label or the .hint, depending on what you want.18:25
gary_posterif that doesn't do what you want, back to the drawing board.  You can do a custom widget easily-ish.18:26
=== EdwinGrubbs2 is now known as EdwinGrubbs
leonardrgary, can you review this tiny lazr.restful diff so i can make a new release for launchpad?21:46
leonardrhttps://pastebin.canonical.com/23226/21:46
gary_posteryes21:46
leonardri've also got a small launchpad branch coming up. (my ec2 test just passed)21:46
gary_posterleonardr: r=gary21:46
gary_postergreat21:46
leonardrcan i commit my changes to the download cache?21:47
gary_posterleonardr: yes21:47
leonardrall right21:47
leonardri love it when a plan comes together21:47
gary_poster:-)21:47
leonardrgary: fyi, here's what i'm adding21:48
leonardradded:21:48
leonardr  dist/grokcore.component-1.6.tar.gz21:48
leonardr  dist/lazr.restful-0.9.11.tar.gz21:48
leonardr  dist/martian-0.11.tar.gz21:48
leonardr  dist/wsgiref-0.1.2.zip21:48
gary_posterleonardr: cool21:48
leonardrgary: https://code.edge.launchpad.net/~leonardr/launchpad/help-me-gary/+merge/1324522:02
gary_posterheh22:04
leonardrthat's what it was called when i couldn't figure out what those tarballs were for22:04
gary_posterheh, I see22:04
gary_posterleonardr: r=gary22:07
leonardrall right22:08
* leonardr has not pqm-submitted a branch for months. does it still work the same way?22:08
gary_posterit can still work with bzr pqm-submit.  There are other new tricks, but that should be fine.22:08
leonardrall right22:08
leonardri'm off, i'll see you tomorrow22:09
gary_postersee you22:09
gary_posterthanks 22:09

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