‹ 首页

lang-py

@dragoscirjan · 收录于 1 周前 · 上游提交 1 个月前

Python development standards, PEP 8, Google Python Style, and tooling.

适合你,如果希望代码符合 PEP 8 和 Google Python 风格

/ 通过 npx 安装 校验哈希
npx oh-my-skill add dragoscirjan/opencode-config/lang-py
/ 通过 bash 安装
curl -fsSL https://oh-my-skill.com/install.sh | bash -s -- dragoscirjan/opencode-config/lang-py
/ 已经装过?验证本机副本,不用重装
npx oh-my-skill verify dragoscirjan/opencode-config/lang-py
安装目标可用 --agent / --scope 或 --to 明确指定;省略时只会在唯一已存在的 agent 目录上自动选择,零命中或多命中会停止并提示。content_hash 缺失或不一致均拒装。
0GitHub stars
~169上下文体积 · 单文件
索引托管

怎么用

商店整理自技能原文 · 版本 f561928 · 表述以原文为准
它做什么

Claude 会按照 Google Python 风格指南(兼容 PEP 8)编写 Python 代码,强制使用类型注解,推荐列表/字典推导式、生成器,使用 asyncio 处理并发,并明确处理异常。

什么时候触发

当你要求编写或审查 Python 代码时,Claude 会自动应用这些标准。

装好后可以这样说
Claude 会生成带类型注解的代码。
Claude 会检查并给出改进建议。
技能原文 SKILL.md作者撰写 · MIT · f561928

PY Standards

  • Style: Google Python Style Guide (PEP 8 compliant).
  • Tooling: ruff (formatting & linting), mypy (typing), pytest (testing), uv for deps.
  • Typing: Type hints are mandatory (def func(a: int) -> str:).
  • Idioms: Prefer list/dict comprehensions over map/filter. Use generators (yield) for large sequences.
  • Errors: Explicit exception handling. Use raise ... from err. Never use bare except:.
  • Concurrency: Use asyncio and TaskGroup for structured concurrency in I/O tasks.

Always load clean-code alongside this skill.

按 MIT 许可原样转载,未经改动 · 在 GitHub 查看 →

评论

登录即可评论;带「已验证安装」的,是发布者名下有本店的安装或持有记录。