Tuesday, 2018-10-30

*** mriedem_away has quit IRC00:15
*** lei-zh has joined #openstack-placement02:06
*** lei-zh has quit IRC02:31
*** lei-zh has joined #openstack-placement02:32
*** takashin has left #openstack-placement03:03
*** tetsuro has joined #openstack-placement04:10
*** lei-zh has quit IRC04:10
*** tetsuro has quit IRC05:03
*** tetsuro has joined #openstack-placement05:03
*** tetsuro_ has joined #openstack-placement05:04
*** tetsuro has quit IRC05:08
*** lei-zh has joined #openstack-placement05:11
*** lei-zh has quit IRC05:18
*** tetsuro_ has quit IRC05:29
*** tetsuro has joined #openstack-placement05:34
*** tetsuro has quit IRC05:38
*** lei-zh has joined #openstack-placement05:42
*** tetsuro has joined #openstack-placement06:05
*** tetsuro has quit IRC06:09
*** tetsuro has joined #openstack-placement06:10
*** mnaser has quit IRC06:16
*** mnaser has joined #openstack-placement06:17
*** vdrok has quit IRC06:22
*** vdrok_ has joined #openstack-placement06:23
*** rubasov has quit IRC07:20
*** rubasov has joined #openstack-placement07:25
*** tetsuro has quit IRC07:50
*** helenafm has joined #openstack-placement08:19
*** e0ne has joined #openstack-placement08:41
*** tetsuro has joined #openstack-placement09:07
openstackgerritTakashi NATSUME proposed openstack/placement master: Add a link to "Add Generation to Consumers" spec  https://review.openstack.org/61415009:13
*** lei-zh has quit IRC09:33
*** tetsuro has quit IRC09:39
*** cdent has joined #openstack-placement09:42
cdentaw: how nice https://docs.openstack.org/placement/latest/09:47
*** tetsuro has joined #openstack-placement09:48
*** tetsuro has quit IRC09:51
*** ttsiouts has joined #openstack-placement10:22
*** e0ne has quit IRC10:32
openstackgerritwangqiang-bj proposed openstack/nova-specs master: fix wrong spelling of "unnecessary"  https://review.openstack.org/61417310:35
openstackgerritwangqiang-bj proposed openstack/nova-specs master: fix wrong spelling of "unnecessary"  https://review.openstack.org/61417310:37
*** cdent has quit IRC10:42
*** helenafm has quit IRC10:45
openstackgerritJohn Garbutt proposed openstack/nova-specs master: Add Unified Limits Spec  https://review.openstack.org/60220110:53
*** e0ne has joined #openstack-placement10:57
openstackgerritwanghui proposed openstack/placement master: Fix the error package name in comment  https://review.openstack.org/61418410:59
openstackgerritwanghui proposed openstack/nova-specs master: Fix a typo of 'keystoneauth1'  https://review.openstack.org/61418711:02
*** cdent has joined #openstack-placement11:13
openstackgerritwangqiang-bj proposed openstack/placement master: fix wrong spelling of "explicit"  https://review.openstack.org/61419211:16
jrolledleafe: around now, I see you found your answer, anything else I can help with?11:24
openstackgerritMerged openstack/placement master: Fix the error package name in comment  https://review.openstack.org/61418412:07
*** ttsiouts has quit IRC12:16
*** tssurya has joined #openstack-placement12:20
*** e0ne has quit IRC12:21
openstackgerritMerged openstack/placement master: fix wrong spelling of "explicit"  https://review.openstack.org/61419212:28
*** ttsiouts has joined #openstack-placement12:32
edleafejroll: just wondering how those version tests work in ironic. Wouldn't they always be skipped, since they're running as unit tests?12:36
jrolledleafe: we configure a database in CI, so they always run, and developers can do the same locally if they want.12:38
edleafejroll: ah, I see.12:38
cdentedleafe: did that --autogenerate stuff make any sense and is it of any use?12:47
cdentthe tests suggest I got it a bit wrong, but the concept is here12:48
edleafecdent: just getting started on my day. What --autogenerate stuff are you referring to?12:49
cdentedleafe: I left comments on https://review.openstack.org/#/c/614024/ about how the described way is not as powerful as it could be and then demo that in: https://review.openstack.org/#/c/614030/112:50
edleafecdent: ok, I'll take a look at it in a bit12:51
*** helenafm has joined #openstack-placement13:06
*** cdent has quit IRC13:07
*** e0ne has joined #openstack-placement13:08
*** mriedem has joined #openstack-placement13:13
*** cdent has joined #openstack-placement13:27
efriedcdent: At a glance, the toc depth on the index page could be reduced a tad. IMO we don't need the microversion history expanded.13:30
cdentefried: yeah, agree13:31
*** ttsiouts has quit IRC13:40
*** ttsiouts has joined #openstack-placement13:42
edleafecdent: ok, read your comments. I guess I'm not sure what --autogenerate has to do with it13:52
cdentone reason for using alembic at all is so you don't have to write migrations, alembic figures them out for you13:53
cdentyou use alembic to create them13:53
cdentas described in the commit message of the demo13:53
edleafeWell, it's sort of a cart/horse situation13:53
edleafeYou have to make the changes *somewhere*. If you do it in sqla, alembic *might* be able to autogenerate the migration13:54
cdentif you do it in any other way then in the models, then the migration is too complicated and we should reject it out of hand because migrations that can't be identfiied by alembic are clearly too complicated and not something we want13:55
edleafeAfter playing around with it a bit, and reading all the disclaimers, I don't find autogenerate to be that reliable13:55
* cdent says tautologically13:55
edleafeNot true - a rename isn't seen by alembic13:55
cdentI'm not suggesting that we use it as a general rule, but rather than it is an available too we might want to document13:55
cdentof a table or a column?13:55
cdentwhy would we ever do a rename?13:56
cdentmind you, I come from that strange alien planet that says that migrations should almost never happen13:56
edleafehttps://alembic.zzzcomputing.com/en/latest/autogenerate.html#what-does-autogenerate-detect-and-what-does-it-not-detect13:56
cdentyeah, the list of things it can't detect are things that shouldn't be done :)13:56
edleafeI used autogenerate to create the initial migration, and you saw that it still needed tweaking13:57
cdentright, but it gave you a starting point13:57
cdentthat's sort of the point13:57
cdentit's a tool13:57
cdenttools are nice13:57
edleafeAnd we shouldn't be doing migrations that are so complex that the tool saves you anything13:57
cdentexcept you can save a step: you have to make the changes in the models anyway13:58
cdentalembic can detect anything sane in those13:58
edleafeIn the case of creating an entire database, sure. In the case of adding an index or a column - nope13:58
cdent"Column additions, removals." yes "Basic changes in indexes and explcitly-named unique constraints" yes13:58
cdentLike I said: we don't have to indicate any of this _yet_, but it would be useful for two things to be true:13:59
edleafeLook, the end result is a revision file, no? How it is created is up to the person making that change.13:59
cdenta) the online migration part of env.py works so that people in the know can use the alembic commands to their fullest14:00
cdentb) we eventually document that availability14:00
cdentit sounds like we are in agreement, so I'm not sure why "Look," is necessary here14:00
cdentin your changes a) was not true, last I checked14:01
edleafeBecause I don't feel confident enough in autogenerate to encourage its use14:01
cdentwhich is why I wrote the demo code, to help you gain some confidence14:01
edleafedidn't work :)14:02
cdentI don't care if you document autogenerate14:02
cdentbut I do care that you fix a)14:02
edleafeSure, I definitely want to fix a). But it goes back to my original statement: I don't see what --autogenerate has to do with it14:03
openstackgerritChris Dent proposed openstack/placement master: Add a placement-manage CLI  https://review.openstack.org/60016114:04
cdentyou can't run --autogenerate without a working14:04
cdentso one way to test that env.py is correct, while experimenting, is to use revision --autogenerate from the command line14:04
cdentas demostrated in my DNM14:04
cdentif you do 'alembic revision' without autogenerate it doesn't tickly the a)-ness14:05
cdentdoes that make more sense?14:06
edleafeNo, still sounds the same to me as creating the revision manually. Especially with the "verify and tweak the resulting file"14:08
edleafeSaves a little typing, for sure14:08
cdentokay:14:08
cdentthat's not my point14:08
cdentlet me try to explain in a different way:14:08
cdentwhen you run 'alembic revision' with no args it doesn't need to consult the database, therefore the code in env.py in the method 'run_migrations_online' is not run14:09
cdentwhen you run 'alembic revision --autogenerate' it does need access to an existing database14:09
cdenttherefore 'run_migrations_online' is called and as the code is currently written it fails14:10
cdentthus:14:10
cdentthe command 'alembic revision --autogenerate' is a tool for doing you to do TDD to make that code more correct while trying to resolve a)14:10
cdents/doing/allowing/14:10
cdentor to put it another way:14:11
cdentI figure out that env.py was incomplete because I tried to use 'alembic revision --autogenerate'14:11
cdentwe want env.py to be right14:11
cdentthe goal is env.py to be right14:11
cdentEOF14:12
edleafeYay! Something I can agree with!!14:12
edleafe:)14:12
edleafeI get that autogenerate is helpful in figuring out how to correct env.py.14:13
cdentI'm not sure if I should be relieved yet or not14:13
edleafeI just don't see it being tremendously useful afterwards14:13
cdentthat's fine. we'll let the future decide that for us.14:14
cdentbiab14:20
*** cdent has quit IRC14:21
*** e0ne has quit IRC14:33
*** e0ne has joined #openstack-placement14:37
openstackgerritJack Ding proposed openstack/nova-specs master: High Precision Event Timer (HPET) on x86 guests  https://review.openstack.org/60798914:42
*** cdent has joined #openstack-placement15:08
openstackgerritTheodoros Tsioutsias proposed openstack/nova-specs master: Enable rebuild for instances in cell0  https://review.openstack.org/55421815:19
*** e0ne has quit IRC15:25
*** e0ne has joined #openstack-placement15:35
openstackgerritMerged openstack/placement master: Add a link to "Add Generation to Consumers" spec  https://review.openstack.org/61415016:29
*** e0ne has quit IRC16:30
sean-k-mooneycdent: im going to have to respin the nova change again because we have flak8 set for a 79 charater limit instead of 80..16:31
sean-k-mooneysorry of the noise16:31
cdentsean-k-mooney: no problem16:31
sean-k-mooneyam i have almost finished the placment port too.16:31
sean-k-mooneyhowever i notice a circualr depenancy if i add the decorator in util.py16:32
sean-k-mooneyhttp://paste.openstack.org/show/733655/16:32
sean-k-mooneyi can move the definition before the import and leave a comment  but is there somewhere else i should add it instead16:33
cdentsean-k-mooney: the right fix for that is to remove the db using methods somewhere else16:33
cdentI'll do that now, and you can base your changes on that16:34
sean-k-mooneyok ill push up what i have and then ill rebase on your change to keep a copy of it16:34
sean-k-mooneyi noticed you comment regarding cyclical imports so was not sure if you planned to fix it or were we just living with it16:35
cdentthere are some which are sort okay, but the db one I don't like16:37
sean-k-mooneycdent: ya i was honestly surprised to see the placment.object and placement.microversion imports. generall util files are imported everhwere and rarely import thing form the current project to avoid this16:43
cdentsean-k-mooney: much of that was the result of haste16:43
sean-k-mooneycdent: with the split out. ya its not a big deal its more of a code smell16:44
sean-k-mooneyit works but it has maitaince issues like this16:44
cdentyes16:44
cdentthe haste I'm talking about is not the haste of extraction, the haste of the original creation of placement16:44
edleafecdent: I just tried playing with autogenerate again, this time with the changes you made to env.py. When I run the revision command with autogenerate, I get "ImportError: No module named placement"16:45
cdentedleafe: you need to run the alembic command from within the virtenv .tox/py??/bin/alembic16:45
cdentif you already did that, then not sure16:45
edleafeoh yeah - I was just doing from the straight python env16:46
edleafeI'm adding an autogen section to the doc, and wanted to test it out first16:46
edleafeBecause I wanted to make you say 'huzzah!'16:47
cdentI'll save it up and use two !16:47
openstackgerritsean mooney proposed openstack/placement master: Harden placement init under wsgi  https://review.openstack.org/61244416:50
sean-k-mooneyille rebase ^ when the cycle is broken of you can if you like. it should just work form the gerrit ui hopefully16:51
*** helenafm has quit IRC17:05
openstackgerritChris Dent proposed openstack/placement master: Move ensure_consumer to a new placement.db.util  https://review.openstack.org/61430717:06
cdentsean-k-mooney: ^ that might do the trick17:07
sean-k-mooneycool im just going to grab something to eat. ill pull it down and rebase locally when i get backin an hour or os17:09
*** tssurya has quit IRC17:19
*** ttsiouts has quit IRC17:28
*** ttsiouts has joined #openstack-placement17:29
*** ttsiouts has quit IRC17:33
*** e0ne has joined #openstack-placement18:10
*** e0ne has quit IRC18:25
openstackgerritsean mooney proposed openstack/placement master: Harden placement init under wsgi  https://review.openstack.org/61244418:37
sean-k-mooneycdent: edleafe have either of ye had issues running placement.tests.functional.db.test_resource_provider.ResourceClassTestCase.test_create_duplicate_id_retry_failing18:39
sean-k-mooneyeven on master that functional test is failing for me locally18:40
cdentsean-k-mooney: i haven't seen that. what kind of error is it giving you?18:40
sean-k-mooneyi have two failing functional tests the relevent bits are here http://paste.openstack.org/show/733661/18:41
* cdent tries18:42
sean-k-mooneyactully you might need the full output http://paste.openstack.org/show/733662/18:42
cdentI haven't run the functional tests locally with 2.7 in a while18:42
sean-k-mooneyoh i can try them with 3.6 too18:42
sean-k-mooneythese are passing upstream so im assuming its a centos thing or somthing is not mocked correctly18:42
edleafeI'm running them locally on 2.7 and they are passing18:43
sean-k-mooneyya its weird im assuming its something to do with my env but not sure what18:44
sean-k-mooneyill try recloning placement once teh 3.6 version finishes18:44
cdentsean-k-mooney: are your tox env's recently -r ?18:44
sean-k-mooneywell the py36 functional test where a first run and yes 5 minutes ago to try and fix the issue :)18:45
cdentI assumed as much, but figured better check everything18:46
sean-k-mooneyjust did a fresh clone and running tox again18:46
cdentwhat version of sqlite have you got?18:47
sean-k-mooneygood question i assume thats a bindep so its not using one installed in the tox env?18:48
sean-k-mooneyill check18:48
sean-k-mooney[stack@devstack2 placement-test]$ sqlite3 --version18:48
sean-k-mooney3.7.17 2013-05-20 00:56:22 118a3b35693b134d56ebd780123b7fd6f149766818:48
sean-k-mooney2013 damb centos packages are old18:48
cdentI've got 3.2218:49
sean-k-mooneyso ya same behavior with a clean clone. i can try and install a newer sqlite3 package if you think that will help18:49
cdentcould be that18:49
cdentit's the only thing I can think of18:50
sean-k-mooneyill grab the latest for upstream one sec18:50
cdentbut not sure why it would be a problem18:50
*** e0ne has joined #openstack-placement19:13
*** cdent has quit IRC19:56
openstackgerritEd Leafe proposed openstack/placement master: Added alembic environment  https://review.openstack.org/61144120:51
openstackgerritEd Leafe proposed openstack/placement master: Delete the old migrations  https://review.openstack.org/61144020:51
openstackgerritEd Leafe proposed openstack/placement master: Add a document for creating DB revisions  https://review.openstack.org/61402420:51
openstackgerritEd Leafe proposed openstack/placement master: WIP - Show an alembic migration  https://review.openstack.org/61402520:51
openstackgerritEd Leafe proposed openstack/placement master: Rename the database files  https://review.openstack.org/61435020:51
*** tssurya has joined #openstack-placement20:58
*** e0ne has quit IRC21:18
*** mriedem has quit IRC21:30
openstackgerritChris Dent proposed openstack/placement master: Add a placement-manage CLI  https://review.openstack.org/60016121:32
*** ttsiouts has joined #openstack-placement21:55
*** ttsiouts has quit IRC22:04
*** ttsiouts has joined #openstack-placement22:05
*** ttsiouts has quit IRC22:10
*** e0ne has joined #openstack-placement22:49
*** tssurya has quit IRC22:51
*** e0ne has quit IRC23:13

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