semvec/pypi-packages huggingface dataset:
columnify 1.0.1
To create text-based columnized (ls-like) content suitable for console output from a list of strings
Requires Python: >=3.10

# columnify

Inspired by [columnify](https://github.com/timoxley/columnify).

`columnify` creates text-based columnized (ls-like) content suitable for console output from list of strings.

Columns are automatically resized to fit the content of the largest cell. Each cell will be padded with spaces to fill the available space and ensure column contents are aligned.

**Table of Contents**

- [Examples](#examples)
- [Installation](#installation)
- [API](#api)
  - [Methods](#methods)
- [License](#license)

## Examples

```py
items: list[str] = [
    "Canidae", "Felidae", "Cat", "Cattle", "Dog",
    "Donkey", "Goat", "Guinea pig", "Horse", "Pig",
    "Rabbit", "Fancy rat varieties", "laboratory rat strains",
]
```

### Default

```text
Canidae  Cat     Dog     Goat        Horse  Rabbit               laboratory rat strains
Felidae  Cattle  Donkey  Guinea pig  Pig    Fancy rat varieties
```

### Horizon first

```text
Canidae     Felidae  Cat  Cattle  Dog                  Donkey                  Goat
Guinea pig  Horse    Pig  Rabbit  Fancy rat varieties  laboratory rat strains
```

### center()

```text
Canidae   Cat     Dog       Goat     Horse         Rabbit        laboratory rat strains
Felidae  Cattle  Donkey  Guinea pig   Pig   Fancy rat varieties
```

### rjust()

```text
Canidae     Cat     Dog        Goat  Horse               Rabbit  laboratory rat strains
Felidae  Cattle  Donkey  Guinea pig    Pig  Fancy rat varieties
```

### Custom delimiter ( | )

```text
Canidae | Cattle | Goat       | Pig                 | laboratory rat strains
Felidae | Dog    | Guinea pig | Rabbit
Cat     | Donkey | Horse      | Fancy rat varieties
```

### Indent (4 spaces):

```text
    Canidae  Cattle  Goat        Pig                  laboratory rat strains
    Felidae  Dog     Guinea pig  Rabbit
    Cat      Donkey  Horse       Fancy rat varieties
```

See `examples/example.py` for more information.

## Installation

```console
pip install columnify
```

## API

### Methods

```py
def columnify(
        items: list[str],
        line_width: int,
        indent: int = 0,
        delimiter: str = '  ',
        align_func_name: str = 'ljust',
        horizon_first: bool = False) -> str:
    ...
```

## License

`columnify` is distributed under the terms of the [MPL-2.0](https://spdx.org/licenses/MPL-2.0.html) license.
extendedjson 0.1.3
Easily extend JSON to encode and decode arbitrary Python objects.
Requires Python: >=3.8,<4.0

# extendedjson

Easily extend JSON to encode and decode arbitrary Python objects.


## Getting started

You can [get `extendedjson` from PyPI](https://pypi.org/project/extendedjson),
which means it's easily installable with `pip`:

```bash
python -m pip install extendedjson
```


## Example usage

Suppose you want to extend the JSON format to handle complex numbers,
which corresponds to the type `complex` in Python.

To do that, you need to:

 1. Determine how a complex number could look like as a JSON dictionary.
 For example, a dictionary with keys `"real"` and `"imag"` is enough to determine what complex number we are talking about.
 2. Subclass `ExtendedEncoder` and implement the method `encode_complex` that accepts a complex number and returns a dictionary with the format you defined.
 3. Subclass `ExtendedDecoder` and implement a method `decode_complex` that accepts a dictionary with the format you described and returns an instance of a `complex` number.

Here is the code:

```py
import extendedjson as xjson


class MyEncoder(xjson.ExtendedEncoder):
    def encode_complex(self, c):
        return {"real": c.real, "imag": c.imag}


class MyDecoder(xjson.ExtendedDecoder):
    def decode_complex(self, dict_):
        return complex(dict_["real"], dict_["imag"])
```

Then, you can use your classes with the standard module `json`,
by specifying the `cls` keyword argument in the functions `json.load`, `json.loads`, `json.dump`, and `json.dumps`:

```py
import json

c = complex(1, 2)
c_json = json.dumps(c, cls=MyEncoder)
c_ = json.loads(c_json, cls=MyDecoder)
print(c_)  # (1+2j)
print(c_ == c)  # True
```

Refer to [this article](https://mathspp.com/blog/custom-json-encoder-and-decoder) to learn more about the internal details of `extendedjson`.


## Changelog

Refer to the [CHANGELOG.md](CHANGELOG.md) file.
django-workflow-engine 0.0.21
Lightweight, reusable workflow engine for Django applications
Requires Python: >=3.6

# django-workflow-engine
`django-workflow` is a lightweight and reusable workflow engine for 
Django applications. It enables you to better organise the business logic for 
collaborating users.

## Installation

    pip install django-workflow-engine

## Getting started
Add the application to your Django settings `INSTALLED_APPS` list:

```python
INSTALLED_APPS = [
    ...
    "django_workflow_engine",
]
```

Add the built-in `django-workflow-engine` view urls to your project's `urls.
py` as 
follows:


```python
from django_workflow_engine import workflow_urls
...
urlpatterns = [
    path("workflow/", workflow_urls()),
    ...
]
```

This will utilise all `django-workflow-engine` built-in view classes. Default views are:
- `list_view=FlowListView` List of workflow instances view.
- `view=FlowView` Workflow instance view.
- `create_view=FlowCreateView` Create workflow view.
- `continue_view=FlowContinueView` Workflow continuation view.
- `diagram_view=FlowDiagramView` Workflow diagram view.

You can override any the built-in view classes with your own, for example to
provide your own view classes for flow list and flow view:

```python
urlpatterns = [
        path("workflow/", 
             workflow_urls(
                 list_view=MyFlowListView,
                 view=MyFlowView,
            ),
        ),
    ]
```

## Building your first workflow

Create a `workflows.py` in your project and add your uniquely named workflows.

```python
from django_workflow_engine import Step, Workflow

onboard_contractor = Workflow(
    name="onboard_contractor",
    steps=[
        Step(...),
        Step(...),
        Step(...),
    ],
)

onboard_perm = Workflow(
    name="onboard_perm",
    steps=[
        ...
    ],
)
```

Add you workflows to your Django settings as follows:

```python
DJANGO_WORKFLOWS = {
    "onboard_contractor": "your_app.workflows.onboard_contractor",
    "onboard_perm": "your_app.workflows.onboard_perm",
}
```

Each entry needs to be a valid module path where the final component is the 
name of your workflow class.  

Finally, run the `django-workflow-engine` migrations:

```bash
$ ./manage.py migrate
```

## Publishing

1. `python setup.py sdist`
2. `twine upload dist/*`

## Dependencies

## Settings

## Running tests