-
Feature Request
-
Resolution: Unresolved
-
Undefined
-
None
-
2.4, 2.5
-
False
-
-
False
What is the nature and description of the request?
Job template execution fails with error Missing a revision to run due to failed project update. if the project is marked as failed sync even if the project data is available locally.
Why does the customer need this? (List the business requirements here)
Their source control system undergoes maintenance that prevent access to the repositories for a limited time frame, any job that requires a project sync will then be halted until the maintenance ends, even if the project data is unaltered and available locally.
How would you like to achieve this? (List the functional requirements here)
It would be useful if the logic behind the check is updated to include some sort of integrity check, something on the lines of git diff --exit-code for instance, to ensure that the local status does not have pending changes or more checks to verify staged-but-not-committed changes.
Steps to Reproduce
- Prepare a dummy repository with a sample playbook
- Create a new project using the dummy repository
- Verify that normal sync operation work as expected and create a job template using the sample playbook prepared in the dummy repository
- Modify the project to target a non existent branch and disable the flag Update Revision on Launch
- The project will be marked as failed
- The data from the controller node is still available under the directory described in the project details
- Execute the job template prepared before
- Job template fails with Missing a revision to run due to failed project update.
Current workarounds
Deleting previously failed jobs reporting sync failure will allow the template to correctly run if project update revision is disabled before execution.
Customer reports an additional workaround:
awx-manage shell_plus >>> Project.objects.filter(id=<Project ID>).update(status='successful')