skillfed

dparse2

A parser for Python dependency files

dparse2 v0.7.0 130.4K downloads/30d#11,640 on PyPI2
Permissive license MIT DORMANT released

What it is and what it does

dparse2 is a maintained fork of the original dparse library that parses Python dependency manifests and extracts structured information about each dependency. It reads requirements.txt, Pipfile, Pipfile.lock, conda.yml, tox.ini, and setup.cfg files, then returns parsed data as JSON-serializable objects containing package names, version specifications, hashes, and other metadata.

The package is designed for tools that need to analyze or process Python project dependencies programmatically. It depends on packvers, pyyaml, and toml for parsing different file formats. The fork was created because the original upstream project became unresponsive; this version supports Python 3.6 through 3.11 and has been marked Production/Stable, though active maintenance has stalled.

Use it for:

  • Analyze dependencies in a Python project to detect version conflicts or outdated packages
  • Extract and validate hashes from requirements files for supply-chain security checks
  • Convert between different dependency file formats by parsing one and regenerating another
  • Build a dependency graph or audit trail from conda.yml or Pipfile.lock for compliance reporting
  • Integrate dependency parsing into a CI/CD pipeline to validate manifest syntax before deployment

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Parses Python dependency manifests (requirements.txt, Pipfile, conda.yml, tox.ini, setup.cfg) and extracts structured dependency information including version specs and hashes.

Yes, if you need to parse Python dependency files programmatically and can accept dormant maintenance. The package is stable, has no known vulnerabilities, and low install friction. However, the last release was in 2022—if you encounter bugs or need support for new dependency formats, you may need to fork or patch it yourself.

Install

dparse2 on PyPI

pip

pip install dparse2

uv

uv add dparse2

poetry

poetry add dparse2

Installing dparse2

Before you install

Low install friction with three lightweight runtime dependencies (packvers, pyyaml, toml). Maintenance is dormant—last release was in 2022 and the repository shows minimal recent activity, though it remains a maintained fork of an upstream project that stopped updating.

License in practice

MIT license is permissive and poses no restrictions on use, modification, or distribution in commercial or private projects.

Quickstart

from dparse2 import parse, filetypes

content = "South==1.0.1\npycrypto>=2.6"
df = parse(content, file_type=filetypes.requirements_txt)
print(df.json())

Requires Python 3.6 or later; pipenv extra must be installed separately if Pipfile updates are needed.

Verify before relying

  • Whether the package handles all edge cases in modern Python dependency formats (e.g., PEP 508 environment markers, direct URL references)
  • Performance characteristics when parsing large or deeply nested dependency files
  • Whether the pipenv extra dependency is still maintained and functional

Package facts

License MIT (permissive)
Python support supports the current Python release (>=3.6)
Install friction low — pure-Python wheel
Runtime dependencies 3 — packvers, pyyaml, toml
Maintenance dormant — 1,330 days since the last release
Last repo commit
First released
Downloads 130,426/month — #11,640 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: dparse2-0.7.0-py3-none-any.whl

Keywords: dparse, pypi, dependencies, tox, conda, pipfile, setup.cfg

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseNatural Language :: EnglishProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9

Tags

python dependency file parserrequirements.txt parserpipfile parserparse python dependenciesdependency manifest parserconda yml parserextract python package versions
dependency-analysismanifest-parsing

More Build Tools packages