reasoning-deployment-service 0.4.7__py3-none-any.whl → 0.4.8__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of reasoning-deployment-service might be problematic. Click here for more details.
- reasoning_deployment_service/reasoning_deployment_service.py +21 -28
- {reasoning_deployment_service-0.4.7.dist-info → reasoning_deployment_service-0.4.8.dist-info}/METADATA +1 -1
- {reasoning_deployment_service-0.4.7.dist-info → reasoning_deployment_service-0.4.8.dist-info}/RECORD +6 -6
- {reasoning_deployment_service-0.4.7.dist-info → reasoning_deployment_service-0.4.8.dist-info}/WHEEL +0 -0
- {reasoning_deployment_service-0.4.7.dist-info → reasoning_deployment_service-0.4.8.dist-info}/entry_points.txt +0 -0
- {reasoning_deployment_service-0.4.7.dist-info → reasoning_deployment_service-0.4.8.dist-info}/top_level.txt +0 -0
|
@@ -776,8 +776,9 @@ class ReasoningEngineDeploymentService:
|
|
|
776
776
|
new_authorizations: Optional[list[str]] = None,
|
|
777
777
|
) -> dict:
|
|
778
778
|
"""
|
|
779
|
-
|
|
779
|
+
Safely patch metadata (displayName, description) and linkage fields
|
|
780
780
|
(reasoningEngine, authorizations) for an existing Agent Space agent.
|
|
781
|
+
Preserves all other required adkAgentDefinition fields.
|
|
781
782
|
"""
|
|
782
783
|
url = (
|
|
783
784
|
f"{DISCOVERY_ENGINE_URL}/projects/{self._project_id}/locations/global/"
|
|
@@ -791,7 +792,7 @@ class ReasoningEngineDeploymentService:
|
|
|
791
792
|
resp.raise_for_status()
|
|
792
793
|
agent_data = resp.json()
|
|
793
794
|
|
|
794
|
-
#
|
|
795
|
+
# Build patch payload by merging
|
|
795
796
|
patch_payload = {}
|
|
796
797
|
|
|
797
798
|
if new_display_name:
|
|
@@ -799,44 +800,36 @@ class ReasoningEngineDeploymentService:
|
|
|
799
800
|
if new_description:
|
|
800
801
|
patch_payload["description"] = new_description
|
|
801
802
|
|
|
802
|
-
|
|
803
|
-
|
|
803
|
+
# Copy entire current adkAgentDefinition
|
|
804
|
+
adk_def = agent_data.get("adkAgentDefinition", {}).copy()
|
|
804
805
|
|
|
805
806
|
if new_reasoning_engine:
|
|
806
|
-
|
|
807
|
+
adk_def.setdefault("provisionedReasoningEngine", {})[
|
|
807
808
|
"reasoningEngine"
|
|
808
809
|
] = new_reasoning_engine
|
|
809
810
|
|
|
810
811
|
if new_authorizations is not None:
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
if
|
|
814
|
-
patch_payload["adkAgentDefinition"] =
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
update_mask = []
|
|
818
|
-
if "displayName" in patch_payload:
|
|
819
|
-
update_mask.append("display_name")
|
|
820
|
-
if "description" in patch_payload:
|
|
821
|
-
update_mask.append("description")
|
|
822
|
-
if "adkAgentDefinition" in patch_payload:
|
|
823
|
-
if "provisionedReasoningEngine" in patch_payload["adkAgentDefinition"]:
|
|
824
|
-
update_mask.append("adk_agent_definition.provisioned_reasoning_engine")
|
|
825
|
-
if "authorizations" in patch_payload["adkAgentDefinition"]:
|
|
826
|
-
update_mask.append("adk_agent_definition.authorizations")
|
|
827
|
-
|
|
828
|
-
if not update_mask:
|
|
812
|
+
adk_def["authorizations"] = new_authorizations
|
|
813
|
+
|
|
814
|
+
if adk_def:
|
|
815
|
+
patch_payload["adkAgentDefinition"] = adk_def
|
|
816
|
+
|
|
817
|
+
if not patch_payload:
|
|
829
818
|
self.info("[AGENT PATCH] Nothing to update.")
|
|
830
819
|
return agent_data
|
|
831
820
|
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
patch_resp = self._http.patch(
|
|
836
|
-
|
|
821
|
+
self.info(
|
|
822
|
+
f"[AGENT PATCH] PATCH {url} with payload={json.dumps(patch_payload, indent=2)}"
|
|
823
|
+
)
|
|
824
|
+
patch_resp = self._http.patch(url, headers=headers, json=patch_payload, timeout=60)
|
|
825
|
+
try:
|
|
826
|
+
self.info(f"[AGENT PATCH] response={json.dumps(patch_resp.json(), indent=2)}")
|
|
827
|
+
except Exception:
|
|
828
|
+
self.info(f"[AGENT PATCH] response_text={(patch_resp.text or '')[:1000]}")
|
|
837
829
|
patch_resp.raise_for_status()
|
|
838
830
|
|
|
839
831
|
return patch_resp.json()
|
|
832
|
+
|
|
840
833
|
|
|
841
834
|
def one_githhub_deployment_to_go_with_skip(self):
|
|
842
835
|
return self.one_github_deployment_to_go(skip_engine=True)
|
{reasoning_deployment_service-0.4.7.dist-info → reasoning_deployment_service-0.4.8.dist-info}/RECORD
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
reasoning_deployment_service/__init__.py,sha256=xDuKt9gGviQiTV6vXBdkBvygnlAOIrwnUjVaMGZy0L4,670
|
|
2
|
-
reasoning_deployment_service/reasoning_deployment_service.py,sha256=
|
|
2
|
+
reasoning_deployment_service/reasoning_deployment_service.py,sha256=sYW_nbA3_gXQiGBq3RVef-0KHq97AEVlxK5iuUQ32lg,43767
|
|
3
3
|
reasoning_deployment_service/runner.py,sha256=qWN0t66lQ1G4ht48gIHSF2JvedcheHRu8PmUz5TaKTI,5619
|
|
4
4
|
reasoning_deployment_service/cli_editor/__init__.py,sha256=bN8NPkw8riB92pj2lAwJZuEMOQIO_RRuge0ehnJTW1I,118
|
|
5
5
|
reasoning_deployment_service/cli_editor/api_client.py,sha256=Kzx5iYp0MmowggrSmPLE7I2kt1-8xvdGBAgde9a1gCY,33681
|
|
@@ -22,8 +22,8 @@ reasoning_deployment_service/gui_editor/src/ui/authorization_view.py,sha256=BoNc
|
|
|
22
22
|
reasoning_deployment_service/gui_editor/src/ui/reasoning_engine_view.py,sha256=tCvSPEf4dW0NRdAqfs3yT5Pa873gYeLzCMMIt2r2T4o,14644
|
|
23
23
|
reasoning_deployment_service/gui_editor/src/ui/reasoning_engines_view.py,sha256=IRjFlBbY98usAZa0roOonjvWQOsF6NBW4bBg_k8KnKI,7860
|
|
24
24
|
reasoning_deployment_service/gui_editor/src/ui/ui_components.py,sha256=HdQHy-oSZ3GobQ3FNdH7y_w3ANbFiuf2rMoflAmff0A,55366
|
|
25
|
-
reasoning_deployment_service-0.4.
|
|
26
|
-
reasoning_deployment_service-0.4.
|
|
27
|
-
reasoning_deployment_service-0.4.
|
|
28
|
-
reasoning_deployment_service-0.4.
|
|
29
|
-
reasoning_deployment_service-0.4.
|
|
25
|
+
reasoning_deployment_service-0.4.8.dist-info/METADATA,sha256=xaV7O_noHdI6o9brO0H-mCST2KYSvlqoe0gOV0jnqA8,5302
|
|
26
|
+
reasoning_deployment_service-0.4.8.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
27
|
+
reasoning_deployment_service-0.4.8.dist-info/entry_points.txt,sha256=onGKjR5ONTtRv3aqEtK863iw9Ty1kLcjfZlsplkRZrA,84
|
|
28
|
+
reasoning_deployment_service-0.4.8.dist-info/top_level.txt,sha256=GKuQS1xHUYLZbatw9DmcYdBxxLhWhhGkV4FmFxgKdp0,29
|
|
29
|
+
reasoning_deployment_service-0.4.8.dist-info/RECORD,,
|
{reasoning_deployment_service-0.4.7.dist-info → reasoning_deployment_service-0.4.8.dist-info}/WHEEL
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|