[17:15] <cjp256> 23.3.3 made it to -proposed for 20.04 and 22.04, but not 18.04. related to https://github.com/canonical/cloud-init/pull/1742/files i assume?
[17:18] <blackboxsw> cjp256: correct, that httpretty commit is in upstream/main, but we have only pulled bugfixes for 22.3.3 into bionic-proposed
[17:18] <blackboxsw> so https://github.com/canonical/cloud-init/commit/9aa4ec6982541f5425c860010fa87134e58469e6 is not in the -proposed release yet correct
[17:19] <blackboxsw> it will be in 22.4
[17:19] <blackboxsw> which is in Nov 
[17:20] <meena> how do I split a line like this to fit into 80 char:
[17:20] <meena>             if toks[0].startswith("options=") or toks[0].startswith("ec_capabilities") or toks[0].startswith("ec_enabled"):
[17:20] <meena> I guess i could use regex :O
[17:21] <blackboxsw> that's one nice way. otherwise
[17:21] <blackboxsw> if any([
[17:21] <blackboxsw>   test1,
[17:21] <blackboxsw>   test2,
[17:21] <blackboxsw>   test3,
[17:21] <blackboxsw> ]):
[17:22] <meena> re.search(r"^(options|ec_capabilities|ec_enabled)=", toks[0])
[17:22] <blackboxsw> and was just staring on a regex :)
[17:23] <blackboxsw> ship it
[17:23] <cjp256> use if ( .. )
[17:23] <meena> regex is usually my first goto, but then i remember how awful that is to people who haven't done 22 years of Unix nonsense.
[17:24] <meena> blackboxsw: so this doesn't need an or, that's nice
[17:24]  * blackboxsw wonders timeit cost of the multi-conditional if vs regex w/  "ORs"  due to "|" 
[17:24] <cjp256> any([t1, t2, ...]) will evaluate all conditions first to build that array I think, so less effecient
[17:24] <blackboxsw> yeah +1 cjp256 good pt
[17:25] <meena> blackboxsw: regex done right can be really fast
[17:25] <meena> I see so much regex out there that just makes me wanna cry
[17:26] <meena> blackboxsw: how do you "timeit"?
[17:27] <blackboxsw> meena: https://docs.python.org/3/library/timeit.html
[17:27] <blackboxsw> create sample constructs or functions and shove them into it's own function or direct on commandline and see how it behaves vs alternatives across many iterations
[17:28] <blackboxsw> gives you a quick relative comparison when you are looking at two ways of writing something
[17:29] <meena> i wish i could feed it random data :D
[17:29] <meena> basically, like, quickcheck, but timed.
[17:38] <falcojr> meena: on that note, we're auto-formatting everything with black these days, so write it however you want and let black deal with it
[18:02] <meena> falcojr: I should just integrate black into my emacs then
[18:02] <falcojr> yes, I've integrated it into my editor...makes life a lot easier
[18:08] <meena> i just forgot you had to add () around a long if line to make it make sense
[18:08] <meena> but i reckon black would've handled that
[21:27] <cjp256> blackboxsw: i'm not seeing an updated -proposed deb for 18.04, just the old build from 09/01
[21:27] <blackboxsw> cjp256: good pt. I'm not seeing it either.
[21:28] <blackboxsw> thx cjp256 still stuck in unapproved queue, I think it was an oversight https://launchpad.net/ubuntu/bionic/+queue?queue_state=1&queue_text=cloud-init
[21:29] <cjp256> thanks