mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #1813] [MERGED] Gate script custom tools #5284
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#5284
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/1813
Author: @Xelvanis
Created: 6/1/2026
Status: ✅ Merged
Merged: 6/1/2026
Merged by: @Xelvanis
Base:
refactor← Head:issue-1791-custom-tool-script-gate📝 Commits (2)
bd341fbGate script custom tools26e3e0eAddress script tool review notes📊 Changes
7 files changed (+30 additions, -120 deletions)
View changed files
📝
src-tauri/src/commands/storage/custom_tools.rs(+14 -4)📝
src/engine/contracts/schemas/custom-tool.schema.ts(+1 -4)📝
src/engine/contracts/types/agent.ts(+1 -2)📝
src/engine/generation/tools-runtime.ts(+2 -72)📝
src/features/catalog/agents/components/ToolEditor.tsx(+11 -34)📝
src/features/catalog/agents/hooks/use-custom-tools.ts(+0 -3)📝
src/features/catalog/characters/lib/character-search.ts(+1 -1)📄 Description
Linked issue
Refs #1791
Partial slice for the script custom-tool safety gap. Does not close #1791 because imported run metadata and cadence-status parity remain separate slices.
Why this change
new Function, while the native custom-tool command already rejected script execution. That left script tools selectable/executable in one runtime path despite the capability model saying script execution should be gated.What changed
scriptExecutionEnabled: falseand kept an actionable rejection for legacy script rows.pnpm checkunused-code gate passes on current refactor.Refactor impact
Primary owner:
Impact areas reviewed:
AgentEditorand chat settings viaisCustomToolSelectable.tools-runtime.ts.custom_tool_executeandcustom_tool_capabilitiesbehavior for static, webhook, legacy script, and unknown execution types.Boundary notes:
IntegrationGatewayport, not direct Tauri APIs.custom_tool_execute/custom_tool_capabilities; this PR does not add command surface.Pressure points touched:
ToolEditor.tsxandtools-runtime.tswere touched narrowly to remove script execution support.Validation
pnpm typecheck,pnpm build,pnpm check:architecture,pnpm check:docs, or fullpnpm checkwhen warranted)pnpm checkpasses locally before PR push/handoff, including the unused-code checkpnpm typecheckpasses locallypnpm buildpasses locallypnpm check:architecturepasses locallypnpm check:docspasses locallycargo check --manifest-path src-tauri/Cargo.toml --workspacepasses locallyManual verification notes
pnpm typecheckpassed locally.cargo test --manifest-path src-tauri/Cargo.toml custom_tools --libpassed locally.pnpm check:architecturepassed locally.cargo check --manifest-path src-tauri/Cargo.toml --workspacepassed locally.pnpm checkpassed locally after removing the stale exportedCharacterSearchScopetype that was already failing the unused-code gate on current refactor.Feature Discoverability
Check exactly one:
src/features/shell/discovery/because this PR adds or materially changes a user-discoverable feature, workflow, setting, mode, panel, import path, agent, media capability, or advanced tool.Reason:
Docs and release impact
No docs changes needed
Updated
README.mdUpdated
CONTRIBUTING.mdUpdated
docs/developer/Updated repo skills or
AGENTS.mdConfirmed this PR does not restore old staging/package-workspace/release claims
No docs changes needed: current custom-tools guidance already describes ME-Refactor as static/webhook only with script execution disabled.
This PR does not restore old staging/package-workspace/release claims.
UI evidence
Summary by CodeRabbit
Breaking Changes
Refactor
Bug Fixes
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.