跳到正文
Simon Willison·· 15 天前

datasette-arrows 0.1a0

datasette-arrows 0.1a0

中文摘要

发布:datasette-arrows 0.1a0 Datasette 1.0a43 添加了插件实现流式导出格式的功能。Datasette 核心支持流式 CSV 和 TSV - 你可以从一个表中导出数百万行数据,而无需将所有数据加载到内存中,因为这两种文件格式支持分块流式数据。register_output_renderer() 插件钩子现在可以用于为其他格式实现相同的模式。我学到的教训是,永远不要在没有配套插件的情况下发布新的插件功能。Claude Fable 5.2 建议将 Apache Arrow 流式格式作为一个好的选项,并几乎一次性地构建了这个插件。将插件添加到 Datasette(datasette install datasette-arrows)后,导出对话框将获得这个新的 Arrow 选项:此截图来自 Datasette 的主分支 - 最近的发布版本尚未将 Arrow 等流式格式与 TSV 和 CSV 一起分组在“此表中的所有行”部分中,但这将在下一个 alpha 版本中实现。标签:datasette,projects

英文原文

Release: datasette-arrows 0.1a0 Datasette 1.0a43 added the ability for plugins to implement streaming export formats. Datasette core supports streaming CSV and TSV - you can export millions of lines of data from a table without needing to load it all into memory, because those two file formats support streaming data in chunks. The register_output_renderer() plugin hook can now be used to implement the same pattern for other formats. I've learned never to release a new plugin feature without accompanying it with a plugin that uses it. Claude Fable 5.2 suggested the Apache Arrow streaming format as a good option, and built this plugin in almost a single shot. Add the plugin to Datasette ( datasette install datasette-arrows ) and the export dialog gains this new Arrow option: This screenshot is from Datasette's main branch - the most recent release doesn't yet group streaming formats such as Arrow with the TSV and CSV in the "All rows in this table" section, but that's coming in the next alpha release. Tags: datasette , projects

应来源方要求,这里只提供摘要与原文入口。完整内容请阅读原文。

来源:Simon Willison · simonwillison.net