Metadata-Version: 2.1
Name: lapa_database
Version: 0.0.9
Summary: database layer for my personal server.
Home-page: https://github.com/thepmsquare/lapa_database
Author: thePmSquare, Amish Palkar, Lav Sharma, Aaditya Sangsihetty
Author-email: thepmsquare@gmail.com, amishpalkar302001@gmail.com, lavsharma2016@gmail.com, adityashetty35@gmail.com
License: UNKNOWN
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Description-Content-Type: text/markdown
Provides-Extra: all

# lapa_database

## about

database layer for my personal server.

## installation

> pip install lapa_database[all]

## usage (WIP)

### change password in config.ini.

### CREATE_SCHEMA = True to create database from scratch.

### LOG_FILE_NAME and configure logger

### link to lapa_database_structure

## configs

1. lapa_database\data\config.ini
2. lapa_logger\data\config.ini

## env

- python>=3.12.0

## changelog

### v0.0.9

- removed config.example.ini.
- bug fix: create_database -> data insertion now takes schema into account.

### v0.0.8

- add module name in config.
- add first test case.
- add dependencies for testing.
- add GitHub workflow for testing.
- remove config from gitignore.

### v0.0.7

- use lapa_commons to read config.

### v0.0.6

- change default value of ignore_filters_and_get_all to False.

### v0.0.5

- make crud logic default to no rows when filters are empty.
- add new parameters to make it easy to select all rows for edit, delete and get.
- move logger to configuration.py to fix bug of multiple logs being created.

### v0.0.4

- rename to lapa database.
- fix bug in create_database that occurred in default data insertion.
- add logs to gitignore.
- change psycopg2 to psycopg2-binary in setup.py.

### v0.0.3

- created utils folder containing CommonOperations.py under which the common functions used across modules are stored.
- web_socket implemented for retrieving the data from the table when a new row is added/deleted/updated.
    - it takes database_name, table_name and schema_name as input through query params.
    - input for websocket
        - /ws/<database_name>/<table_name>/<schema_name>
            - E.g. /ws/game/player/public
    - initially returns all the rows and if any update is made it returns the updated data.
    - trigger creation is implemented once the websocket connection is made. it will first check if the trigger function
      already exists or not and then only create.

### v0.0.2

- remove databases folder and enums related to tables and put in separate module for better version control.
- add proper error message display on errors in configuration.py.
- known bugs:
    - creating engines everytime on fastapi route call is creating idle sessions.

### v0.0.1

- initial implementation.
- known bugs:
    - creating engines everytime on fastapi route call is creating idle sessions.

## Feedback is appreciated. Thank you!


