No project description provided
Project description
Sluth- a python library to find python definitions in code without running it
Sluth is a simple utility to find definitions in python code without running it. It is useful for building documentation, finding dependencies, and other tasks that require knowing what a python file does without running it.
from sluth import NodeWalk
source = """
raise ValueError('This file cannot be run')
class Foo:
def bar(self):
pass
"""
node_walk = NodeWalk.from_source(source)
assert node_walk["Foo"]["bar"].lineno == 5
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
sluth-0.2.0.tar.gz
(5.2 kB
view details)
Built Distribution
sluth-0.2.0-py3-none-any.whl
(4.8 kB
view details)
File details
Details for the file sluth-0.2.0.tar.gz
.
File metadata
- Download URL: sluth-0.2.0.tar.gz
- Upload date:
- Size: 5.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: poetry/1.8.1 CPython/3.12.2 Linux/6.5.0-1015-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 263ef548db251e560e3278a08ef41d9adfc906704a3a8f1f245c620e814e0ca0 |
|
MD5 | d409f162d1847736e6fb784ddaa49c3f |
|
BLAKE2b-256 | c080d37377eddf987aeced2c53e8b66888cb01aed355f6309b82c36d8df9a21b |
File details
Details for the file sluth-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: sluth-0.2.0-py3-none-any.whl
- Upload date:
- Size: 4.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: poetry/1.8.1 CPython/3.12.2 Linux/6.5.0-1015-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9ee34ccd19230ff659c8a39e3c412f87c461148ff3a97c29fd36626cb220b8b9 |
|
MD5 | bafd599db97aa83c6c19250a33df8768 |
|
BLAKE2b-256 | 9bd0091cfe63567571e88f5edd36bab702cef4d9d2bee16303e1abb1cf369fbc |