semvec/pypi-packages huggingface dataset:
tree-sitter-surrealql 0.2.0
SurrealQL grammar for tree-sitter
License: MIT
Requires Python: >=3.8
Keywords: incremental, parsing, tree-sitter, surrealql

# tree-sitter-surrealql

[![CI][ci]](https://github.com/ce11an/tree-sitter-surrealql/actions/workflows/ci.yml)
[![crates][crates]](https://crates.io/crates/tree-sitter-surrealql)
[![pypi][pypi]](https://pypi.org/project/tree-sitter-surrealql/)

SurrealQL grammar for [tree-sitter][].

## Installation

### [cargo](https://crates.io/crates/tree-sitter-surrealql)

```sh
cargo add tree-sitter-surrealql
```

### [pip](https://pypi.org/project/tree-sitter-surrealql)

```bash
pip install tree-sitter-surrealql
```

## Features
Please check the [examples](examples) directory for a complete list of features.

## References
- [SurrealDB](https://surrealdb.com/docs/surrealdb)

[ci]: https://img.shields.io/github/actions/workflow/status/ce11an/tree-sitter-surrealql/ci.yml?logo=github&label=CI
[tree-sitter]: https://github.com/tree-sitter/tree-sitter
[crates]: https://img.shields.io/crates/v/tree-sitter-surrealql?logo=rust
[pypi]: https://img.shields.io/pypi/v/tree-sitter-surrealql?logo=pypi&logoColor=ffd242
django-fields-history 0.1.7
Store model fields history
License: MIT
Requires Python: <4.0,>=3.6
Keywords: django, fields, history

# django-fields-history

[![PyPI version](https://badge.fury.io/py/django-fields-history.svg)](https://badge.fury.io/py/django-fields-history)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)

A Django app that track history changes in model fields.

__Important note__: currently only one implementation of `FieldsHistory`
is supported and it's with `django.contrib.postgres.fields.JSONField`
which is [`JSONB`](https://www.postgresql.org/docs/9.4/datatype-json.html)
under the hood. So only _postgresql_ as database is supported

Similar projects:

 * [django-reversion](https://github.com/etianen/django-reversion)
 * [django-simple-history](https://github.com/treyhunner/django-simple-history)
 * [django-field-history](https://github.com/grantmcconnaughey/django-field-history)

Main difference that those libraries keep track of changes, and this library
tracks the history change.

Simple explanation:

```python
from field_history.trackers import FieldsHistoryTracker

class SimpleModel(models.Model):
    field = models.CharField(max_length=50)

    field_history = FieldsHistoryTracker(fields=['field'])

obj = SimpleModel.objects.create(field='value')
assert not obj.get_field_history()


obj.field = "new_value"
obj.save()
assert obj.get_field_history()
assert obj.get_field_history()[0].value == "value"
```


## QuickStart

Install `django-fields-history`:

```bash
pip install django-fields-history
```

Add `fields_history.postgres` to `INSTALLED_APPS` (currently only
postgres implementation is supported):

```python
INSTALLED_APPS = [
    # rest of apps
    "fields_history.postgres",
]
```

And add trackers to your models and specify fields to track:

```python
from field_history.trackers import FieldsHistoryTracker

class YourModel(models.Model):
    ...

    history_tracker = FieldsHistoryTracker(fields=["field1", "field2"])
```

And you are done.


## Implementation

Every change of your fields field changes be tracked in
`fields_history.models.FieldsHistory` in:

 * `fields_history.postgres` - `JSONB` postgres field

One object per save if tracked fields has been changed.


## Credits

Basically this project is implemented based on
[django-field-history](https://github.com/grantmcconnaughey/django-field-history)
which itself used [django-model-utils](https://github.com/jazzband/django-model-utils).
flake8-all-not-strings 0.0.3
flake8 plugin which checks that modules under `__all__` are defined as strings
License: MIT

# flake8-all-not-strings
![PyPI data-understand](https://img.shields.io/pypi/v/flake8-all-not-strings)
![MIT license](https://img.shields.io/badge/License-MIT-blue.svg)
![versions](https://img.shields.io/pypi/pyversions/flake8-all-not-strings)
![Downloads](https://static.pepy.tech/badge/flake8-all-not-strings)

[![Python Linting](https://github.com/ggupta2005/flake8-all-not-strings/actions/workflows/python-linting.yml/badge.svg)](https://github.com/ggupta2005/flake8-all-not-strings/actions/workflows/python-linting.yml)
[![Run Python Unit Tests](https://github.com/ggupta2005/flake8-all-not-strings/actions/workflows/python-unit-tests.yml/badge.svg)](https://github.com/ggupta2005/flake8-all-not-strings/actions/workflows/python-unit-tests.yml)

[![CodeFactor](https://www.codefactor.io/repository/github/ggupta2005/flake8-all-not-strings/badge)](https://www.codefactor.io/repository/github/ggupta2005/flake8-all-not-strings)

Flake8 plugin that checks that the all the elements defined in the `__all__` list are strings. Sometimes the flake8 doesn't throw error from the `__init__.py` if the modules under `__all__` are not strings.

Example below of an `__init__.py` file which should throw an error:-
```
from some_module import some_function 
__all__ = [
      some_function
]
```

Example below of an `__init__.py` file which should not throw an error:-
```
from some_module import some_function 
__all__ = [
      'some_function'
]
```

## Installation
```
pip install flake8-all-not-strings
```

## Flake8 codes
| Code | description |
|----------|----------|
| ANS100 | '<<some_module_name>>' import under __all__ is not a string. |

## Testing
In order to run unit tests under the `tests/` directory you can do the following steps:-

### Install editable version of `flake8-all-not-strings` from the top level directory
```
pip install -e .
```

### Install `pytest`
```
pip install pytest
```

### Run tests
Change to `tests/` directory and run tests using `pytest`
```
cd tests/
pytest
```