mirror of
https://github.com/ansible/awx.git
synced 2026-10-31 06:26:15 -02:30
[AAP-86051] Pin DAB for CI and fix ruff format in task_manager
Install django-ansible-base from the AAP-86051 companion commit so bulk_validation_audit exists in the awx_devel image used by all CI jobs. Signed-off-by: Vidya Nambiar <vnambiar@redhat.com> Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -667,9 +667,7 @@ class TaskManager(TaskBase):
|
|||||||
)
|
)
|
||||||
if not found_acceptable_queue:
|
if not found_acceptable_queue:
|
||||||
self.task_needs_capacity(task, tasks_to_update_job_explanation)
|
self.task_needs_capacity(task, tasks_to_update_job_explanation)
|
||||||
audit_bulk_model_instances(
|
audit_bulk_model_instances(tasks_to_update_job_explanation, operation='bulk_update', update_fields=['job_explanation'])
|
||||||
tasks_to_update_job_explanation, operation='bulk_update', update_fields=['job_explanation']
|
|
||||||
)
|
|
||||||
UnifiedJob.objects.bulk_update(tasks_to_update_job_explanation, ['job_explanation'])
|
UnifiedJob.objects.bulk_update(tasks_to_update_job_explanation, ['job_explanation'])
|
||||||
|
|
||||||
def task_needs_capacity(self, task, tasks_to_update_job_explanation):
|
def task_needs_capacity(self, task, tasks_to_update_job_explanation):
|
||||||
|
|||||||
@@ -120,7 +120,7 @@ def test_task_manager_audits_before_job_explanation_bulk_update():
|
|||||||
"""Regression: scheduler must not bulk_update job_explanation without audit."""
|
"""Regression: scheduler must not bulk_update job_explanation without audit."""
|
||||||
task_manager_py = Path(__file__).resolve().parents[3] / 'scheduler' / 'task_manager.py'
|
task_manager_py = Path(__file__).resolve().parents[3] / 'scheduler' / 'task_manager.py'
|
||||||
source = task_manager_py.read_text()
|
source = task_manager_py.read_text()
|
||||||
audit_marker = "audit_bulk_model_instances(\n tasks_to_update_job_explanation, operation='bulk_update', update_fields=['job_explanation']"
|
audit_marker = "audit_bulk_model_instances(tasks_to_update_job_explanation, operation='bulk_update', update_fields=['job_explanation'])"
|
||||||
bulk_marker = "UnifiedJob.objects.bulk_update(tasks_to_update_job_explanation, ['job_explanation'])"
|
bulk_marker = "UnifiedJob.objects.bulk_update(tasks_to_update_job_explanation, ['job_explanation'])"
|
||||||
assert audit_marker in source
|
assert audit_marker in source
|
||||||
assert bulk_marker in source
|
assert bulk_marker in source
|
||||||
|
|||||||
@@ -20,5 +20,6 @@
|
|||||||
certifi @ git+https://github.com/ansible/system-certifi.git@devel
|
certifi @ git+https://github.com/ansible/system-certifi.git@devel
|
||||||
ansible-runner @ git+https://github.com/ansible/ansible-runner.git@devel
|
ansible-runner @ git+https://github.com/ansible/ansible-runner.git@devel
|
||||||
awx-plugins-core[credentials-github-app] @ git+https://github.com/ansible/awx-plugins.git@devel
|
awx-plugins-core[credentials-github-app] @ git+https://github.com/ansible/awx-plugins.git@devel
|
||||||
django-ansible-base[feature-flags,jwt-consumer,rbac,resource-registry,rest-filters] @ git+https://github.com/ansible/django-ansible-base@devel
|
# AAP-86051: bulk_validation_audit + validation bypass observability (django-ansible-base#1147); revert to @devel after merge
|
||||||
|
django-ansible-base[feature-flags,jwt-consumer,rbac,resource-registry,rest-filters] @ git+https://github.com/vidyanambiar/django-ansible-base@d9f99d6bf0286d444aa67a00f6b06339e166bdce
|
||||||
awx-plugins-interfaces @ git+https://github.com/ansible/awx_plugins.interfaces.git
|
awx-plugins-interfaces @ git+https://github.com/ansible/awx_plugins.interfaces.git
|
||||||
|
|||||||
Reference in New Issue
Block a user