Repository navigation
fix(sdk): support TypeSafe integration discovery (SAO-18273) - #638
Conversation
|
| Topic | Details | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| TypeSafe Discovery | Support TypeSafe discovery alongside chat providers by advertising capabilities only on integration discovery endpoints, decoding mixed provider responses, and hydrating GenericProvider metadata including selection and disabled state.Modified files (9)
Latest Contributors(2)
| |||||||||
| Provider Metadata Flow | Refresh provider metadata from the full supported integration list using exact integration IDs, including shared rows, and prevent TypeSafe providers from attempting chat model discovery.Modified files (3)
Latest Contributors(2)
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #638 +/- ##
==========================================
+ Coverage 83.66% 83.86% +0.20%
==========================================
Files 124 124
Lines 11042 11045 +3
==========================================
+ Hits 9238 9263 +25
+ Misses 1804 1782 -22 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
| integration_db.is_selected if not isinstance(integration_db.is_selected, Unset) else False | ||
| ) | ||
| provider.permissions = integration_db.permissions if not isinstance(integration_db.permissions, Unset) else None | ||
| provider._update_from_api_response(integration_db) |
There was a problem hiding this comment.
Drops TypeSafe integration identity during deletion
Deleting a selected TypeSafe integration can mark it DELETED without removing that row because inherited delete() ignores the hydrated provider ID and calls DELETE /integrations/typesafe; use an ID-scoped delete request instead.
Want Baz to fix this for you? Activate Fixer
Other fix methods
Prompt for AI Agents
Before applying, verify this suggestion against the current code. In
`src/galileo/integration.py` around lines 344-346, review `_to_provider` and the
inherited `delete()` path: `_update_from_api_response()` hydrates a TypeSafe row with an
ID, but `GenericProvider` deletion still targets `/integrations/typesafe` and can delete
or mark the wrong same-provider integration. Refactor the deletion logic so it uses the
hydrated integration ID (or an identity-aware endpoint/override) for the selected row,
and only marks that provider `DELETED` after that specific deletion succeeds. Add or
update tests covering multiple integrations with the same provider.
c55a057 to
6acfff0
Compare
Story: SAO-18273
Description:
Support TypeSafe in Python SDK integration discovery without treating it as a chat provider.
typesafe.X-Galileo-Integration-Capabilities: typesafeonly on GET/integrationsand GET/integrations/available; keep this in the generator template.This SDK change can ship while
decision_model_metricsis off. It does not enable the feature. The separate backend compatibility change must deploy before the flag is enabled so already installed older SDKs keep receiving compatible discovery responses. This PR does not implement SDK decision-evaluator creation or change inference, credential selection, retries, sharing permissions, or runner capacity.Tests:
9eaa169c;c55a057aonly corrects a docstring.Draft for private Astra review. Normal CI and maintainer review are still required.