Skip to content
TopicTracker
来自 simonwillison.net查看原文
译文语言译文语言

用MicroPython和WebAssembly在沙盒中运行Python代码

作者多年来一直在探索代码沙盒方案,最新尝试是通过MicroPython与WebAssembly实现。他发布了alpha包micropython-wasm,利用wasmtime运行Python代码,支持持久化解释器状态、宿主函数暴露、内存和CPU限制(通过燃料机制控制操作数),并严格控制文件与网络访问。该方案已用于Datasette Agent插件datasette-agent-micropython,可通过uvx快速体验,但作者强调目前仍是alpha版本,不建议用于生产环境。

相关报道

  • HtmlUnit 5.0.0 has been released, now requiring JDK 17 as the minimum version. Key updates include major JavaScript engine improvements, full Web Crypto API support, WebSocket improvements, Web Speech API support, and updated browser profiles for Firefox 150 and Chrome/Edge 148.

  • JsPlumb, the JavaScript library for building visual connectivity interfaces, has released a major update with a modernized API and new diagram/2D chart engines. The project is now free for non-commercial use, with packages available for React, Angular, Vue, Svelte, and vanilla JS on the public NPM registry.

  • Datasette-apps is a new system that allows users to bundle and install full applications within Datasette, turning it into a platform for data-driven apps. It enables developers to create self-contained packages combining SQLite databases, metadata, plugins, templates, and assets.