-
Notifications
You must be signed in to change notification settings - Fork 117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Undeterministic propagation of --dry option in tmt run #1977
Comments
Do you think it is possible that these three lines Line 2660 in 47b9250
A PDB tells me that these steps and
|
That might be it! |
The problem is that all classes inheriting from # Plan class uses Common._options
$ tmt run --all --remove provision --how virtual --dry
# Plan class receiver default context from click subcontext *
$ tmt run --all --remove provision --how virtual --dry plan Plan context override Line 309 in 47b9250
I have tried to fix this using a metaclass that creates a copy of @happz How would you solve this issue? Is it possible to get default context from click even if |
I don't have any proposal, as of now, but I've been poking this particular set of attributes for some time. To support multiple phases on the command line ( Your metaclass might also work, although I did not try this option yet. I'm afraid it would work only for cases where classes based on |
The current problem caused by the issues has a workaround here 47b9250. The question is, whether we will live with the workaround and be aware of such behavior until you refactor these options, or the metaclass from #1983 and possibly revert the workaround. I am OK with both. @psss: What do you think? |
I am trying to fix this issue with a simple fix #2050, which focuses only on the As @happz plans to change the |
+1 from me. |
Recently I found an interesting behavior of the
--dry
option if it is used only for the provision step. It also sets thedry
option ofPlan
objects.Plan.opt('dry') == True
when$ tmt run --all --remove provision --how virtual --dry
Plan.opt('dry') == None
when$ tmt run --all --remove provision --how virtual --dry plan
This causes a bug in the imported plan feature, which is fixed by a workaround 47b9250.
Do you have any idea why it happens? Is it intentional for some reason? Or well a hidden bug?
The text was updated successfully, but these errors were encountered: