Friday, 2019-03-15

*** tetsuro has joined #openstack-placement00:17
*** takashin has left #openstack-placement03:01
*** tetsuro has quit IRC06:08
*** e0ne has joined #openstack-placement06:24
*** e0ne has quit IRC06:27
openstackgerritMerged openstack/placement master: Move Inventory and InventoryList to own file  https://review.openstack.org/64211107:48
openstackgerritMerged openstack/placement master: Remove InventoryList class  https://review.openstack.org/64211207:48
*** tssurya has joined #openstack-placement08:15
*** mcgiggler has joined #openstack-placement08:24
*** e0ne has joined #openstack-placement08:35
openstackgerritMerged openstack/placement master: Remove ResourceProviderList class  https://review.openstack.org/64213810:02
openstackgerritMerged openstack/placement master: Move set_traits tests back to test_resource_provider  https://review.openstack.org/64331310:02
*** ttsiouts has joined #openstack-placement10:07
*** ttsiouts has quit IRC10:22
*** ttsiouts has joined #openstack-placement10:23
*** ttsiouts_ has joined #openstack-placement10:23
*** ttsiouts has quit IRC10:27
*** cdent has joined #openstack-placement10:38
*** mriedem has joined #openstack-placement10:53
*** e0ne has quit IRC11:03
openstackgerritChris Dent proposed openstack/placement master: Move TestAllocation into test_allocation  https://review.openstack.org/64152411:15
*** cdent has quit IRC11:31
*** cdent has joined #openstack-placement11:41
openstackgerritStephen Finucane proposed openstack/placement master: Group API versions by release  https://review.openstack.org/64142211:49
efriedstephenfin: early on todays todo list was to update the predecessor for ^ since the docstheme gizmo is in a release now.11:51
efriedima do that now...11:51
openstackgerritEric Fried proposed openstack/placement master: Use ``code`` role in api-ref titles  https://review.openstack.org/64140412:01
efriedstephenfin: ^ may want to rebase your'n12:01
efriedah bugger, needs another rebase for merge conflictness.12:02
openstackgerritEric Fried proposed openstack/placement master: Use ``code`` role in api-ref titles  https://review.openstack.org/64140412:04
efriedstephenfin: ^12:05
openstackgerritStephen Finucane proposed openstack/placement master: Group API versions by release  https://review.openstack.org/64142212:05
*** e0ne has joined #openstack-placement12:12
cdentstephenfin: since you're a bit in the placement zone, these two tidy ups are worth having: https://review.openstack.org/#/c/641524/ https://review.openstack.org/#/c/640555/12:40
*** ttsiouts_ has quit IRC12:41
*** ttsiouts has joined #openstack-placement12:42
*** ttsiouts has quit IRC12:46
*** ttsiouts has joined #openstack-placement13:04
openstackgerritEric Fried proposed openstack/placement master: Use ``code`` role in api-ref titles  https://review.openstack.org/64140413:29
*** sean-k-mooney has joined #openstack-placement13:30
openstackgerritEric Fried proposed openstack/placement master: Group API versions by release  https://review.openstack.org/64142213:32
efriedthat was a weird rebase ^13:36
efriedI had to pull it down and do it manually, but gerrit showed it as a trivial one, and kept not only the +2s but the +W.13:36
stephenfincdent: Both done13:40
cdentthanks13:40
openstackgerritMerged openstack/placement master: Remove NAME in placement/deploy.py  https://review.openstack.org/64273913:42
openstackgerritMerged openstack/placement master: Extract user and endpoint creation install doc  https://review.openstack.org/64336313:42
*** e0ne has quit IRC13:58
*** efried is now known as fried_rice14:00
*** e0ne has joined #openstack-placement14:06
openstackgerritMerged openstack/placement master: Docs: extract testing info to own sub-page  https://review.openstack.org/63962814:15
openstackgerritChris Dent proposed openstack/placement master: WIP: Optionally run a wsgi profiler when asked  https://review.openstack.org/64326914:16
*** stephenfin is now known as finucannot14:19
*** sean-k-mooney has quit IRC14:20
*** ttsiouts has quit IRC14:21
*** ttsiouts has joined #openstack-placement14:22
fried_ricecdent: given any thought to plumbing openstacksdk with placement thingies?14:22
cdentnot in any significant way, mostly because in my own brain I don't like SDKs, I'd rather just use requests and hork with json blobs14:23
cdentbut I know plenty of people feel otherwise, so would be in support of people making it go14:23
fried_ricecdent: for the effort under discussion in -nova, the first stage would be simply swapping out ksa-adapter.get with connection.adapter.get (or something along those lines) so not critical to make that happen.14:25
*** ttsiouts has quit IRC14:25
*** ttsiouts has joined #openstack-placement14:25
fried_ricebut future, connection.placement.allocation_candidates(...) kind of thing etc.14:25
* cdent nods14:25
cdentdoes the connection.adapter.get step get us anything, or is it mostly a move in the right direction? As in, why not just carrying on using ksa?14:26
fried_riceYeah, the direction being "use sdk instead of [python-*client, ksa, other]"14:30
fried_riceit's a low-surface-area way to prove the sdk plumbing works.14:30
fried_ricein terms of how the connection loads itself up from conf etc.14:30
cdentcool, yeah, seems good to me.14:33
openstackgerritChris Dent proposed openstack/placement master: Note removal of OVO in contrib docs  https://review.openstack.org/64254514:36
cdentif someone would care to re-approve that ^ It required a manual rebase14:38
cdentfried_rice: i'm confused14:44
cdentyou're asking me to touch a file that that patch never touched14:45
cdentoh wait I got ya14:47
* cdent too many things at once14:47
fried_ricecdent: That's correct. The patch originally made <edit1>, <edit2>. <edit2> originally lived in...14:47
fried_riceyeah14:47
*** sean-k-mooney has joined #openstack-placement14:49
openstackgerritChris Dent proposed openstack/placement master: Note removal of OVO in contrib docs  https://review.openstack.org/64254514:49
cdentbetter?14:49
fried_rice+2, qualified.14:51
cdentI bring this pain upon myself14:52
cdentbut for the greater good or something14:52
cdentbbl14:58
*** cdent has quit IRC14:58
*** ttsiouts has quit IRC15:14
openstackgerritMerged openstack/placement master: Add explicit short-circuit in get_all_by_consumer_id  https://review.openstack.org/64055515:18
mriedemfried_rice: edleafe: question on https://review.openstack.org/64254515:33
*** e0ne has quit IRC15:51
*** cdent has joined #openstack-placement15:54
*** ttsiouts has joined #openstack-placement15:55
*** cdent has quit IRC16:24
*** belmoreira has quit IRC16:45
*** mcgiggler has quit IRC17:01
*** e0ne has joined #openstack-placement17:10
*** e0ne has quit IRC17:11
*** ttsiouts has quit IRC17:23
*** ttsiouts has joined #openstack-placement17:24
*** tssurya has quit IRC17:24
*** ttsiouts has quit IRC17:28
openstackgerritMerged openstack/placement master: Move TestAllocation into test_allocation  https://review.openstack.org/64152417:47
*** e0ne has joined #openstack-placement18:53
finucannotfried_rice: Considered running the entirety of placement through black?19:26
finucannot(In relation to https://review.openstack.org/641723)19:26
finucannot(https://pypi.org/project/black/)19:27
fried_ricefinucannot: you mean in reference to https://review.openstack.org/#/c/641497/ ?19:28
finucannotwhoops, yeah19:28
fried_ricefinucannot: In all seriousness, for pypowervm we used pep8 *and* sonar, and adding the latter was jeeeest a little bit too much.19:28
fried_ricethere were good bits, but overall it was more pain than benefit.19:28
fried_riceso no, I have no intention of getting super militant. But I don't think it's unreasonable to do pretty much all of pep8. Especially since we're already there, and any divergence would be regression.19:29
finucannotAgreed. Adding tools like that to an existing project is rarely, if ever, work the effort19:30
*** e0ne has quit IRC19:37
*** openstack has joined #openstack-placement19:45
*** ChanServ sets mode: +o openstack19:45
openstackgerritMerged openstack/placement master: Note removal of OVO in contrib docs  https://review.openstack.org/64254520:54
openstackgerritMerged openstack/placement master: Remove unused table constants from allocation_candiate.py  https://review.openstack.org/64331420:54
openstackgerritEric Fried proposed openstack/placement master: Get rid of backslash continuations in code  https://review.openstack.org/64149722:04
fried_riceedleafe: Before I go crazy, like this ^22:04
fried_rice(by "go crazy" I mean "go through the effort of doing it all like that")22:04
fried_riceedleafe: specifically https://review.openstack.org/#/c/641497/1..2/placement/objects/resource_provider.py22:05
openstackgerritEric Fried proposed openstack/placement master: Get rid of backslash continuations in code  https://review.openstack.org/64149722:13
fried_riceedleafe: wasn't that hard, went ahead and did 'em all ^22:13
edleafefried_rice: much, much better!22:23
fried_ricewoot22:23
edleafemore readable, no?22:23
fried_riceYes. Things in me grate at the extra assignments, but it is the least of the evils, so \o/22:23
fried_riceit's also slightly surprising to me, until I examine and really think about it, that it didn't remove any magic doing it this way.22:24
edleafeMaybe add a comment so that some future person who has similar gratings doesn't undo that22:24
fried_ricemmph, everywhere?22:25
edleafewhat do you mean by magic?22:25
edleafeAt least once, not everywhere22:25
fried_riceWell, sqla is magic to me in general. Like the fact that comparator type things as method args get translated into sql query terms and shit.22:25
fried_riceso I thought  that a().b().c() might actually do something more magical than x = a(); x = x.b(); x = x.c()22:26
edleafeyeah, I know what you mean. I personally hate any ORM, and sqla is no exception22:26
edleafenah, that22:26
edleafethat's basic python22:26
fried_riceright, but like I said, I had to really look at and think about it to convince myself there *couldn't* be sqla magic happening.22:27
fried_riceedleafe: oh, while I have you here22:28
fried_riceI was about to start splitting up resource_provider.py22:28
edleafeat 5:30 on a friday?22:29
fried_riceI still want consumers to be able to say22:29
fried_ricefrom placement.objects import resource_provider as rp_obj22:29
fried_ricebut I want to create sub-things like22:29
fried_ricefrom placement.objects.resource_provider import trait22:29
fried_rice... aggregate22:29
fried_rice... inventory22:29
fried_ricewhich are by name and function "trait stuff you do on a resource provider" etc.22:30
edleafeare those classes or functions?22:30
fried_ricemodules22:30
fried_ricewhich would contain methods relating to "trait stuff you do on a resource provider" etc.22:31
fried_ricethe obvious way is to make a dir called placement/objects/resource_provider/ and move the base resource provider stuff (like ResourceProvider and its listy methods) into __init__.py in that dir. Then the other modules could be trait.py, aggregate.py, inventory.py within that dir.22:31
fried_riceBut some people don't like code in __init__.py22:31
edleafethen why wouldn't they be in placement.objects.trait etc?22:31
fried_ricebecause placement.objects.trait contains things that are about the Trait object22:31
edleafeOh geez, that's hella confusing22:31
fried_riceplacement.objects.resource_provider.trait is stuff you do on resource providers that relates to traits.22:31
edleafeIt's much clearer to have rp_obj.do_trait_thing()22:32
fried_riceokay; resource_provider.py is 2KLOC - do you think that's small enough, or do you have another suggestion for splitting it, or...?22:32
edleafeThe name should indicate that it's trait/inventory/agg related22:32
fried_riceI guess I could make rp_trait.py, rp_inventory.py, ...22:33
edleafeI don't have a problem with 2KLOC, as long as those lines all pertain to resource providers22:33
edleafeIf I'm looking for a method that deals with RPs, I expect to find it in resource_provider.py22:34
fried_riceunless it deals with traits22:34
fried_ricethen you might look for it in traits.py22:34
edleafeIf it's acting on/modifying a trait, then I'd look in traits.py22:35
edleafeIf it's acting on/modifying a RP, I wouldn't22:35
fried_ricemhm, because you're familiar with the structure22:35
edleafenot necesarily22:36
fried_riceI'm saying, if I'm looking for something that deals with a resource provider's inventories, and I saw a module called placement.objects.resource_provider.inventories, that's where I'd prolly go look.22:36
edleafebut if I saw placement.objects.resource_provider.py and placement.objects.inventories, I would look at the former first, since the thing I'm changing is an RP22:38
fried_riceunless you assumed that the raison d'ĂȘtre of inventories was to deal with things related to inventories22:38
fried_riceeither way, you'd find it in a couple hops, so it's probably not the end of the world.22:39
fried_riceanyway, if there's not an obvious desire to split it up, or not substantial enough to be worth whatever semantic confusion it might or might not entail, I can let it drop. It was just something cdent and I were talking about getting done to further the making of smaller files.22:39
edleafefried_rice: I'm about to call it a day. Let's discuss this at the meeting on monday22:39
fried_riceI talked him out of doing a major refactor of resource_provider.py (putting things in alpha order etc) because I was going to do this.22:39
fried_riceI think I'm still not in favor of the alpha reordering, because the current order has things divided logically along lines of inv/traits/aggs22:40
fried_ricergr, I'll add an #open22:40
fried_riceo/ edleafe22:40
edleafekewl. have a great weekend22:40
*** mriedem has quit IRC23:13

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