-
Notifications
You must be signed in to change notification settings - Fork 10
chore: release main #520
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
stainless-app
wants to merge
5
commits into
main
Choose a base branch
from
release-please--branches--main--changes--next
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
chore: release main #520
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
94335d7
feat(registration): report the agent's commit and source repo at regi…
max-parke-scale 53ab900
feat(tracing): stamp __commit_sha__ automatically when AGENT_COMMIT_S…
max-parke-scale d88fac6
feat(obs): wire sgp-obs from the SDK for traces, metrics and logs (#518)
stephen-wang24 687ebfb
revert(obs): remove sgp-obs beta changes (#522)
stephen-wang24 ba336f3
chore: release main
stainless-app[bot] File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,4 @@ | ||
| { | ||
| ".": "0.26.0", | ||
| "adk": "0.26.0" | ||
| ".": "0.27.0", | ||
| "adk": "0.27.0" | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,4 @@ | ||
| # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. | ||
|
|
||
| __title__ = "agentex" | ||
| __version__ = "0.26.0" # x-release-please-version | ||
| __version__ = "0.27.0" # x-release-please-version |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| """Registration metadata: what an agent reports about itself at startup.""" | ||
|
|
||
| from __future__ import annotations | ||
|
|
||
| import pytest | ||
|
|
||
| from agentex.lib.utils.registration import build_registration_metadata | ||
| from agentex.lib.environment_variables import EnvironmentVariables | ||
|
|
||
| SHA = "b362b171a9c4e1f09d8e7a6b5c4d3e2f1a0b9c8d" | ||
|
|
||
|
|
||
| def _env(**overrides) -> EnvironmentVariables: | ||
| return EnvironmentVariables(AGENT_NAME="sample-agent", ACP_URL="http://agent", **overrides) | ||
|
|
||
|
|
||
| def test_nothing_known_yields_empty_metadata(): | ||
| assert build_registration_metadata(_env()) == {} | ||
|
|
||
|
|
||
| def test_commit_and_repo_reported_when_set(): | ||
| env = _env(AGENT_COMMIT_SHA=SHA, AGENT_SOURCE_REPO="git@github.com:scaleapi/Demo.git") | ||
| assert build_registration_metadata(env) == { | ||
| "commit_sha": SHA, | ||
| "source_repo": "github.com/scaleapi/Demo", | ||
| } | ||
|
|
||
|
|
||
| @pytest.mark.parametrize("value", ["latest", "v1.2.3", "rocket_mock_agent-" + SHA, "abc", " "]) | ||
| def test_non_commit_values_are_omitted_not_forwarded(value): | ||
| """A field named for a commit never holds an image tag, same rule as __commit_sha__.""" | ||
| assert "commit_sha" not in build_registration_metadata(_env(AGENT_COMMIT_SHA=value)) | ||
|
|
||
|
|
||
| def test_repo_normalization_strips_scheme_and_credentials(): | ||
| env = _env(AGENT_SOURCE_REPO="https://x-token:secret@GitHub.com/scaleapi/Demo.git") | ||
| assert build_registration_metadata(env)["source_repo"] == "github.com/scaleapi/Demo" | ||
|
|
||
|
|
||
| def test_deployment_id_and_agent_card_still_reported(): | ||
| class Card: | ||
| def model_dump(self): | ||
| return {"name": "sample"} | ||
|
|
||
| env = _env(AGENTEX_DEPLOYMENT_ID="dep-1") | ||
| assert build_registration_metadata(env, Card()) == { | ||
| "deployment_id": "dep-1", | ||
| "agent_card": {"name": "sample"}, | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_enable_from_environment()runs once whencode_revisionis imported. Normal worker startup importsregister_agentbeforeEnvironmentVariables.refresh()loads supported.envand.env.localfiles. A validAGENT_COMMIT_SHAfrom those files reaches registration but never enables tracing. Run the hook after refresh, or read the value lazily.Knowledge Base Used:
Prompt To Fix With AI