From 844ef6445094494695ed5c98c30b6227b964c81c Mon Sep 17 00:00:00 2001 From: devsetgo Date: Thu, 1 Aug 2024 20:18:06 +0000 Subject: [PATCH 01/11] adding doc deployment to package deployment action --- .github/workflows/build_mkdocs.yml | 147 ++++++++++++++-------------- .github/workflows/pythonpublish.yml | 55 +++++++++++ 2 files changed, 129 insertions(+), 73 deletions(-) diff --git a/.github/workflows/build_mkdocs.yml b/.github/workflows/build_mkdocs.yml index 62b35884..05b39d84 100644 --- a/.github/workflows/build_mkdocs.yml +++ b/.github/workflows/build_mkdocs.yml @@ -1,89 +1,90 @@ -name: Publish docs via GitHub Pages - -on: - push: - branches: - - main - workflow_dispatch: - -jobs: - build: - name: Deploy docs - runs-on: ubuntu-latest - - steps: - - name: Checkout main - uses: actions/checkout@v2 - - - name: Set up Python - uses: actions/setup-python@v2 - with: - python-version: '3.x' +# name: Publish docs via GitHub Pages - - name: Install dependencies - run: | - python -m pip install --upgrade pip - pip install -r requirements.txt +# on: +# # push: +# # branches: +# # - main +# workflow_dispatch: +# release: +# types: [published] +# jobs: +# build: +# name: Deploy docs +# runs-on: ubuntu-latest - - name: Generate changelog - run: python3 scripts/changelog.py +# steps: +# - name: Checkout main +# uses: actions/checkout@v2 - - name: Build MkDocs site - run: mkdocs build +# - name: Set up Python +# uses: actions/setup-python@v2 +# with: +# python-version: '3.x' - - name: Copy README to docs/index.md - run: cp README.md docs/index.md +# - name: Install dependencies +# run: | +# python -m pip install --upgrade pip +# pip install -r requirements.txt - - name: Copy CONTRIBUTING to docs/contribute.md - run: cp CONTRIBUTING.md docs/contribute.md +# - name: Generate changelog +# run: python3 scripts/changelog.py - - name: Copy CHANGELOG to docs/release-notes.md - run: cp CHANGELOG.md docs/release-notes.md +# - name: Build MkDocs site +# run: mkdocs build - - name: Configure git - run: | - git config --global user.name "github-actions[bot]" - git config --global user.email "github-actions[bot]@users.noreply.github.com" +# - name: Copy README to docs/index.md +# run: cp README.md docs/index.md - - name: Stash changes - run: git stash --include-untracked +# - name: Copy CONTRIBUTING to docs/contribute.md +# run: cp CONTRIBUTING.md docs/contribute.md - - name: Pull latest gh-pages - run: | - git fetch origin gh-pages - git checkout gh-pages - git pull origin gh-pages - git checkout - +# - name: Copy CHANGELOG to docs/release-notes.md +# run: cp CHANGELOG.md docs/release-notes.md - - name: Apply stash - run: git stash pop +# - name: Configure git +# run: | +# git config --global user.name "github-actions[bot]" +# git config --global user.email "github-actions[bot]@users.noreply.github.com" - - name: Deploy to GitHub Pages - run: mkdocs gh-deploy --force - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +# - name: Stash changes +# run: git stash --include-untracked -# name: Publish docs via GitHub Pages -# on: -# push: -# branches: -# - main +# - name: Pull latest gh-pages +# run: | +# git fetch origin gh-pages +# git checkout gh-pages +# git pull origin gh-pages +# git checkout - -# jobs: -# build: -# name: Deploy docs -# runs-on: ubuntu-latest -# steps: -# - name: Checkout main -# uses: actions/checkout@v2 +# - name: Apply stash +# run: git stash pop -# - name: Deploy docs -# uses: mhausenblas/mkdocs-deploy-gh-pages@master -# # Or use mhausenblas/mkdocs-deploy-gh-pages@nomaterial to build without the mkdocs-material theme +# - name: Deploy to GitHub Pages +# run: mkdocs gh-deploy --force # env: # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} -# CUSTOM_DOMAIN: optionaldomain.com -# CONFIG_FILE: folder/mkdocs.yml -# EXTRA_PACKAGES: build-base -# # GITHUB_DOMAIN: github.myenterprise.com -# REQUIREMENTS: folder/requirements.txt + +# # name: Publish docs via GitHub Pages +# # on: +# # push: +# # branches: +# # - main + +# # jobs: +# # build: +# # name: Deploy docs +# # runs-on: ubuntu-latest +# # steps: +# # - name: Checkout main +# # uses: actions/checkout@v2 + +# # - name: Deploy docs +# # uses: mhausenblas/mkdocs-deploy-gh-pages@master +# # # Or use mhausenblas/mkdocs-deploy-gh-pages@nomaterial to build without the mkdocs-material theme +# # env: +# # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +# # CUSTOM_DOMAIN: optionaldomain.com +# # CONFIG_FILE: folder/mkdocs.yml +# # EXTRA_PACKAGES: build-base +# # # GITHUB_DOMAIN: github.myenterprise.com +# # REQUIREMENTS: folder/requirements.txt diff --git a/.github/workflows/pythonpublish.yml b/.github/workflows/pythonpublish.yml index cc618ac4..9f362762 100644 --- a/.github/workflows/pythonpublish.yml +++ b/.github/workflows/pythonpublish.yml @@ -24,3 +24,58 @@ jobs: run: | python -m build twine upload dist/* + build: + name: Deploy docs + runs-on: ubuntu-latest + + steps: + - name: Checkout main + uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: '3.x' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + + - name: Generate changelog + run: python3 scripts/changelog.py + + - name: Build MkDocs site + run: mkdocs build + + - name: Copy README to docs/index.md + run: cp README.md docs/index.md + + - name: Copy CONTRIBUTING to docs/contribute.md + run: cp CONTRIBUTING.md docs/contribute.md + + - name: Copy CHANGELOG to docs/release-notes.md + run: cp CHANGELOG.md docs/release-notes.md + + - name: Configure git + run: | + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" + + - name: Stash changes + run: git stash --include-untracked + + - name: Pull latest gh-pages + run: | + git fetch origin gh-pages + git checkout gh-pages + git pull origin gh-pages + git checkout - + + - name: Apply stash + run: git stash pop + + - name: Deploy to GitHub Pages + run: mkdocs gh-deploy --force + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From c613f54ab14754fe5266e6a857da0057053fb193 Mon Sep 17 00:00:00 2001 From: devsetgo Date: Tue, 13 Aug 2024 15:47:04 +0000 Subject: [PATCH 02/11] making more generic to copy to other projects. --- makefile | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/makefile b/makefile index e4c6005c..f1d79810 100644 --- a/makefile +++ b/makefile @@ -1,4 +1,6 @@ # Variables +REPONAME = PyJSONSchemaForm + PYTHON = python3 PIP = $(PYTHON) -m pip PYTEST = $(PYTHON) -m pytest @@ -42,9 +44,9 @@ cleanup: isort ruff autoflake ## Run isort, ruff, autoflake create-docs: ## Build and deploy the project's documentation python3 scripts/changelog.py mkdocs build - cp /workspaces/devsetgo_lib/README.md /workspaces/devsetgo_lib/docs/index.md - cp /workspaces/devsetgo_lib/CONTRIBUTING.md /workspaces/devsetgo_lib/docs/contribute.md - cp /workspaces/devsetgo_lib/CHANGELOG.md /workspaces/devsetgo_lib/docs/release-notes.md + cp /workspaces/$(REPONAME)/README.md /workspaces/$(REPONAME)/docs/index.md + cp /workspaces/$(REPONAME)/CONTRIBUTING.md /workspaces/$(REPONAME)/docs/contribute.md + cp /workspaces/$(REPONAME)/CHANGELOG.md /workspaces/$(REPONAME)/docs/release-notes.md mkdocs gh-deploy create-docs-local: ## Build and deploy the project's documentation @@ -82,8 +84,8 @@ speedtest: ## Run a speed test test: ## Run the project's tests pre-commit run -a pytest - sed -i 's|/workspaces/devsetgo_lib|/github/workspace|' /workspaces/devsetgo_lib/coverage.xml - genbadge coverage -i /workspaces/dsg/coverage.xml + sed -i 's|/workspaces/$(REPONAME)|/github/workspace|' /workspaces/$(REPONAME)/coverage.xml + genbadge coverage -i /workspaces/$(REPONAME)/coverage.xml flake8 --tee . > htmlcov/_flake8Report.txt #flake8 --max-doc-length=132 --tee . > htmlcov/_flake8Report.txt From 2e9321635248ecfcf734d8901f8594769645e5df Mon Sep 17 00:00:00 2001 From: devsetgo Date: Tue, 13 Aug 2024 15:47:20 +0000 Subject: [PATCH 03/11] updates --- coverage.xml | 50 ++++++++++++++++++++++- examples/log_example.py => log_example.py | 7 ++-- 2 files changed, 53 insertions(+), 4 deletions(-) rename examples/log_example.py => log_example.py (96%) diff --git a/coverage.xml b/coverage.xml index ba4ae5f7..b871cad0 100644 --- a/coverage.xml +++ b/coverage.xml @@ -1,11 +1,59 @@ - + /workspaces/devsetgo_lib + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/examples/log_example.py b/log_example.py similarity index 96% rename from examples/log_example.py rename to log_example.py index 983a555a..bb51b12b 100644 --- a/examples/log_example.py +++ b/log_example.py @@ -27,9 +27,10 @@ # app_name='my_app', # append_app_name=True, intercept_standard_logging=True, - enqueue=False, + enqueue=True, ) + # @logger.catch def div_zero(x, y): try: @@ -48,7 +49,6 @@ def div_zero_two(x, y): logging.error(f'{e}') - def log_big_string(lqty=100, size=256): big_string = secrets.token_urlsafe(size) for _ in range(lqty): @@ -75,6 +75,7 @@ def worker(wqty=1000, lqty=100, size=256): for _ in tqdm(range(wqty), ascii=True, leave=True): # Adjusted for demonstration log_big_string(lqty=lqty, size=size) + def main(wqty: int = 100, lqty: int = 10, size: int = 256, workers: int = 16, thread_test: bool = False, process_test: bool = False): if process_test: processes = [] @@ -106,5 +107,5 @@ def main(wqty: int = 100, lqty: int = 10, size: int = 256, workers: int = 16, th if __name__ == "__main__": from time import time start = time() - main(wqty=10, lqty=100, size=64, workers=16, thread_test=False, process_test=True) + main(wqty=10, lqty=100, size=64, workers=8, thread_test=False, process_test=True) print(f"Execution time: {time()-start:.2f} seconds") From e1da6c64c3589cc8220bbeba7e830d7ec5c70d25 Mon Sep 17 00:00:00 2001 From: devsetgo Date: Sun, 25 Aug 2024 22:03:29 +0000 Subject: [PATCH 04/11] adding disconnect function --- coverage-badge.svg | 2 +- coverage.xml | 4 ++-- .../async_database_functions/async_database.py | 16 ++++++++++++++++ 3 files changed, 19 insertions(+), 3 deletions(-) diff --git a/coverage-badge.svg b/coverage-badge.svg index e2abb10d..b639d978 100644 --- a/coverage-badge.svg +++ b/coverage-badge.svg @@ -1 +1 @@ -coverage: 13.25%coverage13.25% +coverage: 0.00%coverage0.00% diff --git a/coverage.xml b/coverage.xml index b871cad0..d1661adb 100644 --- a/coverage.xml +++ b/coverage.xml @@ -1,6 +1,6 @@ - - + + /workspaces/devsetgo_lib diff --git a/dsg_lib/async_database_functions/async_database.py b/dsg_lib/async_database_functions/async_database.py index 41d1b3db..25e61a62 100644 --- a/dsg_lib/async_database_functions/async_database.py +++ b/dsg_lib/async_database_functions/async_database.py @@ -120,3 +120,19 @@ async def create_tables(self): # Log the error and raise it logger.error(f"Error creating tables: {ex}") # pragma: no cover raise # pragma: no cover + + async def disconnect(self): # pragma: no cover + """ + This method asynchronously disconnects the database engine. + + Parameters: None + + Returns: None + """ + logger.debug("Disconnecting from database") + try: + await self.db_config.engine.dispose() + logger.info("Disconnected from database") + except Exception as ex: # pragma: no cover + logger.error(f"Error disconnecting from database: {ex}") # pragma: no cover + raise # pragma: no cover From 86db625c9718dab502d385c9a2a4944c326f751c Mon Sep 17 00:00:00 2001 From: devsetgo Date: Sun, 25 Aug 2024 22:10:42 +0000 Subject: [PATCH 05/11] adding the disconnect function to the example --- coverage.xml | 2 +- examples/fastapi_example.py | 113 +++++++++++++++++++----------------- 2 files changed, 60 insertions(+), 55 deletions(-) diff --git a/coverage.xml b/coverage.xml index d1661adb..9bddfdee 100644 --- a/coverage.xml +++ b/coverage.xml @@ -1,5 +1,5 @@ - + diff --git a/examples/fastapi_example.py b/examples/fastapi_example.py index 92016403..dd34e927 100644 --- a/examples/fastapi_example.py +++ b/examples/fastapi_example.py @@ -29,60 +29,6 @@ logging_config.config_log( logging_level="INFO", log_serializer=False, log_name="log.log" ) - - -@asynccontextmanager -async def lifespan(app: FastAPI): - logger.info("starting up") - # Create the tables in the database - await async_db.create_tables() - - create_users = True - if create_users: - await create_a_bunch_of_users(single_entry=2000, many_entries=20000) - yield - logger.info("shutting down") - - -# Create an instance of the FastAPI class -app = FastAPI( - title="FastAPI Example", # The title of the API - description="This is an example of a FastAPI application using the DevSetGo Toolkit.", # A brief description of the API - version="0.1.0", # The version of the API - docs_url="/docs", # The URL where the API documentation will be served - redoc_url="/redoc", # The URL where the ReDoc documentation will be served - openapi_url="/openapi.json", # The URL where the OpenAPI schema will be served - debug=True, # Enable debug mode - middleware=[], # A list of middleware to include in the application - routes=[], # A list of routes to include in the application - lifespan=lifespan, # this is the replacement for the startup and shutdown events -) - - -@app.get("/") -async def root(): - """ - Root endpoint of API - Returns: - Redrects to openapi document - """ - # redirect to openapi docs - logger.info("Redirecting to OpenAPI docs") - response = RedirectResponse(url="/docs") - return response - - -config_health = { - "enable_status_endpoint": True, - "enable_uptime_endpoint": True, - "enable_heapdump_endpoint": True, -} -app.include_router( - system_health_endpoints.create_health_router(config=config_health), - prefix="/api/health", - tags=["system-health"], -) - # Create a DBConfig instance config = { # "database_uri": "postgresql+asyncpg://postgres:postgres@postgresdb/postgres", @@ -95,6 +41,7 @@ async def root(): "pool_recycle": 3600, # "pool_timeout": 30, } + # create database configuration db_config = database_config.DBConfig(config) # Create an AsyncDatabase instance @@ -144,6 +91,64 @@ class Address(base_schema.SchemaBaseSQLite, async_db.Base): "User", back_populates="addresses" ) # Relationship to the User class +@asynccontextmanager +async def lifespan(app: FastAPI): + logger.info("starting up") + # Create the tables in the database + await async_db.create_tables() + + create_users = True + if create_users: + await create_a_bunch_of_users(single_entry=2000, many_entries=20000) + yield + logger.info("shutting down") + await async_db.disconnect() + logger.info("database disconnected") + print("That's all folks!") + + + +# Create an instance of the FastAPI class +app = FastAPI( + title="FastAPI Example", # The title of the API + description="This is an example of a FastAPI application using the DevSetGo Toolkit.", # A brief description of the API + version="0.1.0", # The version of the API + docs_url="/docs", # The URL where the API documentation will be served + redoc_url="/redoc", # The URL where the ReDoc documentation will be served + openapi_url="/openapi.json", # The URL where the OpenAPI schema will be served + debug=True, # Enable debug mode + middleware=[], # A list of middleware to include in the application + routes=[], # A list of routes to include in the application + lifespan=lifespan, # this is the replacement for the startup and shutdown events +) + + +@app.get("/") +async def root(): + """ + Root endpoint of API + Returns: + Redrects to openapi document + """ + # redirect to openapi docs + logger.info("Redirecting to OpenAPI docs") + response = RedirectResponse(url="/docs") + return response + + +config_health = { + "enable_status_endpoint": True, + "enable_uptime_endpoint": True, + "enable_heapdump_endpoint": True, +} +app.include_router( + system_health_endpoints.create_health_router(config=config_health), + prefix="/api/health", + tags=["system-health"], +) + + + async def create_a_bunch_of_users(single_entry=0, many_entries=0): logger.info(f"single_entry: {single_entry}") From 200bcd4c57880ffd9e6baa56999ce4a05ab6b387 Mon Sep 17 00:00:00 2001 From: devsetgo Date: Sun, 25 Aug 2024 22:37:17 +0000 Subject: [PATCH 06/11] move back to examples --- log_example.py => examples/log_example.py | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename log_example.py => examples/log_example.py (100%) diff --git a/log_example.py b/examples/log_example.py similarity index 100% rename from log_example.py rename to examples/log_example.py From cf905ad07e295fe292be07ac3d11d32fb135a7bb Mon Sep 17 00:00:00 2001 From: devsetgo Date: Sun, 25 Aug 2024 22:37:30 +0000 Subject: [PATCH 07/11] run of tests --- coverage.xml | 998 +++++++++++++++++++++++++-------------------------- 1 file changed, 499 insertions(+), 499 deletions(-) diff --git a/coverage.xml b/coverage.xml index 9bddfdee..cca37d20 100644 --- a/coverage.xml +++ b/coverage.xml @@ -1,5 +1,5 @@ - + @@ -64,7 +64,7 @@ - + @@ -78,7 +78,7 @@ - + @@ -89,15 +89,15 @@ - - + + - - - - - - + + + + + + @@ -142,7 +142,7 @@ - + @@ -157,21 +157,21 @@ - - - + + + - - - - + + + + - + @@ -181,219 +181,219 @@ - - - - - - - - - + + + + + + + + + - - - - - - + + + + + + - - - - - - + + + + + + - - - - - - + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - + - + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - + + + + + + + + + - + @@ -404,46 +404,46 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + @@ -457,164 +457,164 @@ - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - + + + + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - + @@ -626,50 +626,50 @@ - - - - - - - - + + + + + + + + - - - - - - - + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - - - - + + + + + + + + + + - + @@ -683,68 +683,68 @@ - - - - + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - + @@ -756,15 +756,15 @@ - + - - + + @@ -780,7 +780,7 @@ - + @@ -802,33 +802,33 @@ - - + + - - - - - - + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + From 73c21bda3b3ef283e00e1c9e4497ef53e835a8f7 Mon Sep 17 00:00:00 2001 From: devsetgo Date: Sun, 25 Aug 2024 22:38:34 +0000 Subject: [PATCH 08/11] run of tests --- coverage.xml | 50 +------------------------------------------------- 1 file changed, 1 insertion(+), 49 deletions(-) diff --git a/coverage.xml b/coverage.xml index cca37d20..fcf0d016 100644 --- a/coverage.xml +++ b/coverage.xml @@ -1,59 +1,11 @@ - + /workspaces/devsetgo_lib - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From d126a3de566cfaeaafb5f125c6ca7bd007270c4a Mon Sep 17 00:00:00 2001 From: devsetgo Date: Sun, 25 Aug 2024 22:40:07 +0000 Subject: [PATCH 09/11] bump to 0.14.1 --- .bumpversion.cfg | 2 +- dsg_lib/__init__.py | 2 +- pyproject.toml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.bumpversion.cfg b/.bumpversion.cfg index 1e9b6e05..affbf924 100644 --- a/.bumpversion.cfg +++ b/.bumpversion.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 0.14.0 +current_version = 0.14.1 commit = False tag = False parse = (?P\d+)\.(?P\d+)\.(?P\d+)(-(?P[a-z]+)(?P\d+))? diff --git a/dsg_lib/__init__.py b/dsg_lib/__init__.py index 332ad4ca..23d9338a 100644 --- a/dsg_lib/__init__.py +++ b/dsg_lib/__init__.py @@ -1,3 +1,3 @@ # -*- coding: utf-8 -*- -__version__ = "0.14.0" +__version__ = "0.14.1" diff --git a/pyproject.toml b/pyproject.toml index 7a745807..c7146f72 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -8,7 +8,7 @@ build-backend = "hatchling.build" [project] name = "devsetgo_lib" -version = "0.14.0" +version = "0.14.1" requires-python = ">=3.9" description = """ DevSetGo Library is a Python library offering reusable functions for efficient coding. It includes file operations, calendar utilities, pattern matching, advanced logging with loguru, FastAPI endpoints, async database handling, and email validation. Designed for ease of use and versatility, it's a valuable tool for Python developers. From b528c65e3e2e52def4710fc78738186d1c515eb2 Mon Sep 17 00:00:00 2001 From: devsetgo Date: Sun, 25 Aug 2024 22:43:02 +0000 Subject: [PATCH 10/11] extending the init with more details. --- coverage.xml | 1000 +++++++++++++++++++++---------------------- dsg_lib/__init__.py | 9 + 2 files changed, 509 insertions(+), 500 deletions(-) diff --git a/coverage.xml b/coverage.xml index fcf0d016..c0dc7b6d 100644 --- a/coverage.xml +++ b/coverage.xml @@ -1,5 +1,5 @@ - + @@ -11,12 +11,12 @@ - + - + @@ -30,7 +30,7 @@ - + @@ -41,15 +41,15 @@ - - + + - - - - - - + + + + + + @@ -94,7 +94,7 @@ - + @@ -109,21 +109,21 @@ - - - + + + - - - - + + + + - + @@ -133,219 +133,219 @@ - - - - - - - - - + + + + + + + + + - - - - - - + + + + + + - - - - - - + + + + + + - - - - - - + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - + - + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - + + + + + + + + + - + @@ -356,46 +356,46 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + @@ -409,164 +409,164 @@ - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - + + + + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - + @@ -578,50 +578,50 @@ - - - - - - - - + + + + + + + + - - - - - - - + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - - - - + + + + + + + + + + - + @@ -635,68 +635,68 @@ - - - - + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - + @@ -708,15 +708,15 @@ - + - - + + @@ -732,7 +732,7 @@ - + @@ -754,33 +754,33 @@ - - + + - - - - - - + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + diff --git a/dsg_lib/__init__.py b/dsg_lib/__init__.py index 23d9338a..27209659 100644 --- a/dsg_lib/__init__.py +++ b/dsg_lib/__init__.py @@ -1,3 +1,12 @@ # -*- coding: utf-8 -*- +""" +DevSetGo Library +========= + +DevSetGo Library is a Python library offering reusable functions for efficient coding. It includes file operations, calendar utilities, pattern matching, advanced logging with loguru, FastAPI endpoints, async database handling, and email validation. Designed for ease of use and versatility, it's a valuable tool for Python developers. + +Author: Mike Ryan +License: MIT +""" __version__ = "0.14.1" From ceecac6bdc2fe235a303787ba7333e9b84ddb2ab Mon Sep 17 00:00:00 2001 From: devsetgo Date: Sun, 25 Aug 2024 22:44:20 +0000 Subject: [PATCH 11/11] updated run of tests --- coverage.xml | 998 +++++++++++++++++++++++++-------------------------- 1 file changed, 499 insertions(+), 499 deletions(-) diff --git a/coverage.xml b/coverage.xml index c0dc7b6d..0f8e29ed 100644 --- a/coverage.xml +++ b/coverage.xml @@ -1,5 +1,5 @@ - + @@ -16,7 +16,7 @@ - + @@ -30,7 +30,7 @@ - + @@ -41,15 +41,15 @@ - - + + - - - - - - + + + + + + @@ -94,7 +94,7 @@ - + @@ -109,21 +109,21 @@ - - - + + + - - - - + + + + - + @@ -133,219 +133,219 @@ - - - - - - - - - + + + + + + + + + - - - - - - + + + + + + - - - - - - + + + + + + - - - - - - + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - + - + - - - - - - - - - - - + + + + + + + + + + + - - - - - - - - - + + + + + + + + + - + @@ -356,46 +356,46 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + @@ -409,164 +409,164 @@ - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - + + + + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + + - + @@ -578,50 +578,50 @@ - - - - - - - - + + + + + + + + - - - - - - - + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - - - - + + + + + + + + + + - + @@ -635,68 +635,68 @@ - - - - + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - - - - - - - - - - - - - - + + + + + + + + + + + + + + - + @@ -708,15 +708,15 @@ - + - - + + @@ -732,7 +732,7 @@ - + @@ -754,33 +754,33 @@ - - + + - - - - - - + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + +