{"categories":[{"label":"Software Development","url":"https://skillfed.io/packages/category/software-development/5"},{"label":"Text Processing","url":"https://skillfed.io/packages/category/text-processing/2"},{"label":"Security","url":"https://skillfed.io/packages/category/security"},{"label":"Quality Assurance","url":"https://skillfed.io/packages/category/software-development-quality-assurance"}],"enrichment":{"capability":"ast-grep-py is a Python binding for ast-grep, a tool that searches, lints, and rewrites code using precise abstract syntax tree patterns.","skillfed_tags":["code-search","ast-analysis","codemod"],"use_cases":["Search for and refactor all uses of a deprecated API across a large codebase in one pass.","Enforce custom code style rules by matching specific AST patterns and flagging violations.","Automate codemod tasks\u2014e.g., migrate from one library to another\u2014by pattern-matching and rewriting code structure.","Build custom linters that detect anti-patterns or security issues based on syntax tree shape.","Analyze code structure programmatically to gather metrics or generate reports on code patterns."],"what_it_does":"ast-grep-py exposes ast-grep's code search and rewriting engine to Python programs. It lets you define patterns that match code structure\u2014not just text\u2014and then find, analyze, or transform matching code at scale. The package is a native Rust binding compiled to wheels, so it has no Python runtime dependencies and runs efficiently on modern Python versions.\n\nYou would use this when you need to perform structural code analysis or refactoring that text regex cannot handle: finding all calls to a deprecated function across a codebase, rewriting patterns to use a new API, or enforcing code style rules based on syntax tree shape. The API is programmatic, so you integrate it into scripts, linters, or CI pipelines rather than using a command-line tool.","worth_installing":"Yes, if you need structural code search or rewriting beyond regex. The package is actively maintained, has no security vulnerabilities, uses a permissive MIT license, and is well-distributed across platforms. Medium install friction is acceptable for a compiled tool. Start with the official API guide to confirm the pattern syntax and API surface fit your use case."},"id":"ast-grep-py","links":{"html":"https://skillfed.io/packages/ast-grep-py","md":"https://skillfed.io/packages/ast-grep-py.md","pypi":"https://pypi.org/project/ast-grep-py/"},"maintenance":{"status":"active"},"meta":{"latest_release":"2026-08-07","license_spdx":null,"license_treatment":"permissive","name":"ast-grep-py","python_support":"supports_current","summary":"Structural Search and Rewrite code at large scale using precise AST pattern."},"popularity":{"monthly_downloads":1163264,"position":4281,"tier":"top_5000"},"security":{"n_vulnerabilities":0},"version":"0.45.1"}
