Skip to main content

No project description provided

Project description

CVLDoc Parser: Python module

Exposes a Python API for the CVLDoc module. WIP.

Usage

First, make sure Rust 1.62 or newer is installed. Clone the entire repo, then from the project base:

$ cd src/python_wrapper
$ python -m venv .env
$ source .env/bin/activate
$ pip install maturin

It creates a virtual environment for development, and should only be done once. Now, while the .env is sourced, it is possible to run

$ maturin build

in order to build the module, which can then be used in the virtualenv or installed globally with pip install {generated .whl file}. It is also possible to run maturin develop in order to generate a temporary module.

It is now possible to import the module:

$ python
>>> import cvldoc_parser

API

Currently exposes a single function, cvldoc_parser.parse(paths). It takes a list of file paths as strings, and returns a list of parsed CVLDoc objects for each path. A parsed CVLDoc object is either a Documentation or a FreeForm. They both support a diagnostics() method, that returns a list of warnings or errors associated with that object.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

cvldoc_parser-1.0.1-cp37-abi3-win_amd64.whl (733.9 kB view hashes)

Uploaded CPython 3.7+ Windows x86-64

cvldoc_parser-1.0.1-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (10.1 MB view hashes)

Uploaded CPython 3.7+ manylinux: glibc 2.17+ x86-64

cvldoc_parser-1.0.1-cp37-abi3-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (2.9 MB view hashes)

Uploaded CPython 3.7+ macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

Supported by

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