Common Python Utility and Client Tools
Project description
ravi-python-clients
Assortment of python client for personal or business use
Current Facilities
- Logger with unique identifier per session
Windows Installation
py -m venv venv
source venv\Scripts\activate
py -m pip install python-prakashravip1
Linux/ Mac Installation
python -m venv venv
source venv/bin/activate
pip install python-prakashravip1
Example
Delta Lake Write client
- Create/Delete Delta Lake Database
from src.delta_lake.delta_lake_spark import create_database, delete_database
DB_NAME = "food_db"
create_database(DB_NAME)
delete_database(DB_NAME)
- Create Delta Lake Table
from src.delta_lake.delta_lake_spark import create_database, create_table_with_schema
DB_NAME = "food_db"
TABLE_NAME = "indian_food"
create_database(DB_NAME)
create_table_with_schema(db=DB_NAME, table=TABLE_NAME,
schema=[("food_type", "STRING"), ("name", "STRING"), ("price", "FLOAT")],
partition_cols=["food_type"])
Logging
from utils.logger import logger
logger.info("test info log")
from utils.trace_logger import get_trace_logger
test_trace_id = "1234"
logger = get_trace_logger(test_trace_id)
logger.info(f"test info log with trace_id. {test_trace_id}")
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file python-prakashravip1-1.0.4.tar.gz.
File metadata
- Download URL: python-prakashravip1-1.0.4.tar.gz
- Upload date:
- Size: 8.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.9.7 Linux/5.13.0-44-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a6853858a1540945fabc4f48767c21c3079b17152c5491813586efd1d964f67f
|
|
| MD5 |
8ad1d23704c4a0e1657a2af1afb7f3dd
|
|
| BLAKE2b-256 |
ffcdc70cc17058825c98450dbd1148b8345c0985b088e3c45a4918e73b0451ea
|
File details
Details for the file python_prakashravip1-1.0.4-py3-none-any.whl.
File metadata
- Download URL: python_prakashravip1-1.0.4-py3-none-any.whl
- Upload date:
- Size: 9.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.9.7 Linux/5.13.0-44-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d4abdacc55618c1159fbae361778901db45ee106b659f1bffd53676ff14ff8c4
|
|
| MD5 |
446d2c8c36801f2e9423112975a26b07
|
|
| BLAKE2b-256 |
ba044ab1b3e67e2697801a95c5c7b704451be41d7bd7b7b1e12165e90a04d01c
|