Skip to content

Commit

Permalink
Docs revamp (#13)
Browse files Browse the repository at this point in the history
* fix typo

* docs revamp

* index page update

* clean up method implementations
  • Loading branch information
dominictarro authored Jun 19, 2023
1 parent d6e9888 commit 5793896
Show file tree
Hide file tree
Showing 10 changed files with 79 additions and 150 deletions.
6 changes: 5 additions & 1 deletion docs/batch_task.md → docs/concurrency.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# BatchTask
# Concurrency

Module for advanced concurrency control.

## BatchTask

::: src.prefecto.concurrency.BatchTask
options:
Expand Down
16 changes: 16 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,3 +62,19 @@ def flow():
df = csv_task(df)
return df
```

## Extras

Prefecto includes a number of extras that are not installed by default.

| Extra | Description |
| --- | --- |
| `pandas` | Adds support for [`pandas.DataFrame`](./serializers/pandas.md) serialization. |
| `polars` | Adds support for [`polars.DataFrame`](./serializers/polars.md) serialization. |
| `moto` | Adds support for mocking AWS's `boto3` with `moto` |

Extras can be installed with

```bash
pip install prefecto[extra]
```
22 changes: 22 additions & 0 deletions docs/serializers/pandas.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Pandas

## PandasSerializer

Type: `pandas`

::: src.prefecto.serializers.pandas.PandasSerializer

## Methods

`Method` classes for serializing `pandas.DataFrame`.

| Discriminator | Default Read | Default Write |
| --- | --- | --- |
| `pandas.csv` | `{"index": False}` | `{"index": False}` |
| `pandas.excel` | None | None |
| `pandas.feather` | None | None |
| `pandas.json` | None | None |
| `pandas.jsonl` | None | None |
| `pandas.parquet` | None | None |
| `pandas.pickle` | None | None |
| `pandas.tsv` | `{"sep": "\t", "index": False}` | `{"sep": "\t", "index": False}` |
67 changes: 0 additions & 67 deletions docs/serializers/pandas/methods.md

This file was deleted.

7 changes: 0 additions & 7 deletions docs/serializers/pandas/pandas_serializer.md

This file was deleted.

22 changes: 22 additions & 0 deletions docs/serializers/polars.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Polars

Serialization module for for the `polars.DataFrame` type.

## PolarsSerializer

Type: `polars`

::: src.prefecto.serializers.polars.PolarsSerializer

## Methods

`Method` classes for serializing `polars.DataFrame`.

| Discriminator | Default Read | Default Write |
| --- | --- | --- |
| `polars.csv` | None | None |
| `polars.excel` | None | None |
| `polars.json` | None | None |
| `polars.ndjson` | None | None |
| `polars.parquet` | None | None |
| `polars.tsv` | `{"separator": "\t"}` | `{"separator": "\t"}` |
51 changes: 0 additions & 51 deletions docs/serializers/polars/methods.md

This file was deleted.

7 changes: 0 additions & 7 deletions docs/serializers/polars/polars_serializer.md

This file was deleted.

29 changes: 13 additions & 16 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,20 @@ repo_url: https://github.com/dominictarro/prefecto
theme: readthedocs

nav:
- Home: index.md
- "Concurrency":
- batch_task.md
- "File Systems": filesystems.md
- "Serialization":
- serializers/extended_serializer.md
- serializers/method.md
- serializers/functions.md
- "Pandas":
- serializers/pandas/pandas_serializer.md
- serializers/pandas/methods.md
- "Polars":
- serializers/polars/polars_serializer.md
- serializers/polars/methods.md
- "Testing":
- testing/s3.md
- "Home": index.md
- "License": license.md
- "Reference":
- "Concurrency": concurrency.md
- "File Systems": filesystems.md
- "Serialization":
- serializers/extended_serializer.md
- serializers/method.md
- serializers/functions.md
- "Custom Serializers":
- "Pandas": serializers/pandas.md
- "Polars": serializers/polars.md
- "Testing":
- testing/s3.md

plugins:
- search:
Expand Down
2 changes: 1 addition & 1 deletion src/prefecto/concurrency.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""
Tools to improve Prefect concurrently.
Tools to improve Prefect concurrency.
"""
from __future__ import annotations
Expand Down

0 comments on commit 5793896

Please sign in to comment.