Skip to content

test(ffe): validate Python agentless EVP fallback - #7592

Draft
leoromanovsky wants to merge 4 commits into
mainfrom
leo.romanovsky/ffe-agentless-evp-fallback-python-tests
Draft

test(ffe): validate Python agentless EVP fallback#7592
leoromanovsky wants to merge 4 commits into
mainfrom
leo.romanovsky/ffe-agentless-evp-fallback-python-tests

Conversation

@leoromanovsky

@leoromanovsky leoromanovsky commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

Motivation

Python needs system-test coverage proving that agentless exposure and flag-evaluation EVP payloads reach the configured direct or serverless intake route.

Linear: FFL-1489

Changes

  • Activate the Python agentless direct and serverless scenarios at v4.15.0-dev.
  • Validate exposure and /api/v2/flagevaluation payloads from the same evaluation sequence.
  • Assert destination host, response status, API-key authentication, evaluation counts, and absence from the excluded intake route.
  • Mount the test CA bundle for direct HTTPS intake capture.

Decisions

  • The direct and serverless adapters inherit one shared egress contract.
  • The existing Agent-backed exposure scenario keeps its current scope.
  • Manifest activation stays future-facing until the SDK version containing the fallback is available.

Validation

  • ./format.sh: passed, including mypy, Ruff, YAML validation, shellcheck, and Node linters.
  • TEST_LIBRARY=python ./run.sh FEATURE_FLAGGING_AND_EXPERIMENTATION_AGENTLESS_DIRECT -F tests/ffe/test_exposure_egress.py::Test_FFE_Exposure_Egress_Agentless_Direct: 1 passed, 3018 deselected against a freshly built Python 3.11 branch artifact.

@github-actions

github-actions Bot commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

CODEOWNERS have been resolved as:

manifests/python.yml                                                    @DataDog/system-tests-reviewers
tests/ffe/test_exposure_egress.py                                       @DataDog/feature-flagging-and-experimentation-sdk @DataDog/system-tests-core
utils/_context/_scenarios/__init__.py                                   @DataDog/system-tests-core
utils/_context/_scenarios/agentless_endtoend.py                         @DataDog/system-tests-core

@datadog-datadog-prod-us1

datadog-datadog-prod-us1 Bot commented Aug 26, 2026

Copy link
Copy Markdown

Pipelines  Tests

Unblock PR with BitsAI

⚠️ Warnings

Your PR has failed checks. Please review the issues below and take necessary action before merging.

🚦 9 Pipeline jobs failed

Testing the test | System Tests (python, dev) / End-to-end #1 / django-py3.13 1 — ❌ 1 test failed · 🔧 Needs a code fix, caused by this PR

View more details · View in GitHub Actions

1 failed test due to timeout waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user' at tests/ffe/utils/exposures.py:66

Showing tests most relevant to this failure.

❌ tests.ffe.test_exposure_egress.Test_FFE_Exposure_Egress_Agentless_Direct.test_exposure_egress[django-py3.13] from system_tests_suite
AssertionError: Timed out waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user'

self = <tests.ffe.test_exposure_egress.Test_FFE_Exposure_Egress_Agentless_Direct object at 0x7f22585a2ba0>

    def test_exposure_egress(self) -> None:
        egress = exposure_egress()
>       matching_requests = assert_exposure_side_effects_contract(
            egress.interface,
            self.responses,
            flag_key=self.flag_key,
...
Testing the test | System Tests (python, dev) / End-to-end #1 / flask-poc 1 — ❌ 1 test failed · 🔧 Needs a code fix, caused by this PR

View more details · View in GitHub Actions

1 failed test. AssertionError: Timed out waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user' at tests/ffe/utils/exposures.py:66.

Showing tests most relevant to this failure.

❌ tests.ffe.test_exposure_egress.Test_FFE_Exposure_Egress_Agentless_Direct.test_exposure_egress[flask-poc] from system_tests_suite
AssertionError: Timed out waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user'

self = <tests.ffe.test_exposure_egress.Test_FFE_Exposure_Egress_Agentless_Direct object at 0x7f5b547f3260>

    def test_exposure_egress(self) -> None:
        egress = exposure_egress()
>       matching_requests = assert_exposure_side_effects_contract(
            egress.interface,
            self.responses,
            flag_key=self.flag_key,
...
Testing the test | System Tests (python, dev) / End-to-end #1 / python3.12 1 — ❌ 1 test failed · 🔧 Needs a code fix, caused by this PR

View more details · View in GitHub Actions

1 failed test. AssertionError: Timed out waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user' in tests/ffe/utils/exposures.py:66.

Showing tests most relevant to this failure.

❌ tests.ffe.test_exposure_egress.Test_FFE_Exposure_Egress_Agentless_Direct.test_exposure_egress[python3.12] from system_tests_suite
AssertionError: Timed out waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user'

self = <tests.ffe.test_exposure_egress.Test_FFE_Exposure_Egress_Agentless_Direct object at 0x7f5d18a9e120>

    def test_exposure_egress(self) -> None:
        egress = exposure_egress()
>       matching_requests = assert_exposure_side_effects_contract(
            egress.interface,
            self.responses,
            flag_key=self.flag_key,
...

View all 9 failed jobs.

📋 Copy fix prompt
CI on my pull request is failing. Help me find and fix the root cause of each failing job below — they were flagged as caused by changes in this PR, so focus on the diff. For each job, explain the failure and propose a fix.

Before you start, set up the Datadog software-delivery tooling so you can
query the CI data yourself:

1. Check whether you already have the Datadog software-delivery MCP tools
   (e.g. a `search_datadog_ci_pipeline_events` tool) and the `unblock-pr` skill.
2. If either is missing, STOP and ask me for permission before installing
   anything. Do not install or run anything until I have said yes.
3. Only with my explicit approval, set up the Datadog software-delivery MCP
   server and skills by following:
     https://docs.datadoghq.com/getting_started/software_delivery_mcp_tools/
   then restart so the skill is picked up.
4. If I decline, skip all of the above and work from the context below alone.

Then run /unblock-pr — it will pull the CI data itself. The job context below is what we already know.

If /unblock-pr is not available — because I declined the setup above, or it did not install — work from the context below instead.

Datadog has already classified this failure as caused by changes in this PR.
Take that as given and work the fix:

1. Locate the change. Diff this branch against its base and find the change
   that produces this error. Explain the mechanism, don't just name a file:
     git fetch origin && git diff $(git merge-base origin/main HEAD)...HEAD
2. Reproduce it locally. Run the failing job's command or test before
   proposing anything.
3. Propose the smallest fix that addresses the root cause — not a workaround,
   not a broadened assertion, not a disabled or skipped test.
4. Re-run the same command to confirm, and say exactly what you ran.
5. If the failure turns out to be intermittent rather than deterministic, say
   so plainly instead of "fixing" it — that is a flaky test, and patching it
   hides the problem.

If the right move is to re-run the job rather than change code, use the job
link in the context below. For GitHub Actions: `gh run rerun <run-id> --failed`,
where the run ID is the number after `/runs/` in that URL (not the trailing
number, which is the job ID).

Branch: leo.romanovsky/ffe-agentless-evp-fallback-python-tests

Testing the test | System Tests (python, dev) / End-to-end #1 / django-py3.13 1
Commit: 90c290bce2b967b573f566583759e368532f0a52
Error (code / test):
1 failed test due to timeout waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user' at tests/ffe/utils/exposures.py:66
CI job: https://github.com/DataDog/system-tests/actions/runs/33017203431/job/98339408782

Testing the test | System Tests (python, dev) / End-to-end #1 / flask-poc 1
Commit: 90c290bce2b967b573f566583759e368532f0a52
Error (code / test):
1 failed test. AssertionError: Timed out waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user' at tests/ffe/utils/exposures.py:66.
CI job: https://github.com/DataDog/system-tests/actions/runs/33017203431/job/98339408985

Testing the test | System Tests (python, dev) / End-to-end #1 / python3.12 1
Commit: 90c290bce2b967b573f566583759e368532f0a52
Error (code / test):
1 failed test. AssertionError: Timed out waiting for exposure event for 'empty-targeting-key-flag' and 'exposure-egress-user' in tests/ffe/utils/exposures.py:66.
CI job: https://github.com/DataDog/system-tests/actions/runs/33017203431/job/98339408890

Plus 6 more failing jobs not shown here.

ℹ️ Info

No other issues found (see more)

❄️ No new flaky tests detected

Useful? React with 👍 / 👎

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: a2af596 | Docs | View more details | Give us feedback!

The direct-intake contract continues to validate route selection and API-key authentication without requiring the unrelated fingerprint header.

Environment: Datadog workspace
Keep the fingerprint split compatible with the repository formatter.

Environment: Datadog workspace
Exercise exposure and flag-evaluation delivery through the Python direct and serverless agentless scenarios.

Environment: Datadog workspace
@linear-code

linear-code Bot commented Aug 26, 2026

Copy link
Copy Markdown

FFL-1489

@leoromanovsky leoromanovsky changed the title test(ffe): validate Python agentless EVP egress test(ffe): validate Python agentless EVP fallback Aug 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant