Skip to content

ADK_SUPPRESS_EXPERIMENTAL_FEATURE_WARNINGS not working #5114

Closed

Description

@lovervoorde

Describe the Bug:
ADK_SUPPRESS_EXPERIMENTAL_FEATURE_WARNINGS does not suppress experimental feature warnings, e.g. for A2A or skills.

Steps to Reproduce:
Please provide a numbered list of steps to reproduce the behavior:

  1. Install adk python in a docker image
  2. Set the env var ADK_SUPPRESS_EXPERIMENTAL_FEATURE_WARNINGS=1
  3. Run a main file like this using uvicorn:
import os
import uvicorn
from google.adk.cli.fast_api import get_fast_api_app

AGENT_DIR = os.path.dirname(os.path.abspath(__file__))

app = get_fast_api_app(
    agents_dir=AGENT_DIR,
    web=True,
    a2a=True,
)

if __name__ == "__main__":
    uvicorn.run(
        "main:app",
        host="0.0.0.0",
        port=int(os.environ.get("PORT", 8080)),
        reload=True,
    )

Expected Behavior:
No warnings containing UserWarning: [EXPERIMENTAL] in the logs.

Observed Behavior:
Warnings containing UserWarning: [EXPERIMENTAL] in the logs

Environment Details:

  • ADK Library Version (pip show google-adk): 1.27.2
  • Desktop OS:** [e.g., macOS, Linux, Windows]: linux docker image on macOS
  • Python Version (python -V): 3.11.10

Model Information:

  • Are you using LiteLLM: Yes
  • Which model is being used: (e.g., gemini-2.5-pro): gemini-2.5-flash

🟡 Optional Information

Logs:
Example warning seen in logs:

/opt/venv/lib/python3.11/site-packages/google/adk/a2a/executor/a2a_agent_executor.py:199: UserWarning: [EXPERIMENTAL] convert_a2a_request_to_agent_run_request: ADK Implementation for A2A support (A2aAgentExecutor, RemoteA2aAgent and corresponding supporting components etc.) is in experimental mode and is subject to breaking changes. A2A protocol and SDK are themselves not experimental. Once it's stable enough the experimental mode will be removed. Your feedback is welcome.

How often has this issue occurred?:

  • Always (100%)

Activity

  1. added
    core[Component] This issue is related to the core interface and implementation
    on Apr 2, 2026
  2. added theissue type on Apr 2, 2026
  3. added 2 commits that reference this issue on Apr 3, 2026
    2d26241
    8e97e24
  4. surajksharma07 commented on Apr 10, 2026

    @surajksharma07
    Collaborator

    @lovervoorde Looks like the A2A decorator is internally wired to a separate env var — ADK_SUPPRESS_A2A_EXPERIMENTAL_FEATURE_WARNINGS — rather than the generic one you're setting, which is why it's not being picked up.

    As a quick workaround, try setting both ADK_SUPPRESS_EXPERIMENTAL_FEATURE_WARNINGS=1 and ADK_SUPPRESS_A2A_EXPERIMENTAL_FEATURE_WARNINGS=1 and see if that clears the warnings on your end.

    If it does, the actual fix is a one-liner in a2a/experimental.py — just changing the bypass_env_var param — so it'd be a great candidate for a PR once you've confirmed the workaround holds up in your setup!

  5. lovervoorde commented on Apr 10, 2026

    @lovervoorde
    Author

    Hi Suraj, thanks for the reply. I tried your suggestion but I still see the warnings.

  6. surajksharma07 commented on Apr 10, 2026

    @surajksharma07
    Collaborator

    @lovervoorde Thanks for checking!

    If both env vars still aren't working, the most likely culprit is that they're not actually reaching the container's runtime environment — worth verifying with docker exec env | grep SUPPRESS to confirm they're being picked up.

    As a guaranteed fallback that bypasses the decorator entirely, you can add this before your app = get_fast_api_app(...) call:

    import warnings
    warnings.filterwarnings("ignore", category=UserWarning, message=r"\[EXPERIMENTAL\]")](url)
    

    That works regardless of env vars, so it should unblock you in the meantime.
    PR #5124 is already linked to fix this at the source.

  7. added a commit that references this issue on Apr 14, 2026
    52127cf
  8. surajksharma07 commented on Apr 29, 2026

    @surajksharma07
    Collaborator

    @Jacksunwei Please have a look into it once.

  9. surajksharma07 commented on May 19, 2026

    @surajksharma07
    Collaborator

    Going ahead and closing this out since we haven't heard back in a while — assuming the warnings.filterwarnings("ignore", category=UserWarning, message=r"[EXPERIMENTAL]") fallback is holding up for you!

    Just to confirm for anyone landing here: the split env var (ADK_SUPPRESS_A2A_EXPERIMENTAL_FEATURE_WARNINGS vs the generic one) is still present in v2.0.0, so the warnings.filterwarnings approach remains the most reliable workaround until PR #5124 lands and covers a2a/experimental.py.

    Feel free to reopen if the workaround isn't working for your setup or you're hitting something else — happy to dig in further!

  10. added a commit that references this issue on Oct 16, 2026
    b592dee
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

core[Component] This issue is related to the core interface and implementationneeds review[Status] The PR/issue is awaiting review from the maintainer

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions