1
0

10 Commits

Author SHA256 Message Date
dc573251dd Accepting request 1289437 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1289437
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pydantic-settings?expand=0&rev=9
2025-07-02 10:09:41 +00:00
dfc15150f2 - Update to 2.10.1
* Fix UnboundLocalError error in _replace_field_names_case_insensitively
  * Remove unknown file reference in documentation
  * Prepare release 2.10.1
- Update to 2.10.0
  * Fix running tests when azure-keyvault-secrets is not installed
  * Fix running tests when google-cloud-secret-manager is not installed
  * Support loading a specific nested key from YAML in YamlConfigSettingsSource
  * Fix CLI suppression for model group help
  * Fix missing DEFAULT_PATH import
  * Fix case-insensitive handling of nested aliases in EnvironmentSettingsSource
  * Azure Key Vault case insensitive support and dash-underscore translation
  * fix: Respect 'cli_parse_args' from model_config with settings_customise_sources
  * Bump astral-sh/setup-uv
  * Update packages by
  * Update README.md
  * Fix CI badge
  * Update dependencies
  * Fix coverage report
  * Fix _consume_object_or_array on unbalanced brackets in JSON strings
  * add region as a parameter to aws secret manager
  * Expose GCP Secret Manager case sensitive option
  * Update deps
  * feat: Add cli_shortcuts to CLI settings
  * Expose AWS Secrets Manager case sensitive option
  * Prepare release 2.10.0
- remove otional test dependencies

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pydantic-settings?expand=0&rev=18
2025-07-01 09:01:11 +00:00
082e820302 Accepting request 1272302 from devel:languages:python
- Update to 2.9.1:
  * Drop support for Python 3.8
  * Switch to typing-inspection
  * Refactor sources.py into a subpackage
  * Add support for AWS Secrets Manager
  * Fix minor typo: conotations => connotations
  * Azure Key Vault: Don't load disabled secret
  * Add support for GCP Secret Manager
  * CLI JSON Optional Default
  * Fix for env nested enum
  * CLI submodel suppress
  * Cli retrieve unknown args
  * Update pydantic
- Drop patches:
  * fix-settings-dump.patch
  * use-typing_objects.patch

OBS-URL: https://build.opensuse.org/request/show/1272302
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pydantic-settings?expand=0&rev=8
2025-04-25 20:17:55 +00:00
8ca27fd8ae - Update to 2.9.1:
* Drop support for Python 3.8
  * Switch to typing-inspection
  * Refactor sources.py into a subpackage
  * Add support for AWS Secrets Manager
  * Fix minor typo: conotations => connotations
  * Azure Key Vault: Don't load disabled secret
  * Add support for GCP Secret Manager
  * CLI JSON Optional Default
  * Fix for env nested enum
  * CLI submodel suppress
  * Cli retrieve unknown args
  * Update pydantic
- Drop patches:
  * fix-settings-dump.patch
  * use-typing_objects.patch

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pydantic-settings?expand=0&rev=16
2025-04-24 05:54:41 +00:00
6400f49133 Accepting request 1267000 from devel:languages:python
- Update to 2.8.1:
  * Fix for init source kwarg alias resolution
  * Revert usage of positional only argument in BaseSettings.__init__
  * Revert use of object instead of Any
  * CLI support for optional and variadic positional args
  * Improve env_prefix config doc
  * Add env_nested_max_split setting
  * Avoid using Any in BaseSettings signature to avoid mypy errors
  * Asynchronous CLI methods in CliApp
  * Don't explode env vars if env_nested_delimiter is empty
- Add patch use-typing_objects.patch:
  * Use typing_inspection.typing_objects rather than isinstance.
- Refreshed patch fix-settings-dump.patch

OBS-URL: https://build.opensuse.org/request/show/1267000
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pydantic-settings?expand=0&rev=7
2025-04-11 14:45:28 +00:00
b393ce4c0c - Update to 2.8.1:
* Fix for init source kwarg alias resolution
  * Revert usage of positional only argument in BaseSettings.__init__
  * Revert use of object instead of Any
  * CLI support for optional and variadic positional args
  * Improve env_prefix config doc
  * Add env_nested_max_split setting
  * Avoid using Any in BaseSettings signature to avoid mypy errors
  * Asynchronous CLI methods in CliApp
  * Don't explode env vars if env_nested_delimiter is empty
- Add patch use-typing_objects.patch:
  * Use typing_inspection.typing_objects rather than isinstance.
- Refreshed patch fix-settings-dump.patch

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pydantic-settings?expand=0&rev=14
2025-04-04 04:54:24 +00:00
5e05958622 Accepting request 1240690 from devel:languages:python
- Update to 2.7.1:
  * Move preferred alias resolution to private method
  * Fix test_protected_namespace_defaults with -Wdefault
  * Make tests more robust to the running environment
  * Fix rendering of annotations in code example
  * Fix alias resolution for default settings source.
  * Use the class name in the __repr__ implementations
  * Fix default help text for union of submodels.
  * Add support for CliMutuallyExclusiveGroup.
  * Disable abbreviations on internal parser.
  * Fix Secret field parsing
  * Fix alias resolution to use preferred key.
  * Strip annotated when getting submodels during CLI parsing.
  * Removing return type from the function in test
  * Relax default protected_namespaces
  * Add support for CLI kebab case flag.
  * Change reference of default values validation in documentation
  * Improve field value parsing by adding NoDecode and ForceDecode
    annotations
  * Fix attribute error on Python 3.9 with typing.Sequence
  * Add Python 3.13 support
  * Adding support for populate_by_name
  * Refactor path_type_label
  * Fix nested model field with alias parsing
  * Fix PathType typing in case of sequence
  * Add cli_ignore_unknown_args config option.
  * Fix AzureKeyVaultSettingsSource problem in case of field with underscore
  * Add cli_flag_prefix_char config option.
  * Fix nested model AliasChoices in validation alias
  * Add CLI App Support

OBS-URL: https://build.opensuse.org/request/show/1240690
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pydantic-settings?expand=0&rev=6
2025-01-29 15:09:41 +00:00
e4a8a0d837 - Update to 2.7.1:
* Move preferred alias resolution to private method
  * Fix test_protected_namespace_defaults with -Wdefault
  * Make tests more robust to the running environment
  * Fix rendering of annotations in code example
  * Fix alias resolution for default settings source.
  * Use the class name in the __repr__ implementations
  * Fix default help text for union of submodels.
  * Add support for CliMutuallyExclusiveGroup.
  * Disable abbreviations on internal parser.
  * Fix Secret field parsing
  * Fix alias resolution to use preferred key.
  * Strip annotated when getting submodels during CLI parsing.
  * Removing return type from the function in test
  * Relax default protected_namespaces
  * Add support for CLI kebab case flag.
  * Change reference of default values validation in documentation
  * Improve field value parsing by adding NoDecode and ForceDecode
    annotations
  * Fix attribute error on Python 3.9 with typing.Sequence
  * Add Python 3.13 support
  * Adding support for populate_by_name
  * Refactor path_type_label
  * Fix nested model field with alias parsing
  * Fix PathType typing in case of sequence
  * Add cli_ignore_unknown_args config option.
  * Fix AzureKeyVaultSettingsSource problem in case of field with underscore
  * Add cli_flag_prefix_char config option.
  * Fix nested model AliasChoices in validation alias
  * Add CLI App Support

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pydantic-settings?expand=0&rev=12
2025-01-28 02:23:18 +00:00
492f548e7b Accepting request 1218762 from devel:languages:python
- Remove azure BuildRequires

OBS-URL: https://build.opensuse.org/request/show/1218762
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pydantic-settings?expand=0&rev=5
2024-10-29 13:31:51 +00:00
5803852694 - Remove azure BuildRequires
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pydantic-settings?expand=0&rev=10
2024-10-28 09:52:41 +00:00
5 changed files with 149 additions and 44 deletions

View File

@@ -1,32 +0,0 @@
Index: pydantic_settings-2.3.4/tests/test_settings.py
===================================================================
--- pydantic_settings-2.3.4.orig/tests/test_settings.py
+++ pydantic_settings-2.3.4/tests/test_settings.py
@@ -10,6 +10,7 @@ from datetime import datetime, timezone
from enum import IntEnum
from pathlib import Path
from typing import Any, Callable, Dict, Generic, Hashable, List, Optional, Set, Tuple, Type, TypeVar, Union
+from unittest import mock
import pytest
import typing_extensions
@@ -1116,7 +1117,8 @@ def test_multiple_env_file(tmp_path):
model_config = SettingsConfigDict(env_file=[base_env, prod_env])
- s = Settings()
+ with mock.patch.dict('os.environ', {}, clear=True):
+ s = Settings()
assert s.debug_mode is False
assert s.host == 'https://example.com/services'
assert s.port == 8000
@@ -1135,7 +1137,8 @@ def test_model_env_file_override_model_c
model_config = SettingsConfigDict(env_file=prod_env)
- s = Settings(_env_file=base_env)
+ with mock.patch.dict('os.environ', {}, clear=True):
+ s = Settings(_env_file=base_env)
assert s.debug_mode is True
assert s.host == 'localhost'
assert s.port == 8000

BIN
pydantic_settings-2.10.1.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

BIN
pydantic_settings-2.4.0.tar.gz (Stored with Git LFS)

Binary file not shown.

View File

@@ -1,3 +1,134 @@
-------------------------------------------------------------------
Tue Jul 1 08:46:12 UTC 2025 - Nico Krapp <nico.krapp@suse.com>
- Update to 2.10.1
* Fix UnboundLocalError error in _replace_field_names_case_insensitively
* Remove unknown file reference in documentation
* Prepare release 2.10.1
- Update to 2.10.0
* Fix running tests when azure-keyvault-secrets is not installed
* Fix running tests when google-cloud-secret-manager is not installed
* Support loading a specific nested key from YAML in YamlConfigSettingsSource
* Fix CLI suppression for model group help
* Fix missing DEFAULT_PATH import
* Fix case-insensitive handling of nested aliases in EnvironmentSettingsSource
* Azure Key Vault case insensitive support and dash-underscore translation
* fix: Respect 'cli_parse_args' from model_config with settings_customise_sources
* Bump astral-sh/setup-uv
* Update packages by
* Update README.md
* Fix CI badge
* Update dependencies
* Fix coverage report
* Fix _consume_object_or_array on unbalanced brackets in JSON strings
* add region as a parameter to aws secret manager
* Expose GCP Secret Manager case sensitive option
* Update deps
* feat: Add cli_shortcuts to CLI settings
* Expose AWS Secrets Manager case sensitive option
* Prepare release 2.10.0
- remove otional test dependencies
-------------------------------------------------------------------
Thu Apr 24 05:53:47 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
- Update to 2.9.1:
* Drop support for Python 3.8
* Switch to typing-inspection
* Refactor sources.py into a subpackage
* Add support for AWS Secrets Manager
* Fix minor typo: conotations => connotations
* Azure Key Vault: Don't load disabled secret
* Add support for GCP Secret Manager
* CLI JSON Optional Default
* Fix for env nested enum
* CLI submodel suppress
* Cli retrieve unknown args
* Update pydantic
- Drop patches:
* fix-settings-dump.patch
* use-typing_objects.patch
-------------------------------------------------------------------
Fri Apr 4 04:53:17 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
- Update to 2.8.1:
* Fix for init source kwarg alias resolution
* Revert usage of positional only argument in BaseSettings.__init__
* Revert use of object instead of Any
* CLI support for optional and variadic positional args
* Improve env_prefix config doc
* Add env_nested_max_split setting
* Avoid using Any in BaseSettings signature to avoid mypy errors
* Asynchronous CLI methods in CliApp
* Don't explode env vars if env_nested_delimiter is empty
- Add patch use-typing_objects.patch:
* Use typing_inspection.typing_objects rather than isinstance.
- Refreshed patch fix-settings-dump.patch
-------------------------------------------------------------------
Tue Jan 28 02:23:01 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
- Update to 2.7.1:
* Move preferred alias resolution to private method
* Fix test_protected_namespace_defaults with -Wdefault
* Make tests more robust to the running environment
* Fix rendering of annotations in code example
* Fix alias resolution for default settings source.
* Use the class name in the __repr__ implementations
* Fix default help text for union of submodels.
* Add support for CliMutuallyExclusiveGroup.
* Disable abbreviations on internal parser.
* Fix Secret field parsing
* Fix alias resolution to use preferred key.
* Strip annotated when getting submodels during CLI parsing.
* Removing return type from the function in test
* Relax default protected_namespaces
* Add support for CLI kebab case flag.
* Change reference of default values validation in documentation
* Improve field value parsing by adding NoDecode and ForceDecode
annotations
* Fix attribute error on Python 3.9 with typing.Sequence
* Add Python 3.13 support
* Adding support for populate_by_name
* Refactor path_type_label
* Fix nested model field with alias parsing
* Fix PathType typing in case of sequence
* Add cli_ignore_unknown_args config option.
* Fix AzureKeyVaultSettingsSource problem in case of field with underscore
* Add cli_flag_prefix_char config option.
* Fix nested model AliasChoices in validation alias
* Add CLI App Support
* Fix a regression in dotenv optional nested field
* Put tests for non-default sources in separate files
* Update nested model partial update docs example.
* Add support for suppressing fields from CLI help.
* Fix bug in dotenv source when there is env with and without prefix
* Fix a bug in nested vanila dataclass
* CLI Improve Docstring Help Text
* Cli fix default or none object help text
* Determine RootModel complexity from root type
* Add CLI bool flags
* CLI arg list whitespaces fix.
* Add nested_model_default_partial_update flag and DefaultSettingsSource
* Parse enum fixes.
* Fixes CLI help text for function types
* Add get_subcommand function.
* Cli prefix validation alias fix
* CLI ignore external parser list fix
* Enable multiple secrets dirs
* Add CLI subcommand union and alias support
* Fix dotenv settings source problem in handling extra variables with
same prefix in name
- Drop patch clear-environment.patch, fixed by upstream in a different way.
- Add patch fix-settings-dump.patch:
* Support changes introduced by Pydantic 2.10.
-------------------------------------------------------------------
Mon Oct 28 09:52:17 UTC 2024 - Daniel Garcia <daniel.garcia@suse.com>
- Remove azure BuildRequires
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Sep 12 05:57:59 UTC 2024 - Steve Kowalik <steven.kowalik@suse.com> Thu Sep 12 05:57:59 UTC 2024 - Steve Kowalik <steven.kowalik@suse.com>

View File

@@ -1,7 +1,7 @@
# #
# spec file for package python-pydantic-settings # spec file for package python-pydantic-settings
# #
# Copyright (c) 2024 SUSE LLC # Copyright (c) 2025 SUSE LLC
# #
# All modifications and additions to the file contributed by third parties # All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed # remain the property of their copyright owners, unless otherwise agreed
@@ -26,31 +26,35 @@
%endif %endif
%{?sle15_python_module_pythons} %{?sle15_python_module_pythons}
Name: python-pydantic-settings%{psuffix} Name: python-pydantic-settings%{psuffix}
Version: 2.4.0 Version: 2.10.1
Release: 0 Release: 0
Summary: Settings management using Pydantic Summary: Settings management using Pydantic
License: MIT License: MIT
URL: https://github.com/pydantic/pydantic-settings URL: https://github.com/pydantic/pydantic-settings
Source: https://files.pythonhosted.org/packages/source/p/pydantic-settings/pydantic_settings-%{version}.tar.gz Source: https://files.pythonhosted.org/packages/source/p/pydantic-settings/pydantic_settings-%{version}.tar.gz
# PATCH-FIX-OPENSUSE Clear the environment before two test cases BuildRequires: %{python_module base >= 3.9}
Patch0: clear-environment.patch
BuildRequires: %{python_module hatchling} BuildRequires: %{python_module hatchling}
BuildRequires: %{python_module pip} BuildRequires: %{python_module pip}
BuildRequires: python-rpm-macros BuildRequires: python-rpm-macros
# SECTION test requirements # SECTION test requirements
%if %{with test} %if %{with test}
BuildRequires: %{python_module azure-identity >= 1.16} BuildRequires: %{python_module azure-identity}
BuildRequires: %{python_module pydantic-settings == %{version}} BuildRequires: %{python_module google-auth}
BuildRequires: %{python_module pydantic-settings = %{version}}
BuildRequires: %{python_module pytest-examples} BuildRequires: %{python_module pytest-examples}
BuildRequires: %{python_module pytest-mock} BuildRequires: %{python_module pytest-mock}
BuildRequires: %{python_module pytest} BuildRequires: %{python_module pytest}
%endif %endif
# /SECTION # /SECTION
BuildRequires: fdupes BuildRequires: fdupes
Requires: python-pydantic >= 2.3.0 Requires: python-pydantic >= 2.7.0
Requires: python-python-dotenv >= 0.21.0 Requires: python-python-dotenv >= 0.21.0
Suggests: python-pyyaml >= 6.0.1 Requires: python-typing-inspection >= 0.4.0
Suggests: python-PyYAML >= 6.0.1
Suggests: python-tomli >= 2.0.1 Suggests: python-tomli >= 2.0.1
Suggests: python-google-cloud-secret-manager >= 2.23.1
Suggests: python-azure-keyvault-secrets >= 4.8
Suggests: python-azure-identity
BuildArch: noarch BuildArch: noarch
%python_subpackages %python_subpackages
@@ -71,7 +75,9 @@ Settings management using Pydantic, this is the new official home of Pydantic's
%check %check
%if %{with test} %if %{with test}
%pytest # This test requires azure
skiptest="test_docs_examples[docs/index.md:1847-1890]"
%pytest -k "not ($skiptest)"
%endif %endif
%if !%{with test} %if !%{with test}