Fix malformed README quickstart fence and non-runnable timeout snippet
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 82/100
- Issue 类型
- 文档
- 描述清晰度
- 描述清楚
- 活跃度
- 冷清
- 技术栈
- python
调研方向
从 README.md 的第 27-68 行开始,检查 quickstart fence,然后查看第 230-247 行的 timeout 示例。将完整的 quickstart 保留在一个 Python fence 中,并确保 timeout snippet 包含其所需的 import。渲染 README 并运行独立的 snippet,以验证这些示例可执行。
由索引模型根据 Issue 内容生成。
描述
Description
The README quickstart closes its Python fence immediately after session creation (README.md:43), leaving the Playwright run() function as plain Markdown, then opens an unintended fence at README.md:67. This corrupts the rendered structure around the primary usage example and the following Examples section.
A second runnable-snippet problem appears in the timeout example: README.md:241 calls httpx.Timeout(...), but that code block imports only Browserbase and never imports httpx.
Reproduction
- Render
README.mdon GitHub/PyPI, or track fence state from lines 27-68. - Observe that lines 46-66 are outside the Python block and line 68 (
## Examples) is inside the next fence. - Copy the timeout block at lines 230-247 into a Python process; it raises
NameError: name 'httpx' is not definedat line 241.
Expected behavior
- The entire quickstart (imports, session creation,
run(), and main guard) should be within one Python fence. - Each advertised standalone snippet should contain the imports it needs, including
import httpxfor the granular timeout example.
Actual behavior
The primary README example is malformed when rendered, and the timeout example is not executable as shown.
Why it matters
README content is also used for the package metadata/PyPI page, so these errors affect the first-run path for both GitHub and PyPI users. A lightweight docs test that extracts/compiles Python fences would prevent recurrence.
- 主要语言
- Python
- 星标
- 93
- 派生
- 16
- 平均合并
- 11 分钟
- 30 天内合并 PR
- 3
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
browserbase/sdk-python 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 82/100
browserbase/sdk-python#182 ·
-
难度 2/5 1-3 小时 新手友好度 84/100
browserbase/sdk-python#180 ·
-
难度 2/5 1-3 小时 新手友好度 82/100
browserbase/sdk-python#179 ·
-
难度 2/5 1-3 小时 新手友好度 78/100
browserbase/sdk-python#178 ·
-
难度 2/5 1-3 小时 新手友好度 82/100
browserbase/sdk-python#175 ·
查看 browserbase/sdk-python 的全部 Issue
相似的 Issue
-
documentation help wanted
难度 2/5 1-3 小时 新手友好度 90/100
-
难度 2/5 1-3 小时 新手友好度 90/100
simonw/sqlite-utils#872 ·
-
难度 2/5 1-3 小时 新手友好度 88/100
-
难度 2/5 1-3 小时 新手友好度 82/100
-
难度 2/5 1-3 小时 新手友好度 78/100