Skip to content

google-adk[db] is missing greenlet聽#7341

Description

@aseelmannfuzzy

馃敶 Required Information

Describe the Bug:
With the recent new release of sqlalchemy (v2.1), sqlalchemy does no longer install the greenlet dependency by default. Consequently, with only google-adk[db] and an install after the release of sqlalchemy in v2.1, the db-related async functionality is missing and instantiating DatabaseSessionService results in NameError: name 'create_async_engine' is not defined.

Steps to Reproduce:

  1. Install 'google-adk[db]' (tested with v2.10.0); this needs to install sqlalchemy>=2.1
  2. Instantiate a DatabaseSessionService
  3. Observe the error
db_engine = create_async_engine(db_url, **engine_kwargs)
                      ^^^^^^^^^^^^^^^^^^^
E         NameError: name 'create_async_engine' is not defined

.venv/lib/python3.13/site-packages/google/adk/sessions/database_session_service.py:393: NameError

Expected Behavior:
Instantiating DatabaseSessionService should pass normally.

Observed Behavior:
A NameError occurs due to the missing greenlet dependency.

Environment Details:

  • ADK Library Version (pip show google-adk): 2.10.0 (but earlier version should be affected alike)
  • Desktop OS:** Ubuntu 24.04 on WSL under Windows 11
  • Python Version (python -V): 3.13.13

Model Information:

  • Are you using LiteLLM: No
  • Which model is being used: gemini-3.7-flash

馃煛 Optional Information

Regression:
This worked fine with ~v2.0 of sqlalchemy.

Additional Context:
Additionally installing greenlet (resp. sqlalchemy[asyncio]) solves the issue, but since ADK relies on async session so heavily, google-adk[db] really just should install sqlalchemy with the asyncio extra.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

services[Component] This issue is related to runtime services, e.g. sessions, memory, artifacts, etc

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions