🚨 RULE VIOLATION DETECTED (2026-04-21 03:00 +07)
Agent reported "e2e done" by writing 125 lines of handwritten JavaScript in extension/sidepanel.js, background.js etc. This is a direct violation of the Trinity Rust-only policy.
Forbidden artifacts (MUST be deleted)
extension/sidepanel.js (125 lines handwritten JS) ❌
extension/background.js (handwritten JS) ❌
Any .js file in extension/ that is NOT generated by wasm-bindgen / trunk / wasm-pack ❌
Any .sh test script (L1) ❌
Trinity Stack Law (reaffirmed)
Layer
Allowed
Forbidden
Core / crates
Rust
Python, JS, Go
Extension logic
Rust → WASM (via wasm-bindgen / web-sys / leptos / yew / dioxus)
Handwritten .js, .ts
UI markup
HTML + CSS (minimal, generated where possible)
jQuery, hand-rolled JS
Glue (manifest)
manifest.json (data only, no logic)
inline <script> with logic
Scripts
Rust binaries / cargo xtask
.sh, .bash, .zsh
Root Cause
Agent took the lazy path (write JS) instead of the correct path:
crates/trios-ext/ Rust crate compiled to WASM via wasm-pack build --target web
web-sys for DOM, wasm-bindgen-futures for async
gloo-net::websocket for MCP WebSocket to trios-server
Output: extension/dist/trios_ext_bg.wasm + tiny generated trios_ext.js glue (auto, not handwritten)
Acceptance Criteria
Test Plan
cd crates/trios-ext && wasm-pack build --target web --out-dir ../../extension/dist/wasm
Load unpacked extension → side panel opens
Total Black #000000 background, Trinity logo, фирменные цвета (🎨 P0: Brand enforcement — Trinity logo + Total Black palette + working chat (Chrome Extension) #155 )
Chat sends via Rust gloo-net::websocket to ws://localhost:9005/mcp → echo response visible
find extension -name "*.js" -not -path "*/dist/*" → empty
Related
L8 PUSH FIRST + L9 BOARD
Note to agents
Шеф проверяет каждый коммит. Любой .js написанный руками = отзыв задачи + переписать на Rust .
Это не popup-toy, это Trinity. Rust → WASM. Точка.
🚨 RULE VIOLATION DETECTED (2026-04-21 03:00 +07)
Agent reported "e2e done" by writing 125 lines of handwritten JavaScript in
extension/sidepanel.js,background.jsetc. This is a direct violation of the Trinity Rust-only policy.Forbidden artifacts (MUST be deleted)
extension/sidepanel.js(125 lines handwritten JS) ❌extension/background.js(handwritten JS) ❌.jsfile inextension/that is NOT generated bywasm-bindgen/trunk/wasm-pack❌.shtest script (L1) ❌Trinity Stack Law (reaffirmed)
wasm-bindgen/web-sys/leptos/yew/dioxus).js,.tsmanifest.json(data only, no logic)<script>with logiccargo xtask.sh,.bash,.zshRoot Cause
Agent took the lazy path (write JS) instead of the correct path:
crates/trios-ext/Rust crate compiled to WASM viawasm-pack build --target webweb-sysfor DOM,wasm-bindgen-futuresfor asyncgloo-net::websocketfor MCP WebSocket totrios-serverextension/dist/trios_ext_bg.wasm+ tiny generatedtrios_ext.jsglue (auto, not handwritten)Acceptance Criteria
.jsfiles fromextension/(sidepanel.js, background.js)crates/trios-extbuilds withwasm-pack build --target web --out-dir ../../extension/dist/wasmmanifest.jsonreferences only generated wasm-bindgen glue (no handwritten logic)web-sys)gloo-netorweb-sys::WebSocketfrom Rustcargo clippy --target wasm32-unknown-unknown -- -D warnings= 0wasm-pack test --headless --chromepassesgrep -r "function\|=>" extension/*.jsreturns empty (only auto-generated allowed, indist/)extension/**/*.jsoutsidedist/fails build.trinity/experience/2026-04-21-rust-only-extension.mdTest Plan
cd crates/trios-ext && wasm-pack build --target web --out-dir ../../extension/dist/wasm#000000background, Trinity logo, фирменные цвета (🎨 P0: Brand enforcement — Trinity logo + Total Black palette + working chat (Chrome Extension) #155)gloo-net::websockettows://localhost:9005/mcp→ echo response visiblefind extension -name "*.js" -not -path "*/dist/*"→ emptyRelated
L8 PUSH FIRST + L9 BOARD
Closes #156, branch pushed первымNote to agents