Repository navigation
Conversation
MyPrototypeWhat
left a comment
There was a problem hiding this comment.
Thanks for the Learn Workbench PR. We re-checked on 7e56fde8. This isn't ready to merge yet.
The blocking issue is the lesson iframe. Lessons are served same-origin from /w/... and loaded with sandbox="allow-scripts allow-same-origin allow-popups allow-modals" in app.js. LESSON_CSP sets connect-src 'none', which only blocks fetches made by the iframe itself. With allow-scripts and allow-same-origin together, a script in a lesson page can reach the parent page — its DOM, storage, and parent.fetch. We independently confirmed that code setup. A review run also showed that a lesson script could change the parent title, write the parent's localStorage and cookies, inject a script into the parent, and call /api/bootstrap (which includes home and drives) and /api/fs/list?path=/ through parent.fetch and get a 200. Dropping allow-same-origin turned those accesses into SecurityError. Lesson HTML is generated from web research and is allowed to run its own scripts, so this isn't just theoretical.
A few related points, not all of them blockers in the same way:
/api/fs/listwill list any absolute directory. That fits the folder picker, but combined with the iframe issue, a lesson script can browse outside the workspace.resolveInside(and the create path) only do lexicalpath.resolve/path.relative. They do notrealpath, so a symlink inside the workspace can be read, and create can follow a link past the home-directory / drive-root string checks.- The main session automatically
allowOnces writes to workspace files classified asother(neverProtect). If someone imports an existing project, that can touch non-workbench files. We did not run this through the Host to a disk write. - The icon is the default hello-miniapp bar-chart graphic. It is a real, recognizable image, so we are not blocking on that alone, but it is not specific to this plugin.
- There are no package tests, and the PR body has no hosted screenshots or video of the product UI.
Please tighten the lesson sandbox so a lesson page cannot reach the parent page or its APIs, and look at the path and write-scope issues above. Happy to re-review once that's in.
Add Learn Workbench, a teach-method learning workbench for MiniMax Code. Pick a learning folder, let the Agent write the mission and curriculum, and give every lesson its own branch conversation. It also annotates lessons, distils notes, and opens file links at the matching lines in an in-app panel.
Tested environment
Checks
node scripts/validate.mjs:plugins/meisijiya/learn-workbench: OK,examples/hello-miniapp: OK,repository: OK(0 errors, 0 warnings).npm test: 94 pass, 2 fail. Both failures are the repository's own symlink tests intest/files.test.mjs, which fail withEPERMon Windows because creating symlinks requires Developer Mode or administrator rights. They are unrelated to this package and should pass on macOS/Linux.Access
Declares
agentAccess: ["session.run"],agentConcurrency: 4andsurface.window; minimum client MiniMax Code 3.1.2. No MCP endpoints, no device access, no host-navigation read. File access is limited to the learning folder the user picks; details are in the package README under "Data & access".Written with MiniMax Code
A teach-method learning workbench: mission and curriculum written by the main conversation, a branch conversation per lesson that writes one self-contained HTML lesson, text-selection annotations with highlights, note extraction into Markdown, a floating code panel for file links such as
main.py:608, and workspace management (create/import/remove, per-lesson regenerate, clean artifacts, model switch). The package is self-contained (no build step, no node_modules) and is the same code published at https://github.com/meisijiya/learn-workbench-miniapp.Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.