SKILL11.1K installs41.8K

Python Resource Management

Python resource management with context managers, cleanup patterns, and streaming. Use when managing connections, file handles, implementing cleanup logic, or building streaming responses with accumulated state.

Type
Skill
Author
wshobson
Category
Backend
GitHub stars
41.8K
Installs
11.1K
Last updated
November 2, 2026

Install

npx skills add https://github.com/wshobson/agents --skill python-resource-management

Use cases


Frequently Asked Questions

What Python patterns does this skill cover?

Context managers, cleanup patterns, and streaming with accumulated state.

Does it address error handling?

Yes, the focus is on releasing resources correctly under both normal and error paths.

What resources does it apply to?

Connections, file handles, and similar resources that need cleanup.


About this skill

Covers Python resource management with context managers, cleanup patterns, and streaming. It applies when handling connections, file handles, or cleanup logic, and when building streaming responses that accumulate state. The focus is on making sure resources are released correctly under both normal and error paths.

Summary written with AI assistance from the project's public description.


Categories


More from wshobson


Similar Skills