Skip to content

Improve readability of run_tasks in AgenticPhase#23919

Merged
luisorofino merged 2 commits into
loa/openmetrics-ai-genfrom
loa/run-tasks
Jun 12, 2026
Merged

Improve readability of run_tasks in AgenticPhase#23919
luisorofino merged 2 commits into
loa/openmetrics-ai-genfrom
loa/run-tasks

Conversation

@luisorofino

@luisorofino luisorofino commented Jun 3, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Divides run_tasks into different functions and helpers, whose purpose is explained by its name: run_task, task_has_goal, render_task_prompt, run_goal_validation ...

Motivation

The run_tasks function in AgenticPhase was hard to read and understand. There were different parts that could be divided into different isolated functions, enhancing logic encapsulation.

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Add qa/required if this PR needs QA validation, or qa/skip-qa if it does not. Exactly one of the two is required.
  • If you need to backport this PR to another branch, you can add the backport/<branch-name> label to the PR and it will automatically open a backport PR once this one is merged

@dd-octo-sts dd-octo-sts Bot added the ddev label Jun 3, 2026
@luisorofino luisorofino marked this pull request as ready for review June 3, 2026 07:59
@luisorofino luisorofino requested a review from a team as a code owner June 3, 2026 07:59
@datadog-prod-us1-4

datadog-prod-us1-4 Bot commented Jun 3, 2026

Copy link
Copy Markdown
Contributor

Tests  Code Coverage

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🎯 Code Coverage (details)
Patch Coverage: 100.00%
Overall Coverage: 88.07%

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 627eb4e | Docs | Datadog PR Page | Give us feedback!

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b714109abc

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread ddev/src/ddev/ai/phases/agentic_phase.py
@luisorofino luisorofino added the qa/skip-qa Automatically skip this PR for the next QA label Jun 3, 2026
@luisorofino luisorofino force-pushed the loa/orchestrator-isolation branch 2 times, most recently from 172b8e4 to d5aa805 Compare June 8, 2026 09:12
@luisorofino luisorofino force-pushed the loa/orchestrator-isolation branch from d5aa805 to fe384fb Compare June 8, 2026 09:36
@luisorofino luisorofino force-pushed the loa/run-tasks branch 2 times, most recently from f828379 to 41871ec Compare June 8, 2026 10:15
@luisorofino luisorofino force-pushed the loa/orchestrator-isolation branch from fe384fb to 42751bb Compare June 8, 2026 10:15
@luisorofino luisorofino force-pushed the loa/orchestrator-isolation branch from 42751bb to bc5a1ae Compare June 8, 2026 10:18
@luisorofino luisorofino force-pushed the loa/orchestrator-isolation branch 2 times, most recently from c054251 to 5626da9 Compare June 9, 2026 09:08
@luisorofino luisorofino force-pushed the loa/run-tasks branch 2 times, most recently from baf39f2 to aa9a892 Compare June 10, 2026 09:29
@luisorofino luisorofino force-pushed the loa/orchestrator-isolation branch 2 times, most recently from 1145cd4 to 8170d0d Compare June 11, 2026 07:58
@luisorofino luisorofino force-pushed the loa/orchestrator-isolation branch from 8170d0d to 895558f Compare June 12, 2026 08:59
Base automatically changed from loa/orchestrator-isolation to loa/openmetrics-ai-gen June 12, 2026 09:00
@dd-octo-sts

dd-octo-sts Bot commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Validation Report

All 21 validations passed.

Show details
Validation Description Status
agent-reqs Verify check versions match the Agent requirements file
ci Validate CI configuration and code coverage settings
codeowners Validate every integration has a CODEOWNERS entry
config Validate default configuration files against spec.yaml
dep Verify dependency pins are consistent and Agent-compatible
http Validate integrations use the HTTP wrapper correctly
imports Validate check imports do not use deprecated modules
integration-style Validate check code style conventions
jmx-metrics Validate JMX metrics definition files and config
labeler Validate PR labeler config matches integration directories
legacy-signature Validate no integration uses the legacy Agent check signature
license-headers Validate Python files have proper license headers
licenses Validate third-party license attribution list
metadata Validate metadata.csv metric definitions
models Validate configuration data models match spec.yaml
openmetrics Validate OpenMetrics integrations disable the metric limit
package Validate Python package metadata and naming
qa-label Validate the pull request declares whether it needs QA for the next Agent release
readmes Validate README files have required sections
saved-views Validate saved view JSON file structure and fields
version Validate version consistency between package and changelog

View full run

@luisorofino luisorofino merged commit ca16ce9 into loa/openmetrics-ai-gen Jun 12, 2026
338 checks passed
@luisorofino luisorofino deleted the loa/run-tasks branch June 12, 2026 13:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ddev qa/skip-qa Automatically skip this PR for the next QA team/agent-integrations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants