Name | clickpy-client JSON |
Version |
0.1.6
JSON |
| download |
home_page | None |
Summary | Client for clickpy.clickhouse.com database |
upload_time | 2024-12-19 21:29:48 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.9 |
license | MIT |
keywords |
rocshers
pypi
clickhouse
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# clickpy-client
Client for [clickpy.clickhouse.com](https://clickpy.clickhouse.com) database.
[![PyPI](https://img.shields.io/pypi/v/clickpy-client)](https://pypi.org/project/clickpy-client/)
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/clickpy-client)](https://pypi.org/project/clickpy-client/)
[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=rocshers_clickpy-client&metric=coverage)](https://sonarcloud.io/summary/new_code?id=rocshers_clickpy-client)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=rocshers_clickpy-client&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=rocshers_clickpy-client)
[![Downloads](https://pypi.rocshers.com/badges/svg/packages/clickpy-client/downloads/total)](https://clickpy.clickhouse.com/dashboard/clickpy-client)
[![GitLab stars](https://img.shields.io/gitlab/stars/rocshers/python/clickpy-client)](https://gitlab.com/rocshers/python/clickpy-client)
[![GitLab last commit](https://img.shields.io/gitlab/last-commit/rocshers/python/clickpy-client)](https://gitlab.com/rocshers/python/clickpy-client)
## Quick start
```bash
pip install clickpy-client
```
```python
import asyncio
from clickpy import ClickPyClient
async def main():
clickpy = ClickPyClient()
tables = await clickpy.get_tables()
for table in tables:
print(f'Database: {table.database}; table: {table.name} rows: {table.total_rows}')
keywords = await clickpy.get_keywords_by_releases()
for keyword in keywords:
print(f'Database: {keyword.name}; releases: {keyword.releases}')
asyncio.run(main())
```
## Config
The client uses a public connection. But if you have your own DB instance with a similar structure, you can override the access parameters via environment variables.
```bash
CLICKPY_HOST='https://clickpy-clickhouse.clickhouse.com'
CLICKPY_SECURE=True
CLICKPY_USERNAME='play'
CLICKPY_PASSWORD=''
```
## Client Methods
### get_tables
Get all tables in `github` and `pypi` databases.
### get_keywords_by_releases
Get all keywords based on project description. Sorted by number of releases.
## Contribute
Issue Tracker: <https://gitlab.com/rocshers/python/clickpy-client/-/issues>
Source Code: <https://gitlab.com/rocshers/python/clickpy-client>
Before adding changes:
```bash
make install-dev
```
After changes:
```bash
make format test
```
Raw data
{
"_id": null,
"home_page": null,
"name": "clickpy-client",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": null,
"keywords": "rocshers, pypi, clickhouse",
"author": null,
"author_email": "Aleksei Marusich <aleksei.marusich@rocshers.com>",
"download_url": "https://files.pythonhosted.org/packages/40/85/d7dea3fba38714a7c0543ddaa2dc8338df92087414acf2eaa48d9d1f18a2/clickpy_client-0.1.6.tar.gz",
"platform": null,
"description": "# clickpy-client\n\nClient for [clickpy.clickhouse.com](https://clickpy.clickhouse.com) database.\n\n[![PyPI](https://img.shields.io/pypi/v/clickpy-client)](https://pypi.org/project/clickpy-client/)\n[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/clickpy-client)](https://pypi.org/project/clickpy-client/)\n\n[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=rocshers_clickpy-client&metric=coverage)](https://sonarcloud.io/summary/new_code?id=rocshers_clickpy-client)\n[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=rocshers_clickpy-client&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=rocshers_clickpy-client)\n\n[![Downloads](https://pypi.rocshers.com/badges/svg/packages/clickpy-client/downloads/total)](https://clickpy.clickhouse.com/dashboard/clickpy-client)\n[![GitLab stars](https://img.shields.io/gitlab/stars/rocshers/python/clickpy-client)](https://gitlab.com/rocshers/python/clickpy-client)\n[![GitLab last commit](https://img.shields.io/gitlab/last-commit/rocshers/python/clickpy-client)](https://gitlab.com/rocshers/python/clickpy-client)\n\n## Quick start\n\n```bash\npip install clickpy-client\n```\n\n```python\nimport asyncio\n\nfrom clickpy import ClickPyClient\n\n\nasync def main():\n clickpy = ClickPyClient()\n\n tables = await clickpy.get_tables()\n for table in tables:\n print(f'Database: {table.database}; table: {table.name} rows: {table.total_rows}')\n\n keywords = await clickpy.get_keywords_by_releases()\n for keyword in keywords:\n print(f'Database: {keyword.name}; releases: {keyword.releases}')\n\n\nasyncio.run(main())\n```\n\n## Config\n\nThe client uses a public connection. But if you have your own DB instance with a similar structure, you can override the access parameters via environment variables.\n\n```bash\nCLICKPY_HOST='https://clickpy-clickhouse.clickhouse.com'\nCLICKPY_SECURE=True\nCLICKPY_USERNAME='play'\nCLICKPY_PASSWORD=''\n```\n\n## Client Methods\n\n### get_tables\n\nGet all tables in `github` and `pypi` databases.\n\n### get_keywords_by_releases\n\nGet all keywords based on project description. Sorted by number of releases.\n\n## Contribute\n\nIssue Tracker: <https://gitlab.com/rocshers/python/clickpy-client/-/issues> \nSource Code: <https://gitlab.com/rocshers/python/clickpy-client>\n\nBefore adding changes:\n\n```bash\nmake install-dev\n```\n\nAfter changes:\n\n```bash\nmake format test\n```\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Client for clickpy.clickhouse.com database",
"version": "0.1.6",
"project_urls": null,
"split_keywords": [
"rocshers",
" pypi",
" clickhouse"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "2ecec98e7affde94bba4b3e5cca81ec2a502b1cba945c9f494abac834439c0bc",
"md5": "481568101cb2109f287ba16102aa8ccb",
"sha256": "8dc679e871378fb657408ad696eec4dcf7e27a75b44647474900fe5f70040c85"
},
"downloads": -1,
"filename": "clickpy_client-0.1.6-py3-none-any.whl",
"has_sig": false,
"md5_digest": "481568101cb2109f287ba16102aa8ccb",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 4217,
"upload_time": "2024-12-19T21:29:46",
"upload_time_iso_8601": "2024-12-19T21:29:46.534599Z",
"url": "https://files.pythonhosted.org/packages/2e/ce/c98e7affde94bba4b3e5cca81ec2a502b1cba945c9f494abac834439c0bc/clickpy_client-0.1.6-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "4085d7dea3fba38714a7c0543ddaa2dc8338df92087414acf2eaa48d9d1f18a2",
"md5": "eadd516a222aaaa3a8595a0e89eadf75",
"sha256": "cbb045a01606b26a82b245205cfccc31b4b5956e631506b120c85678b1531a57"
},
"downloads": -1,
"filename": "clickpy_client-0.1.6.tar.gz",
"has_sig": false,
"md5_digest": "eadd516a222aaaa3a8595a0e89eadf75",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 4455,
"upload_time": "2024-12-19T21:29:48",
"upload_time_iso_8601": "2024-12-19T21:29:48.850773Z",
"url": "https://files.pythonhosted.org/packages/40/85/d7dea3fba38714a7c0543ddaa2dc8338df92087414acf2eaa48d9d1f18a2/clickpy_client-0.1.6.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-19 21:29:48",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "clickpy-client"
}