Skip to main content

Generate dependency graphs and modify Python packages based on the generated graphs.

Project description

Deprive

Installation

pip install deprive

Disabled Python Features

If one of the disabled features is used, a NotImplementedError will be raised:

  1. Star imports (e.g., from module import *).
  2. Redefining imports (independent of the scope).
  3. Multiple statements per line (e.g., a = 1; b = 2).

Discouraged Python Features

These following features don't raise any warning or errors, but the correctness of the output is not guaranteed:

  1. importlib.import_module, __import__, eval, exec, or similar dynamic functions.
  2. Overwriting built-in functions.
  3. Assigning functions to variables.
  4. Namespace packages (e.g., no __init__.py in a package).

Changelog

0.3.0

  • Add attributes of imports to the dependency graph.

0.1.2 - Initial Release

  • Initial implementation of the deprive library.
  • Support for parsing Python files and generating dependency graphs.
  • Codes needs to be cleaned up and refactored.

TODO:

  • parse type annotations
  • add tests for handler, and add a enum or similar to the _assets proj

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

deprive-0.3.0.tar.gz (33.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

deprive-0.3.0-py3-none-any.whl (19.6 kB view details)

Uploaded Python 3

File details

Details for the file deprive-0.3.0.tar.gz.

File metadata

  • Download URL: deprive-0.3.0.tar.gz
  • Upload date:
  • Size: 33.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.22

File hashes

Hashes for deprive-0.3.0.tar.gz
Algorithm Hash digest
SHA256 930bd4f0ab7a903451717e6389ebb981878f311074d8dfc512f8eb945ff5366f
MD5 e47e1164ae67f7e9e1185450d8bd28ff
BLAKE2b-256 d8ea114e259360cb87a869857d5b811c90ddf3674a755f29fb503d1057bced1d

See more details on using hashes here.

File details

Details for the file deprive-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: deprive-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 19.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.22

File hashes

Hashes for deprive-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 dafcdb430725c36d76c145e98bf7da4e23c90b8697aafc66bf16e054be8604c9
MD5 272660100c69ae5a51d6b4c4d0f12568
BLAKE2b-256 43a2c6a64d2137a057d034a8524eb9536072e92df1bea81f124fbde5f60f5625

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page