Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions src/iac_code/a2a/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -1731,9 +1731,7 @@ def _resolve_cwd(self, metadata: Any | None) -> str:
raise ValueError("Invalid A2A workspace metadata.")
logical_cwd = os.path.normpath(cwd)
resolved_cwd = resolve_workspace_path(Path(logical_cwd))
if not trust_request_cwd() and not any(
_is_relative_to(resolved_cwd, root) for root in _allowed_cwd_roots()
):
if not trust_request_cwd() and not any(_is_relative_to(resolved_cwd, root) for root in _allowed_cwd_roots()):
raise ValueError("Invalid A2A workspace metadata.")
if resolved_cwd.exists():
if not resolved_cwd.is_dir():
Expand Down
26 changes: 8 additions & 18 deletions src/iac_code/a2a/input_required.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,35 +178,29 @@ def permission_display_fields(request: PermissionRequestEvent, *, language: str
command = safe_input.get("command") or safe_input.get("cmd")
if isinstance(command, str) and command.strip():
command_fallback = translate_message("shell command", language=language)
target = translate_message(
"the current local workspace; command: {command}", language=language
).format(command=_display_text(command, fallback=command_fallback, maximum=240))
target = translate_message("the current local workspace; command: {command}", language=language).format(
command=_display_text(command, fallback=command_fallback, maximum=240)
)
else:
target = translate_message("the current local workspace", language=language)
effect = "read" if is_read_only else ("local_execution" if read_only_known else "unknown")
elif tool_name in {"write_file", "edit_file"}:
title = translate_message("Change a workspace file", language=language)
purpose = translate_message(
"Write a file needed for the requested infrastructure task.", language=language
)
purpose = translate_message("Write a file needed for the requested infrastructure task.", language=language)
target = _safe_input_target(safe_input, language=language) or translate_message(
"a file in the current workspace", language=language
)
effect = "file_change"
elif tool_name in {"read_file", "glob", "grep"} or is_read_only:
title = translate_message("Read workspace data with {tool}", language=language).format(tool=public_tool)
purpose = translate_message(
"Read local data needed for the requested infrastructure task.", language=language
)
purpose = translate_message("Read local data needed for the requested infrastructure task.", language=language)
target = _safe_input_target(safe_input, language=language) or translate_message(
"the current local workspace", language=language
)
effect = "read"
else:
title = translate_message("Run {tool}", language=language).format(tool=public_tool)
purpose = translate_message(
"Run this operation for the requested infrastructure task.", language=language
)
purpose = translate_message("Run this operation for the requested infrastructure task.", language=language)
target = _safe_input_target(safe_input, language=language) or translate_message(
"the current task workspace or cloud account", language=language
)
Expand Down Expand Up @@ -319,9 +313,7 @@ def _cloud_operation_title(product: str, action: str, *, is_read_only: bool, lan
if action == "CreateStack":
return translate_message("Create {product} stack", language=language).format(product=product_label)
if action == "ContinueCreateStack":
return translate_message("Continue creating {product} stack", language=language).format(
product=product_label
)
return translate_message("Continue creating {product} stack", language=language).format(product=product_label)
if action == "UpdateStack":
return translate_message("Update {product} stack", language=language).format(product=product_label)
if action == "DeleteStack":
Expand All @@ -344,9 +336,7 @@ def _safe_input_target(value: Any, *, language: str) -> str:
for key in ("file_path", "filePath", "path", "region_id", "regionId", "resource_id", "resourceId"):
candidate = value.get(key)
if isinstance(candidate, str) and candidate.strip():
return _display_text(
candidate, fallback=translate_message("the current task scope", language=language)
)
return _display_text(candidate, fallback=translate_message("the current task scope", language=language))
return ""


Expand Down
6 changes: 1 addition & 5 deletions src/iac_code/a2a/pipeline_executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -1235,11 +1235,7 @@ def _create_pipeline(
def permission_context_getter() -> Any:
return getattr(agent_loop, "_permission_context", None)

surface = (
A2A_RICH_CANDIDATE_SURFACE
if self._candidate_presentation == RICH_CANDIDATE_PRESENTATION
else "a2a"
)
surface = A2A_RICH_CANDIDATE_SURFACE if self._candidate_presentation == RICH_CANDIDATE_PRESENTATION else "a2a"
return create_pipeline(
pipeline_name,
provider_manager=runtime.provider_manager,
Expand Down
4 changes: 1 addition & 3 deletions src/iac_code/a2a/task_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -864,9 +864,7 @@ async def has_active_work(self) -> bool:
any(record.active_task is not None and not record.active_task.done() for record in self._tasks.values())
or any(not task.done() for task in self._context_runtime_tasks.values())
or any(
not task.done()
for starts in self._context_execution_starts.values()
for task in starts.values()
not task.done() for starts in self._context_execution_starts.values() for task in starts.values()
)
or any(self._context_reconciliation_waiters.values())
or any(lock.locked() for lock in self._reconciliation_locks.values())
Expand Down
18 changes: 14 additions & 4 deletions src/iac_code/i18n/locales/de/LC_MESSAGES/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4086,6 +4086,16 @@ msgstr ""
"eine erfolgreiche Prüfung mit übereinstimmenden Parametern und Nachweisen"
" abgedeckt sein."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid ""
"The final instance spec must match the architecture plan, budget "
"deviation must be disclosed, and a contract discount must only be "
"reported when it actually reduces the price."
msgstr ""
"Die endgültige Instanzspezifikation muss dem Architekturplan entsprechen,"
" Budgetabweichungen müssen offengelegt werden, und ein Vertragsrabatt "
"darf nur ausgewiesen werden, wenn er den Preis tatsächlich senkt."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid ""
"Complete the current step by calling this tool to submit the conclusion. "
Expand Down Expand Up @@ -4194,15 +4204,15 @@ msgstr ""
"{message} complete_step.conclusion muss eines dieser Felder enthalten: "
"{fields}."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A completion guard is misconfigured."
msgstr "Eine Abschlussbedingung ist falsch konfiguriert."

#: src/iac_code/pipeline/engine/complete_step_tool.py
#, python-brace-format
msgid "{message} Validation issue: {code} ({detail})."
msgstr "{message} Validierungsproblem: {code} ({detail})."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A completion guard is misconfigured."
msgstr "Eine Abschlussbedingung ist falsch konfiguriert."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A conclusion content hash is required before completing the current step."
msgstr ""
Expand Down
16 changes: 8 additions & 8 deletions src/iac_code/i18n/locales/de/LC_MESSAGES/webui.po
Original file line number Diff line number Diff line change
Expand Up @@ -545,6 +545,14 @@ msgstr "{n}Wo"
msgid "{n}y"
msgstr "{n}J"

#: src/iac_code/web/static/js/app.js
msgid "Operation failed"
msgstr "Vorgang fehlgeschlagen"

#: src/iac_code/web/static/js/app.js
msgid "Archive failed"
msgstr "Archivierung fehlgeschlagen"

#: src/iac_code/web/static/js/app.js
msgid "Read-only"
msgstr "Schreibgeschützt"
Expand All @@ -561,14 +569,6 @@ msgstr "Bitte geben Sie einen Inhalt ein"
msgid "Please enter a name"
msgstr "Bitte geben Sie einen Namen ein"

#: src/iac_code/web/static/js/app.js
msgid "Operation failed"
msgstr "Vorgang fehlgeschlagen"

#: src/iac_code/web/static/js/app.js
msgid "Archive failed"
msgstr "Archivierung fehlgeschlagen"

#: src/iac_code/web/static/js/app.js
#, python-brace-format
msgid "Remove {label}?"
Expand Down
19 changes: 15 additions & 4 deletions src/iac_code/i18n/locales/es/LC_MESSAGES/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4063,6 +4063,17 @@ msgstr ""
"Cada restricción estricta explícita del usuario debe estar cubierta por "
"una comprobación satisfactoria con parámetros y evidencias coincidentes."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid ""
"The final instance spec must match the architecture plan, budget "
"deviation must be disclosed, and a contract discount must only be "
"reported when it actually reduces the price."
msgstr ""
"La especificación final de la instancia debe coincidir con el plan de "
"arquitectura, se debe divulgar la desviación del presupuesto y un "
"descuento contractual solo se puede informar cuando realmente reduce el "
"precio."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid ""
"Complete the current step by calling this tool to submit the conclusion. "
Expand Down Expand Up @@ -4168,15 +4179,15 @@ msgstr ""
"{message} complete_step.conclusion debe incluir uno de estos campos: "
"{fields}."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A completion guard is misconfigured."
msgstr "La guarda de finalización está mal configurada."

#: src/iac_code/pipeline/engine/complete_step_tool.py
#, python-brace-format
msgid "{message} Validation issue: {code} ({detail})."
msgstr "{message} Problema de validación: {code} ({detail})."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A completion guard is misconfigured."
msgstr "La guarda de finalización está mal configurada."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A conclusion content hash is required before completing the current step."
msgstr ""
Expand Down
16 changes: 8 additions & 8 deletions src/iac_code/i18n/locales/es/LC_MESSAGES/webui.po
Original file line number Diff line number Diff line change
Expand Up @@ -547,6 +547,14 @@ msgstr "{n}sem"
msgid "{n}y"
msgstr "{n}a"

#: src/iac_code/web/static/js/app.js
msgid "Operation failed"
msgstr "La operación falló"

#: src/iac_code/web/static/js/app.js
msgid "Archive failed"
msgstr "Error al archivar"

#: src/iac_code/web/static/js/app.js
msgid "Read-only"
msgstr "Solo lectura"
Expand All @@ -563,14 +571,6 @@ msgstr "Introduce contenido"
msgid "Please enter a name"
msgstr "Introduce un nombre"

#: src/iac_code/web/static/js/app.js
msgid "Operation failed"
msgstr "La operación falló"

#: src/iac_code/web/static/js/app.js
msgid "Archive failed"
msgstr "Error al archivar"

#: src/iac_code/web/static/js/app.js
#, python-brace-format
msgid "Remove {label}?"
Expand Down
19 changes: 15 additions & 4 deletions src/iac_code/i18n/locales/fr/LC_MESSAGES/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -4072,6 +4072,17 @@ msgstr ""
"être couverte par une vérification réussie avec des paramètres et des "
"preuves concordants."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid ""
"The final instance spec must match the architecture plan, budget "
"deviation must be disclosed, and a contract discount must only be "
"reported when it actually reduces the price."
msgstr ""
"La spécification finale de l’instance doit correspondre au plan "
"d’architecture, tout écart budgétaire doit être signalé, et une remise "
"contractuelle ne peut être mentionnée que si elle réduit réellement le "
"prix."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid ""
"Complete the current step by calling this tool to submit the conclusion. "
Expand Down Expand Up @@ -4175,15 +4186,15 @@ msgstr ""
"{message} complete_step.conclusion doit inclure l’un de ces champs : "
"{fields}."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A completion guard is misconfigured."
msgstr "Une garde de finalisation est mal configurée."

#: src/iac_code/pipeline/engine/complete_step_tool.py
#, python-brace-format
msgid "{message} Validation issue: {code} ({detail})."
msgstr "{message} Problème de validation : {code} ({detail})."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A completion guard is misconfigured."
msgstr "Une garde de finalisation est mal configurée."

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A conclusion content hash is required before completing the current step."
msgstr ""
Expand Down
16 changes: 8 additions & 8 deletions src/iac_code/i18n/locales/fr/LC_MESSAGES/webui.po
Original file line number Diff line number Diff line change
Expand Up @@ -545,6 +545,14 @@ msgstr "{n} sem"
msgid "{n}y"
msgstr "{n} an"

#: src/iac_code/web/static/js/app.js
msgid "Operation failed"
msgstr "Échec de l’opération"

#: src/iac_code/web/static/js/app.js
msgid "Archive failed"
msgstr "Échec de l’archivage"

#: src/iac_code/web/static/js/app.js
msgid "Read-only"
msgstr "Lecture seule"
Expand All @@ -561,14 +569,6 @@ msgstr "Veuillez saisir du contenu"
msgid "Please enter a name"
msgstr "Veuillez saisir un nom"

#: src/iac_code/web/static/js/app.js
msgid "Operation failed"
msgstr "Échec de l’opération"

#: src/iac_code/web/static/js/app.js
msgid "Archive failed"
msgstr "Échec de l’archivage"

#: src/iac_code/web/static/js/app.js
#, python-brace-format
msgid "Remove {label}?"
Expand Down
15 changes: 11 additions & 4 deletions src/iac_code/i18n/locales/ja/LC_MESSAGES/messages.po
Original file line number Diff line number Diff line change
Expand Up @@ -3874,6 +3874,13 @@ msgid ""
"with matching parameters and evidence."
msgstr "ユーザーが明示した各ハード制約は、パラメーターと根拠が一致する「満たしている」チェックで網羅する必要があります。"

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid ""
"The final instance spec must match the architecture plan, budget "
"deviation must be disclosed, and a contract discount must only be "
"reported when it actually reduces the price."
msgstr "最終的なインスタンス仕様はアーキテクチャ計画と一致していなければならず、予算の乖離は明示的に開示し、契約割引は実際に価格が下がる場合にのみ記載してください。"

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid ""
"Complete the current step by calling this tool to submit the conclusion. "
Expand Down Expand Up @@ -3967,15 +3974,15 @@ msgid ""
"{fields}."
msgstr "{message} complete_step.conclusion には次のいずれかのフィールドが必要です: {fields}。"

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A completion guard is misconfigured."
msgstr "完了ガードの設定に誤りがあります。"

#: src/iac_code/pipeline/engine/complete_step_tool.py
#, python-brace-format
msgid "{message} Validation issue: {code} ({detail})."
msgstr "{message} 検証上の問題: {code} ({detail})。"

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A completion guard is misconfigured."
msgstr "完了ガードの設定に誤りがあります。"

#: src/iac_code/pipeline/engine/complete_step_tool.py
msgid "A conclusion content hash is required before completing the current step."
msgstr "現在のステップを完了する前に、結論内容のハッシュが必要です。"
Expand Down
16 changes: 8 additions & 8 deletions src/iac_code/i18n/locales/ja/LC_MESSAGES/webui.po
Original file line number Diff line number Diff line change
Expand Up @@ -539,6 +539,14 @@ msgstr "{n}週間"
msgid "{n}y"
msgstr "{n}年"

#: src/iac_code/web/static/js/app.js
msgid "Operation failed"
msgstr "操作に失敗しました"

#: src/iac_code/web/static/js/app.js
msgid "Archive failed"
msgstr "アーカイブに失敗しました"

#: src/iac_code/web/static/js/app.js
msgid "Read-only"
msgstr "読み取り専用"
Expand All @@ -555,14 +563,6 @@ msgstr "内容を入力してください"
msgid "Please enter a name"
msgstr "名前を入力してください"

#: src/iac_code/web/static/js/app.js
msgid "Operation failed"
msgstr "操作に失敗しました"

#: src/iac_code/web/static/js/app.js
msgid "Archive failed"
msgstr "アーカイブに失敗しました"

#: src/iac_code/web/static/js/app.js
#, python-brace-format
msgid "Remove {label}?"
Expand Down
Loading
Loading