Skip to content

chore: sync main -> v2#4915

Open
Jacksunwei wants to merge 313 commits intov2from
main
Open

chore: sync main -> v2#4915
Jacksunwei wants to merge 313 commits intov2from
main

Conversation

@Jacksunwei
Copy link
Copy Markdown
Collaborator

Automated sync of v1 changes from main into v2. The oncall is responsible for reviewing and merging this PR. Resolve conflicts in favor of the v2 implementation.

@google-cla
Copy link
Copy Markdown

google-cla Bot commented Mar 20, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

google-genai-bot and others added 29 commits March 23, 2026 08:43
The log message when instantiating DatabaseSessionService is updated from "Falling back to..." to "Using..." for clarity.

Close #4890

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 888160397
Close #4947

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 888296476
Merge #4720
Close #4697

Co-authored-by: Xuan Yang <xygoogle@google.com>
COPYBARA_INTEGRATE_REVIEW=#4720 from kaligautier:fix/global-and-regional-region ed0b18d
PiperOrigin-RevId: 888728543
…82.6

Versions 1.82.7 and 1.82.8 of LiteLLM were affected by a supply chain attack and are now explicitly excluded from the dependency constraints for both project and dev dependencies.

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 888818704
Co-authored-by: Sasha Sobran <asobran@google.com>
PiperOrigin-RevId: 888850792
Introduces a new index `idx_events_app_user_session_ts` on the `events` table in both V0 and V1 database schemas. This index covers `app_name`, `user_id`, `session_id`, and `timestamp` (descending) to improve query performance.

Modifies `DatabaseSessionService` to automatically create any missing indexes defined in the SQLAlchemy metadata when preparing the database tables.

Close #4827

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 888877174
…tionTool`

Merge #4778

Closes: #4777

Co-authored-by: Xuan Yang <xygoogle@google.com>
COPYBARA_INTEGRATE_REVIEW=#4778 from gautamvarmadatla:fix/pydantic-basemodel-required-fields 45db622
PiperOrigin-RevId: 888905953
Merge #4990

Syncs version bump and CHANGELOG from release v1.27.4 to main.

COPYBARA_INTEGRATE_REVIEW=#4990 from google:release/v1.27.4 71982f2
PiperOrigin-RevId: 888928449
Update the `model_config` for `Event` to set `extra='ignore'`. This allows the `Event` model to be initialized with fields not explicitly defined in the model, preventing errors when deserializing data that may contain additional, unneeded fields. This allows the session service to accept 2.0 events.

Co-authored-by: Shangjie Chen <deanchen@google.com>
PiperOrigin-RevId: 889327445
…sionService

Introduces a new helper function, `_get_or_create_state`, which uses a nested transaction (SAVEPOINT) to safely attempt creating a state row. If a concurrent transaction has already inserted the row, the inner insert will fail with an IntegrityError, which is caught, and the already-existing row is then fetched

Close #4954

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 889441684
…d LiteLLM upperbound

Co-authored-by: Sasha Sobran <asobran@google.com>
PiperOrigin-RevId: 889449878
…or clearer agent feedback and correct typing

PiperOrigin-RevId: 889521009
- Migrate `tools/bigquery` to `integrations/bigquery` to match standard ADK layout.
- Update unit tests to fully assert integration migration.

Co-authored-by: Haiyuan Cao <haiyuan@google.com>
PiperOrigin-RevId: 889634966
- Migrate `tools/bigquery` to `integrations/bigquery` to match standard ADK layout.
- Update unit tests to fully assert integration migration.

PiperOrigin-RevId: 889796517
Co-authored-by: Sasha Sobran <asobran@google.com>
PiperOrigin-RevId: 889890969
- Migrate `tools/bigquery` to `integrations/bigquery` to match standard ADK layout.
- Update unit tests to fully assert integration migration.

PiperOrigin-RevId: 889891348
Co-authored-by: Sasha Sobran <asobran@google.com>
PiperOrigin-RevId: 889912141
PiperOrigin-RevId: 889912199
- Migrate `tools/bigquery` to `integrations/bigquery` to match standard ADK layout.
- Update unit tests to fully assert integration migration.

Co-authored-by: Haiyuan Cao <haiyuan@google.com>
PiperOrigin-RevId: 889963735
PiperOrigin-RevId: 889992570
… default

Co-authored-by: Sasha Sobran <asobran@google.com>
PiperOrigin-RevId: 890025323
…definitions

The list_agents method in AgentLoader no longer attempts to determine the agent language for each directory

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 890078066
Merge #5016

Syncs version bump and CHANGELOG from release v1.28.0 to main.

COPYBARA_INTEGRATE_REVIEW=#5016 from google:release/v1.28.0 4e05efb
PiperOrigin-RevId: 890122693
…r session management

Co-authored-by: Xuan Yang <xygoogle@google.com>
PiperOrigin-RevId: 890127075
The workflow now accepts a `release_branch` input, checks out the specified release branch, and updates the version in `src/google/adk/version.py`

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 890134954
…ponses

Close: #4609

Co-authored-by: Xuan Yang <xygoogle@google.com>
PiperOrigin-RevId: 890144644
google-genai-bot and others added 30 commits April 28, 2026 13:11
Co-authored-by: Wiktoria Walczak <wwalczak@google.com>
PiperOrigin-RevId: 907418898
`gemini-1.*` and `gemini-2.0*` models are respectively deprecated and scheduled for shutdown on June 1, 2026. `gemini-2.5*` models are their successors.
No regressions in unit tests:
```
========================================================================================== 5583 passed, 2237 warnings in 84.91s (0:01:24) ===========================================================================================
```

PiperOrigin-RevId: 907663315
… and `output_schema` together

PiperOrigin-RevId: 907857917
Previously it was just in adk create, now add it to adk deploy in case users create an agent on their own and need to deploy with api key. Moved the shared logic into a utils/onboarding.py file

Co-authored-by: Kathy Wu <wukathy@google.com>
PiperOrigin-RevId: 908191494
Close #5103

Co-authored-by: Kathy Wu <wukathy@google.com>
PiperOrigin-RevId: 908196458
Co-authored-by: Sasha Sobran <asobran@google.com>
PiperOrigin-RevId: 908322085
… 3.1 tool calls

Fixes #5407

END_PUBLIC

Merge #5408

## Summary

- Tool call parts received via `LiveServerToolCall` in `GeminiLlmConnection.receive()` are now yielded immediately instead of being deferred until `turn_complete`
- This unblocks function/tool calling for Gemini 3.1 Flash Live models which do not emit `turn_complete` until they receive the tool response

## Problem

Gemini 3.1 Flash Live models send tool calls via `LiveServerToolCall` and wait for the tool response before sending `turn_complete`. The current code accumulates `tool_call_parts` and only yields them on `turn_complete` or loop exit, creating a deadlock where tools are never executed.

## Fix

Yield `tool_call_parts` immediately after receiving `message.tool_call`. This is backward-compatible — earlier models that send `turn_complete` after tool calls will still work because the existing yield paths become no-ops when `tool_call_parts` is already empty.

## Test plan

- [x] Tested with `gemini-3.1-flash-live-preview` in live mode — tool calls now execute on the first message and the model responds with audio after receiving tool results
- [x] Verified no regression with the existing `turn_complete`-based flow

Co-authored-by: Sasha Sobran <asobran@google.com>
COPYBARA_INTEGRATE_REVIEW=#5408 from sandeshveerani4:fix/live-tool-call-yield ca0e760
PiperOrigin-RevId: 908326192
…onal` for conversation_scenario support

Close #5214

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 908347275
Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 908397117
Co-authored-by: Kathy Wu <wukathy@google.com>
PiperOrigin-RevId: 908414335
Merge #5563

Syncs version bump and CHANGELOG from release v1.32.0 to main.

COPYBARA_INTEGRATE_REVIEW=#5563 from google:release/v1.32.0 1551268
PiperOrigin-RevId: 908475510
Co-authored-by: Yifan Wang <wanyif@google.com>
PiperOrigin-RevId: 908496612
Co-authored-by: Yifan Wang <wanyif@google.com>
PiperOrigin-RevId: 908883116
…mResponse

Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 908900779
This fixes an issue where AgentEngineSandboxCodeExecutor catches the wrong exception class when attempting to recover from externally-deleted sandboxes.

Fixes #5480

Co-authored-by: Amaad Martin <amaadmartin@google.com>
PiperOrigin-RevId: 908965545
Merge #4722
Close #4721

Co-authored-by: Xuan Yang <xygoogle@google.com>
COPYBARA_INTEGRATE_REVIEW=#4722 from polar3130:feat/apigee-llm-userinfo-email-scope f746117
PiperOrigin-RevId: 910144731
PiperOrigin-RevId: 910258324
They were added prematurely, and currently output.type diverges from what's in semconv (https://opentelemetry.io/docs/specs/semconv/registry/attributes/gen-ai/), so this change removes them from our metrics, at least for the time being.

PiperOrigin-RevId: 910587563
Merge #4642
Fixes #3178

Co-authored-by: Xuan Yang <xygoogle@google.com>
COPYBARA_INTEGRATE_REVIEW=#4642 from yuvrajangadsingh:fix/state-delta-overwrite-3178 f4cc2f2
PiperOrigin-RevId: 910767582
…ging in BigQuery plugin

This PR addresses three distinct issues in the BigQuery Agent Analytics Plugin:

1. Fix false-positive fork detection:
When the plugin is deployed via Vertex AI Agent Engine, it undergoes a pickle/unpickle lifecycle which resets `_init_pid` to 0. Previously, `_ensure_started()` would incorrectly detect this as a fork since `os.getpid()` is never 0, causing unnecessary cold-start latency and log noise. The PID check now distinguishes `_init_pid == 0` (unpickled) from a real fork.

2. Correct GCS offload unit mismatch:
Separates the evaluation limits for offloading text content to GCS. It evaluates the byte-based storage guard (`inline_text_limit`) and the character-based truncation limit (`max_length`) independently, preventing mismatched unit comparisons.

3. Add AGENT_RESPONSE logging:
Logs final response events emitted by agents to BigQuery. This explicitly filters out intermediate steps such as function calls/responses, streaming partials, and invisible internal reasoning ("thoughts") so that only the final visible response text is captured.

Co-authored-by: Haiyuan Cao <haiyuan@google.com>
PiperOrigin-RevId: 910770002
Co-authored-by: Xuan Yang <xygoogle@google.com>
PiperOrigin-RevId: 910796426
…ent engine

Deploying using API key has been leading to "Deploy failed: 'NoneType' object has no attribute 'before_request'" errors because creating cloud resources requires ADC credentials (project id and region)

Co-authored-by: Kathy Wu <wukathy@google.com>
PiperOrigin-RevId: 910821145
Co-authored-by: George Weale <gweale@google.com>
PiperOrigin-RevId: 910839657
… available

This reduces the token usage of having skills appended to the instruction on every call

Co-authored-by: Kathy Wu <wukathy@google.com>
PiperOrigin-RevId: 910904229
…istered AuthProvider

PiperOrigin-RevId: 911115744
Co-authored-by: Xuan Yang <xygoogle@google.com>
PiperOrigin-RevId: 911411431
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.