Skip to content

Commit 15b9ce8

Browse files
committed
merge main
2 parents 1221aa9 + 5b03148 commit 15b9ce8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+2281
-337
lines changed

.github/actions/spelling/allow.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ AError
44
ARequest
55
ARun
66
AServer
7+
AServers
78
AStarlette
89
EUR
910
GBP
@@ -13,6 +14,7 @@ JSONRPCt
1314
Llm
1415
aconnect
1516
adk
17+
agentic
1618
autouse
1719
cla
1820
cls
@@ -24,6 +26,7 @@ dunders
2426
genai
2527
gle
2628
inmemory
29+
kwarg
2730
langgraph
2831
lifecycles
2932
linting

.github/actions/spelling/excludes.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,3 +86,4 @@
8686
\.vscode/
8787
noxfile.py
8888
\.ruff.toml$
89+
CHANGELOG.md

.github/actions/spelling/line_forbidden.patterns

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@
295295
(?!'")[‘’“”]
296296

297297
# "an" should only be before vowels.
298-
\ban\s+(?![FHLMNRSX][A-Z0-9]+\b)(?!hour\b)(?!honest\b)([b-df-hj-np-tv-zB-DF-HJ-NP-TV-Z]{1}\w*)
298+
\ban\s+(?![FHLMNRSX][A-Z0-9]+\b)(?!hour\b)(?!honest\b)(?!httpx?\b)([b-df-hj-np-tv-zB-DF-HJ-NP-TV-Z]{1}\w*)
299299

300300
# Don't use Google internal links
301301
((corp|prod|sandbox).google.com|googleplex.com|https?://(?!localhost/)[0-9a-z][0-9a-z-]+/|(?:^|[^/.-])\b(?:go|b|cl|cr)/[a-z0-9_.-]+\b)

.github/linters/.markdownlint.json

Lines changed: 0 additions & 4 deletions
This file was deleted.

.github/linters/.mypy.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[mypy]
22
exclude = examples/
3-
disable_error_code = import-not-found
3+
disable_error_code = import-not-found,annotation-unchecked
44

55
[mypy-examples.*]
66
follow_imports = skip

.github/release-please.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
releaseType: python
2+
handleGHRelease: true
3+
bumpMinorPreMajor: false
4+
bumpPatchForMinorPreMajor: true

.github/release-trigger.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
enabled: true

.github/workflows/linter.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,5 @@ jobs:
6262
VALIDATE_JAVASCRIPT_STANDARD: false
6363
VALIDATE_TYPESCRIPT_STANDARD: false
6464
VALIDATE_GIT_COMMITLINT: false
65-
MARKDOWN_CONFIG_FILE: .markdownlint.json
6665
PYTHON_MYPY_CONFIG_FILE: .mypy.ini
67-
FILTER_REGEX_EXCLUDE: "^examples/.*"
66+
FILTER_REGEX_INCLUDE: "^src/**"
Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
name: Update A2A Schema from Specification
2+
3+
on:
4+
schedule:
5+
- cron: "0 0 * * *" # Runs daily at 00:00 UTC
6+
workflow_dispatch:
7+
8+
jobs:
9+
check_and_update:
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: write
13+
pull-requests: write
14+
15+
steps:
16+
- name: Checkout code
17+
uses: actions/checkout@v4
18+
19+
- name: Set up Python
20+
uses: actions/setup-python@v5
21+
with:
22+
python-version: "3.13"
23+
24+
- name: Install uv
25+
run: curl -LsSf https://astral.sh/uv/install.sh | sh
26+
27+
- name: Configure uv shell
28+
run: echo "$HOME/.cargo/bin" >> $GITHUB_PATH
29+
30+
- name: Install dependencies (datamodel-code-generator)
31+
run: uv sync
32+
33+
- name: Define output file variable
34+
id: vars
35+
run: |
36+
GENERATED_FILE="./src/a2a/types.py"
37+
echo "GENERATED_FILE=$GENERATED_FILE" >> "$GITHUB_OUTPUT"
38+
39+
- name: Run datamodel-codegen
40+
run: |
41+
set -euo pipefail # Exit immediately if a command exits with a non-zero status
42+
43+
REMOTE_URL="https://raw.githubusercontent.com/google/A2A/refs/heads/main/specification/json/a2a.json"
44+
GENERATED_FILE="${{ steps.vars.outputs.GENERATED_FILE }}"
45+
46+
echo "Running datamodel-codegen..."
47+
uv run datamodel-codegen \
48+
--url "$REMOTE_URL" \
49+
--input-file-type jsonschema \
50+
--output "$GENERATED_FILE" \
51+
--target-python-version 3.10 \
52+
--output-model-type pydantic_v2.BaseModel \
53+
--disable-timestamp \
54+
--use-schema-description \
55+
--use-union-operator \
56+
--use-field-description \
57+
--use-default \
58+
--use-default-kwarg \
59+
--use-one-literal-as-default \
60+
--class-name A2A \
61+
--use-standard-collections
62+
echo "Codegen finished."
63+
64+
- name: Create Pull Request if generated file changed
65+
uses: peter-evans/create-pull-request@v6
66+
with:
67+
token: ${{ secrets.A2A_BOT_PAT }}
68+
committer: a2a-bot <[email protected]>
69+
author: a2a-bot <[email protected]>
70+
commit-message: "chore: 🤖 Auto-update A2A schema from specification"
71+
title: "chore: 🤖 Auto-update A2A Schema from Specification"
72+
body: |
73+
This PR automatically updates the A2A schema types based on the latest specification.
74+
75+
This update was triggered by the scheduled workflow run.
76+
See the workflow run details: [${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }})
77+
branch: "a2a-schema-update"
78+
base: main
79+
labels: |
80+
automated
81+
dependencies
82+
add-paths: ${{ steps.vars.outputs.GENERATED_FILE }}

CHANGELOG.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Changelog
2+
3+
## [0.2.3](https://github.com/google/a2a-python/compare/v0.2.2...v0.2.3) (2025-05-20)
4+
5+
6+
### Features
7+
8+
* Add request context builder with referenceTasks ([#56](https://github.com/google/a2a-python/issues/56)) ([f20bfe7](https://github.com/google/a2a-python/commit/f20bfe74b8cc854c9c29720b2ea3859aff8f509e))
9+
10+
## [0.2.2](https://github.com/google/a2a-python/compare/v0.2.1...v0.2.2) (2025-05-20)
11+
12+
13+
### Documentation
14+
15+
* Write/Update Docstrings for Classes/Methods ([#59](https://github.com/google/a2a-python/issues/59)) ([9f773ef](https://github.com/google/a2a-python/commit/9f773eff4dddc4eec723d519d0050f21b9ccc042))

0 commit comments

Comments
 (0)