Skip to content
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

Skip create step when created == true #4038

Merged
merged 2 commits into from
Oct 17, 2023

Conversation

mluzarreta
Copy link
Contributor

@mluzarreta mluzarreta commented Sep 8, 2023

Fixes: #4037

@mluzarreta mluzarreta force-pushed the bugfix/ignore_created branch from badb753 to 45b3656 Compare September 8, 2023 14:56
@DrPsychick
Copy link

This introduced a breaking change to my use case, unfortunately : https://github.com/ansible/molecule/pull/3949/files

I use libvirt to create VMs to run tests on and since creating VMs is slow, I run converge while I develop the role (VM OS is different than my machine's OS, so I need to develop with molecule/libvirt essentially).
Since the change above, converge always runs create and tries to recreate the VMs I already have, although created: true is in the state file.

Please consider this PR to revert that change (and skip create when already created).

@yanghua-ola
Copy link

Same issue here. I have a molecule scenario executed with Podman. The base image doesn't not come with Python; therefore, I install it in prepare.yml. The first molecule converge worked as expected. However, during subsequent invocations, the create step would execute again but not prepare, resulting a brand-new container without Python. As a result, molecule failed. This defect was introduced by #3949 and affects version 6.x.

@zhan9san zhan9san added the bug label Sep 19, 2023
@zhan9san zhan9san temporarily deployed to ack September 19, 2023 07:05 — with GitHub Actions Inactive
@ssbarnea ssbarnea changed the title Skip create step when created == true - closes #4037 Skip create step when created == true Oct 16, 2023
@ssbarnea ssbarnea temporarily deployed to ack October 16, 2023 15:00 — with GitHub Actions Inactive
@ssbarnea ssbarnea merged commit d7b93b5 into ansible:main Oct 17, 2023
12 checks passed
@Adrixop95
Copy link

Hey, when can we expect a new version of molecule to be released on pipy with this fix?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

created: true is ignored in state.yml
6 participants