Skip to content

add build.md #59

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 3, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 47 additions & 0 deletions BUILD.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
## How to build and test ydb-python-sdk

This document has detailed instructions on how to build ydb-python-sdk from source and run style and unit tests.

### Pre-requisites

- Install [Docker](https://docs.docker.com/engine/install/).
- Install [Python 3.8](https://www.python.org/downloads/release/python-38/)
- Install [pip](https://pip.pypa.io/en/latest/installation/)
- Install [Tox](https://tox.wiki/en/latest/install.html)

### Clone the repository

```sh
git clone https://github.com/ydb-platform/ydb-python-sdk
```

### Run style tests

Use the command below to prepare `virtualenv` and to run style tests using `flake8`.

```sh
tox -estyle
```

### Run formatting checks

Use the command below to prepare `virtualenv` and to run style tests using `black`.
See [documentation](https://black.readthedocs.io/en/stable/) about Black project.

```sh
tox -eblack
```

To automatically format code using the `black` formatting style, use the command below.

```sh
tox -eblack-format
```

### Run unit tests

Use the command below to run unit tests.

```sh
tox -epy310
```