pychrdb


Namepychrdb JSON
Version 1.2.1 PyPI version JSON
download
home_pageNone
SummaryImproved and easy-to-use version of builtin Python's JSON
upload_time2024-03-21 14:54:11
maintainerNone
docs_urlNone
authordas Alex
requires_python>=3.8
licenseMIT
keywords chrdb pychrdb database json
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            Chroma Database (ChrDB)
=======
Improved and easy-to-use version of builtin Python's JSON

Key Features
------------

- Simple and easy-to-use syntax.
- It is based on ujson, instead of default json, which speeds up the database.
- You can use dots in the key arguments to search in child dictionaries.

Installing
----------

**Python 3.8 or higher is required.**

```sh
# Linux/macOS
python3 -m pip install pychrdb

# Windows
py -3 -m pip install pychrdb
```

Usage
-----

Print full database to the console:
```py
from chrdb import ChrDB

database = ChrDB("database.json")
print(database.full())
```

Get the key from the database:
```py
from chrdb import ChrDB

database = ChrDB("database.json")
database.find("key")
```

Update key value in the database:
```py
from chrdb import ChrDB

database = ChrDB("database.json")
database.update(key="key", value="Hello, World!")
```

Update full database (value must be `dict`):
```py
from chrdb import ChrDB

database = ChrDB("database.json")
database.update(key=None, value={"key": "Hello, World!"})
```

Delete key from the database:
```py
from chrdb import ChrDB

database = ChrDB("database.json")
database.delete("key")
```

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "pychrdb",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "chrdb, pychrdb, database, json",
    "author": "das Alex",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/f8/15/a3515e945da45e9966c58c3fa05ae9799e2f1cb91ce6e009ecbf21669484/pychrdb-1.2.1.tar.gz",
    "platform": null,
    "description": "Chroma Database (ChrDB)\r\n=======\r\nImproved and easy-to-use version of builtin Python's JSON\r\n\r\nKey Features\r\n------------\r\n\r\n- Simple and easy-to-use syntax.\r\n- It is based on ujson, instead of default json, which speeds up the database.\r\n- You can use dots in the key arguments to search in child dictionaries.\r\n\r\nInstalling\r\n----------\r\n\r\n**Python 3.8 or higher is required.**\r\n\r\n```sh\r\n# Linux/macOS\r\npython3 -m pip install pychrdb\r\n\r\n# Windows\r\npy -3 -m pip install pychrdb\r\n```\r\n\r\nUsage\r\n-----\r\n\r\nPrint full database to the console:\r\n```py\r\nfrom chrdb import ChrDB\r\n\r\ndatabase = ChrDB(\"database.json\")\r\nprint(database.full())\r\n```\r\n\r\nGet the key from the database:\r\n```py\r\nfrom chrdb import ChrDB\r\n\r\ndatabase = ChrDB(\"database.json\")\r\ndatabase.find(\"key\")\r\n```\r\n\r\nUpdate key value in the database:\r\n```py\r\nfrom chrdb import ChrDB\r\n\r\ndatabase = ChrDB(\"database.json\")\r\ndatabase.update(key=\"key\", value=\"Hello, World!\")\r\n```\r\n\r\nUpdate full database (value must be `dict`):\r\n```py\r\nfrom chrdb import ChrDB\r\n\r\ndatabase = ChrDB(\"database.json\")\r\ndatabase.update(key=None, value={\"key\": \"Hello, World!\"})\r\n```\r\n\r\nDelete key from the database:\r\n```py\r\nfrom chrdb import ChrDB\r\n\r\ndatabase = ChrDB(\"database.json\")\r\ndatabase.delete(\"key\")\r\n```\r\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Improved and easy-to-use version of builtin Python's JSON",
    "version": "1.2.1",
    "project_urls": {
        "Repository": "https://github.com/dasalexua/pychrdb"
    },
    "split_keywords": [
        "chrdb",
        " pychrdb",
        " database",
        " json"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "83859bea9d77cb2d18ce2401acd38adaf269e63a4b3bb40316aca9d2b4044b3d",
                "md5": "ff7d28553054205ba80c0c9a44c24366",
                "sha256": "c9055868934299747ad38f866e4854d6dac28c0d185982a3f482f6c0e3fa0efe"
            },
            "downloads": -1,
            "filename": "pychrdb-1.2.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ff7d28553054205ba80c0c9a44c24366",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 4609,
            "upload_time": "2024-03-21T14:54:09",
            "upload_time_iso_8601": "2024-03-21T14:54:09.882874Z",
            "url": "https://files.pythonhosted.org/packages/83/85/9bea9d77cb2d18ce2401acd38adaf269e63a4b3bb40316aca9d2b4044b3d/pychrdb-1.2.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f815a3515e945da45e9966c58c3fa05ae9799e2f1cb91ce6e009ecbf21669484",
                "md5": "45d5509f9cbe47e8b351e56f5ec1af9d",
                "sha256": "b4b826aea7658ae15fae88375cfb0847f293979cddcee7fc625d4d67808e9a71"
            },
            "downloads": -1,
            "filename": "pychrdb-1.2.1.tar.gz",
            "has_sig": false,
            "md5_digest": "45d5509f9cbe47e8b351e56f5ec1af9d",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 4190,
            "upload_time": "2024-03-21T14:54:11",
            "upload_time_iso_8601": "2024-03-21T14:54:11.017758Z",
            "url": "https://files.pythonhosted.org/packages/f8/15/a3515e945da45e9966c58c3fa05ae9799e2f1cb91ce6e009ecbf21669484/pychrdb-1.2.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-21 14:54:11",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "dasalexua",
    "github_project": "pychrdb",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "pychrdb"
}
        
Elapsed time: 0.19136s