Kognitos BDK Poetry Plugin
Project description
Poetry Plugin for Book Development Kit
The Poetry plugin for BDK is designed to enhance documentation workflows by automatically generating a comprehensive USAGE.md file from the docstrings embedded within a Poetry-managed Python project. This plugin seamlessly integrates with the Poetry ecosystem, parsing the docstrings of functions and classes to produce a well-structured and readable markdown file that outlines usage examples, input and output concepts, return types, and descriptions.
Usage
In order to be able to use the plugin, you must first add the BDK repository to Poetry itself:
Edit ~/.config/pypoetry/pyproject.toml and add the following lines to it:
NOTE: If you are on macOS that path is ~/Library/Application\ Support/pypoetry/pyproject.toml
[[tool.poetry.source]]
name = "bdk"
url = "https://kognitos-719468614044.d.codeartifact.us-west-2.amazonaws.com/pypi/bdk/simple/"
priority = "explicit"
Authenticate the repository using your AWS credentials (notice the authentication will only last 12 hours):
poetry config http-basic.bdk aws $(aws codeartifact get-authorization-token --domain-owner 719468614044 --domain kognitos --query 'authorizationToken' --output text)
Add the plugin to poetry:
poetry self add kognitos-bdk-poetry-plugin --source bdk
Build and Contribute
Prerequisites
Before you begin, ensure you have the following installed on your system:
Python 3.11
The project is developed with Python 3.11. We recommend using Pyenv to manage your Python versions.
To manage Python 3.11 with Pyenv, follow these steps:
Install Pyenv
If you haven't installed Pyenv yet, you can find the installation instructions on the Pyenv GitHub page. The installation process varies depending on your operating system.
Install Python 3.11
Once Pyenv is installed, you can install Python 3.11 using the following command:
pyenv install 3.11.0
Poetry
Poetry is used for dependency management and packaging in this project.
Install Poetry
Run the following command to install Poetry:
curl -sSL https://install.python-poetry.org | python3 -
Setting Up the Project
Clone the Repository
Ensure you have the necessary permissions to access the repository and clone it to your local machine:
git clone https://github.com/kognitos/bdk.git
cd bdk
Install Dependencies
Use Poetry to install all required dependencies in an isolated environment:
poetry install
Building the Project
To build the project, run:
poetry build
Running Tests
BDK uses Pytest as its test runner. You can execute it using the following command:
poetry run tests
Formatting Code
BDK uses yapf as its source formatter. You can execute it using the following command:
poetry run format
Linting Code
BDK uses pylint as its source linter. You can execute it using the following command:
poetry run lint
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kognitos_bdk_poetry_plugin-1.3.1.tar.gz.
File metadata
- Download URL: kognitos_bdk_poetry_plugin-1.3.1.tar.gz
- Upload date:
- Size: 12.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
19f64a24e39689c397e0a7e714856ef75bfc81eff66cd51b076360fcf206ac2d
|
|
| MD5 |
c472fd083a62b352be03de1a9e4c4489
|
|
| BLAKE2b-256 |
3334d4559889259ccdde77d7697acade3ea36e7b8e205f8d03ed4f735018b68e
|
File details
Details for the file kognitos_bdk_poetry_plugin-1.3.1-py3-none-any.whl.
File metadata
- Download URL: kognitos_bdk_poetry_plugin-1.3.1-py3-none-any.whl
- Upload date:
- Size: 13.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
603c2262147e179901314588ed3e59e145cd82eed73b72254b72e974b46419a0
|
|
| MD5 |
2eb5995578536ea47f26eb582407fb4c
|
|
| BLAKE2b-256 |
789c9c065dc51e9cdadefdc6b8bdc5575e70514b016e1862789cea5064b85a9f
|