From 539ed5bb601622c36cb87e8133ad77849fad241e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 1 Feb 2024 13:14:15 -0500 Subject: [PATCH] Bump the python-dependencies group with 4 updates (#288) * Bump the python-dependencies group with 4 updates --- updated-dependencies: - dependency-name: pydantic-settings dependency-type: direct:production dependency-group: python-dependencies - dependency-name: sqlalchemy dependency-type: direct:production dependency-group: python-dependencies - dependency-name: sphinx-rtd-theme dependency-type: direct:development dependency-group: python-dependencies - dependency-name: sphinx-jsonschema dependency-type: direct:development dependency-group: python-dependencies ... Signed-off-by: dependabot[bot] * Drops sphinx pydantic --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Daniel Perrefort --- docs/source/conf.py | 1 - docs/source/overview/configuration.rst | 74 ++++++++++++++++++++++++-- pyproject.toml | 8 ++- 3 files changed, 73 insertions(+), 10 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index aa2e501..f81aabc 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -32,7 +32,6 @@ 'sphinx.ext.githubpages', 'sphinx_copybutton', 'sphinxarg.ext', - 'sphinx-pydantic' ] # Customize default options for the sphinx autodoc utility diff --git a/docs/source/overview/configuration.rst b/docs/source/overview/configuration.rst index e701c7a..93cdb14 100644 --- a/docs/source/overview/configuration.rst +++ b/docs/source/overview/configuration.rst @@ -29,10 +29,76 @@ If this file does not exist, the application will run using the default settings A full list of available settings and their defaults is provided below. +Core Settings +............. + .. important:: The top level ``file_systems`` field is a nested field and entries - should adhere to the :ref:`#/$defs/filesystemschema` schema outlined below. + should adhere to the :ref:`fs-label` schema outlined below. + ++------------------+-----------------------------------------+---------------------------------------------------------+ +| Setting | Default Value | Description | ++==================+=========================================+=========================================================+ +| ihome_quota_path | ``/ihome/crc/scripts/ihome_quota.json`` | Path to ihome storage information. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| file_systems | ``[]`` | List of file systems to examine. See the | +| | | :ref:`fs-label` section for details | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| uid_blacklist | ``[0]`` | Do not notify users with these UID values. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| gid_blacklist | ``[0]`` | Do not notify groups with these GID values. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| disk_timeout | ``30`` | Give up on checking a file system after | +| | | the given number of seconds. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| log_level | ``INFO`` | Application logging level. | +| log_level | ``INFO`` | One of ``DEBUG``, ``INFO``, ``WARNING``, or ``ERROR``. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| log_path | | Optionally log application events to a | +| | | file. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| smtp_host | Matches system default. | Name of the SMTP host server. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| smtp_port | Matches system default. | Port for the SMTP server. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| db_url | ``sqlite:///notifier_data.db`` | URL for the application database. By | +| | | default, a SQLITE database is created in | +| | | the working directory. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| email_from | ``no-reply@domain.com`` | From address for automatically generated | +| | | emails. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| email_subject | ``CRC Disk Usage Alert`` | Subject line for automatically generated | +| | | emails. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| email_domain | ``@domain.com`` | String to append to usernames when | +| | | generating user email addresses. The | +| | | leading ``@`` is optional. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| admin_emails | ``[]`` | Admin users to contact when the | +| | | application encounters a critical issue. | ++------------------+-----------------------------------------+---------------------------------------------------------+ +| debug | ``False`` | Disable database commits and email | +| | | notifications. Useful for development | +| | | and testing. | ++------------------+-----------------------------------------+---------------------------------------------------------+ + +.. _fs-label: + +File System Settings +.................... + +The following fields are required when defining which file systems to scan. -.. pydantic:: quota_notifier.settings.SettingsSchema ++------------------------+---------------------------------------------------------------------------------------------+ +| Setting | Description | ++========================+=============================================================================================+ +| name | Human-readable name for the file system. | ++------------------------+---------------------------------------------------------------------------------------------+ +| path | Absolute path to the mounted file system. | ++------------------------+---------------------------------------------------------------------------------------------+ +| type | Type of the file system. Options: ``ihome``, ``generic``, ``beegfs``. If modifying options, | +| | update QuotaType in ``quota_notifier.disk_utils.QuotaFactory``. | ++------------------------+---------------------------------------------------------------------------------------------+ +| thresholds | Usage percentages to issue notifications for. | ++------------------------+---------------------------------------------------------------------------------------------+ -.. _#/$defs/filesystemschema: -.. pydantic:: quota_notifier.settings.FileSystemSchema diff --git a/pyproject.toml b/pyproject.toml index fbfd9d9..a598e75 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -29,8 +29,8 @@ notifier = "quota_notifier.cli:Application.execute" [tool.poetry.dependencies] python = ">=3.8" -pydantic-settings = "2.0.3" -sqlalchemy = "2.0.21" +pydantic-settings = "2.1.0" +sqlalchemy = "2.0.25" [tool.poetry.group.tests] optional = true @@ -45,6 +45,4 @@ optional = true sphinx = "6.2.1" sphinx-argparse = "0.4.0" sphinx-copybutton = "0.5.2" -sphinx-pydantic = "0.1.1" -sphinx-rtd-theme = "1.2.2" -sphinx-jsonschema = "1.15" +sphinx-rtd-theme = "2.0.0"