Skip to content

feat(google/cloud/agentregistryendpoint/v1): add google-cloud-agentregistryendpoint - #19314

Open
suztomo wants to merge 1 commit into
mainfrom
onboard-agentregistryendpoint
Open

suztomo wants to merge 1 commit into
mainfrom
onboard-agentregistryendpoint

Conversation

@suztomo

@suztomo suztomo commented Dec 2, 2026

Copy link
Copy Markdown
Member

Onboard google/cloud/agentregistryendpoint/v1 API (google-cloud-agentregistryendpoint).

Internal tracking bug http://b/590946763

PiperOrigin-RevId: 1030994426

Debug Info

System Details

  • Python version: Python 3.13.18
  • OS: Linux 7.1.6-1rodete1-amd64 x86_64
  • Librarian version: v0.54.0

Commands Executed

  • go run github.com/googleapis/librarian/cmd/librarian@v0.54.0 install
  • go run github.com/googleapis/librarian/cmd/librarian@v0.54.0 add google/cloud/agentregistryendpoint/v1
  • go run github.com/googleapis/librarian/cmd/librarian@v0.54.0 generate -v google-cloud-agentregistryendpoint
  • go run github.com/googleapis/librarian/cmd/librarian@v0.54.0 tidy
  • git add -A
  • git commit -m "feat(google/cloud/agentregistryendpoint/v1): add google-cloud-agentregistryendpoint"

@suztomo
suztomo added this pull request to stack #19316 December 2, 2026 19:25

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces the new client library package google-cloud-agentregistryendpoint, which implements the localized dataplane API for Agent Registry. The changes include the generated GAPIC client code, documentation, unit tests, and samples, along with updates to the repository's release configuration files. The review feedback correctly identifies a PEP 8 violation in rest.py where a bare except: clause is used, and recommends catching Exception instead to prevent catching system-exiting exceptions.

method = transcoded_request["method"]
try:
request_payload = type(request).to_json(request)
except:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

This line uses a bare except: clause, which is a violation of PEP 8 style guidelines. Bare except: clauses catch all exceptions, including SystemExit, KeyboardInterrupt, and GeneratorExit, which can make it difficult to interrupt the program (e.g., via Ctrl+C) and can hide unexpected bugs. It is highly recommended to catch Exception instead, or specific exceptions like AttributeError or TypeError since to_json might not be available or fail to serialize.

Suggested change
except:
except Exception:
References
  1. PEP 8: Programming Recommendations - When catching exceptions, mention specific exceptions whenever possible instead of using a bare except: clause. (link)

Base automatically changed from feat-update-sources-2026-12-02 to main December 2, 2026 23:26
@suztomo
suztomo force-pushed the onboard-agentregistryendpoint branch from c8606f8 to 1617805 Compare December 2, 2026 23:26
@suztomo
suztomo marked this pull request as ready for review December 2, 2026 23:26
@suztomo
suztomo requested review from a team as code owners December 2, 2026 23:26
@snippet-bot

snippet-bot Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Here is the summary of changes.

You are about to add 10 region tags.

This comment is generated by snippet-bot.
If you find problems with this result, please file an issue at:
https://github.com/googleapis/repo-automation-bots/issues.
To update this comment, add snippet-bot:force-run label or use the checkbox below:

  • Refresh this comment

@suztomo
suztomo requested a review from ohmayr December 2, 2026 23:27
ohmayr added a commit that referenced this pull request Dec 3, 2026
…19322)

## Context & Problem
Libraries that import google.cloud.agentregistry.v1 proto types (such as
google-cloud-agentregistryendpoint in #19314) are missing
google-cloud-agentregistry in generated setup.py and testing constraint
files because _pypi_packages.j2 does not map this API yet.

## Summary of Changes
- Add ("google", "cloud", "agentregistry", "v1") mapped to
google-cloud-agentregistry (>= 0.1.2, < 1.0.0) in
packages/gapic-generator/gapic/templates/_pypi_packages.j2, matching
#18826 and #19022.

## Why This Approach
Declaring cross-API PyPI packages in _pypi_packages.j2 lets setup.py.j2
and the testing constraint templates emit the dependency automatically
during regeneration instead of maintaining per-package post-processing
overrides.

## Intentionally Out of Scope
- Bumping the pinned gapic-generator commit SHA in librarian.yaml or
regenerating google-cloud-agentregistryendpoint (handled separately
after merge).
- Adding a temporary post-processing override in
.librarian/generator-input/client-post-processing/add-missing-dependencies-to-setup-py-constraints.yaml.

## Verification
nox -s lint mypy-3.14 unit-3.14 passed in packages/gapic-generator.
@ohmayr

ohmayr commented Dec 3, 2026

Copy link
Copy Markdown
Contributor

Hi @suztomo, presubmits are failing with ModuleNotFoundError: No module named google.cloud.agentregistry because google-cloud-agentregistryendpoint imports types from google.cloud.agentregistry.v1. We merged #19322 to add google-cloud-agentregistry to gapic-generator, though librarian.yaml is still pinned to 78ff458.

To unblock this PR (and your stacked #19315 / #19317) right away without waiting for a repo-wide generator bump, could you apply the same bridge used for google-cloud-designcenter in #18894 and regenerate?

  1. In librarian.yaml under google-cloud-agentregistryendpoint.python, add opt_args_by_api with google/cloud/agentregistryendpoint/v1: [proto-plus-deps=google.cloud.agentregistry.v1].
  2. In .librarian/generator-input/client-post-processing/add-missing-dependencies-to-setup-py-constraints.yaml, add entries for packages/google-cloud-agentregistryendpoint/setup.py ("google-cloud-agentregistry >= 0.1.2, <1.0.0") and packages/google-cloud-agentregistryendpoint/testing/constraints-3.10.txt (google-cloud-agentregistry==0.1.2).
  3. Re-run Librarian generate and tidy for google-cloud-agentregistryendpoint.

Once CI is green, happy to approve!

@suztomo
suztomo force-pushed the onboard-agentregistryendpoint branch from 1617805 to d21128c Compare December 3, 2026 02:05

This branch has not been deployed

No deployments
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.

2 participants