Skip to content

Commit 46e0dc0

Browse files
committed
Update contributing guide
1 parent 96e3b1d commit 46e0dc0

File tree

1 file changed

+28
-11
lines changed

1 file changed

+28
-11
lines changed

CONTRIBUTING.md

Lines changed: 28 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,23 @@ We use [uv](https://docs.astral.sh/uv/) for project management. Install it and s
1111
We use [Poe the Poet](https://poethepoet.natn.io/) as a task runner, similar to npm scripts in `package.json`.
1212
All tasks are defined in `pyproject.toml` under `[tool.poe.tasks]` and can be run with `uv run poe <task>`.
1313

14+
### Available tasks
15+
16+
| Task | Description |
17+
| ---- | ----------- |
18+
| `install-dev` | Install dependencies and pre-commit hooks |
19+
| `check-code` | Run lint, type-check, and unit-tests |
20+
| `lint` | Run linter |
21+
| `format` | Fix lint issues and format code |
22+
| `type-check` | Run type checker |
23+
| `unit-tests` | Run unit tests |
24+
| `unit-tests-cov` | Run unit tests with coverage |
25+
| `e2e-templates-tests` | Run end-to-end template tests |
26+
| `build-docs` | Build documentation website |
27+
| `run-docs` | Run documentation locally |
28+
| `build` | Build package |
29+
| `clean` | Remove build artifacts |
30+
1431
## Dependencies
1532

1633
To install this package and its development dependencies, run:
@@ -51,7 +68,7 @@ uv run poe format
5168

5269
Type checking is handled by [ty](https://docs.astral.sh/ty/), verifying code against type annotations. Configuration settings can be found in `pyproject.toml`.
5370

54-
To run type-check:
71+
To run type checking:
5572

5673
```sh
5774
uv run poe type-check
@@ -75,10 +92,10 @@ uv run poe unit-tests-cov
7592

7693
## End-to-end tests
7794

78-
Pre-requisites for running end-to-end tests:
79-
- [apify-cli](https://docs.apify.com/cli/docs/installation) correctly installed
80-
- `apify-cli` available in `PATH` environment variable
81-
- Your [apify token](https://docs.apify.com/platform/integrations/api#api-token) is available in `APIFY_TEST_USER_API_TOKEN` environment variable
95+
Prerequisites:
96+
97+
- [apify-cli](https://docs.apify.com/cli/docs/installation) installed and available in `PATH`
98+
- Set `APIFY_TEST_USER_API_TOKEN` to your [Apify API token](https://docs.apify.com/platform/integrations/api#api-token)
8299

83100
To run end-to-end tests:
84101

@@ -90,7 +107,7 @@ uv run poe e2e-templates-tests
90107

91108
We follow the [Google docstring format](https://sphinxcontrib-napoleon.readthedocs.io/en/latest/example_google.html) for code documentation. All user-facing classes and functions must be documented. Documentation standards are enforced using [Ruff](https://docs.astral.sh/ruff/).
92109

93-
Our API documentation is generated from these docstrings using [pydoc-markdown](https://pypi.org/project/pydoc-markdown/) with custom post-processing. Additional content is provided through markdown files in the `docs/` directory. The final documentation is rendered using [Docusaurus](https://docusaurus.io/) and published to GitHub pages.
110+
Our API documentation is generated from these docstrings using [pydoc-markdown](https://pypi.org/project/pydoc-markdown/) with custom post-processing. Additional content is provided through markdown files in the `docs/` directory. The final documentation is rendered using [Docusaurus](https://docusaurus.io/) and published to GitHub Pages.
94111

95112
To run the documentation locally, ensure you have `Node.js` 20+ installed, then run:
96113

@@ -120,14 +137,14 @@ name = "crawlee"
120137
version = "x.z.y"
121138
```
122139

123-
4. Generate the distribution archives for the package:
140+
4. Build the package:
124141

125-
```shell
126-
uv build
142+
```sh
143+
uv run poe build
127144
```
128145

129-
5. Set up the PyPI API token for authentication and upload the package to PyPI:
146+
5. Upload to PyPI:
130147

131-
```shell
148+
```sh
132149
uv publish --token YOUR_API_TOKEN
133150
```

0 commit comments

Comments
 (0)