17
0
2026-03-05 07:29:42 +00:00
committed by Git OBS Bridge
commit a09bb907fc
6 changed files with 235 additions and 0 deletions

24
.gitattributes vendored Normal file
View File

@@ -0,0 +1,24 @@
*.changes merge=merge-changes
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tar filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

4
.gitignore vendored Normal file
View File

@@ -0,0 +1,4 @@
*.obscpio
*.osc
_build.*
.pbuild

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:59b5b9278e30382d6d213497623043ebe63f10e29055be4419a9c04c721739cb
size 61717

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b18c07212bfead624345bb8e1d6141cdcf15a39736994ea0b94035ad2b1ba177
size 63262

134
python-pathvalidate.changes Normal file
View File

@@ -0,0 +1,134 @@
-------------------------------------------------------------------
Tue Mar 3 17:02:59 UTC 2026 - Andreas Schneider <asn@cryptomilk.org>
- Update to version 3.3.1
-------------------------------------------------------------------
Wed Jun 11 05:50:32 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
- Switch to pyproject macros.
- Specify files and directories explicitly in %files.
-------------------------------------------------------------------
Tue Jan 14 11:12:53 UTC 2025 - John Paul Adrian Glaubitz <adrian.glaubitz@suse.com>
- Update to 3.2.3
* Fix dot-files validation
- from version 3.2.2
* Fix the detection logic of the reservation
words for the file name on Windows
* Drop support for Python 3.7/3.8
* Refactor type annotations
-------------------------------------------------------------------
Sat Aug 31 12:18:51 UTC 2024 - Dirk Müller <dmueller@suse.com>
- update to 3.2.1:
* Test Python 3.12 in CIs
* Fix coverage report
* Fix `sanitize_filename` truncation
* Fix validation functions of filepaths
* If `platform` argument is `windows` or `universal`, filepaths
ending with a space or a period should be detected as an
error
* Fix POSIX-style absolute paths were not detected as errors
with `platform="windows"` or `platform="universal"` on Python
3.12 and below
* Add support for Python 3.13
* Improve type annotations
* Add a build and publish workflow
* Add Sigstore signatures to release assets
-------------------------------------------------------------------
Sat Dec 9 10:06:13 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 3.2.0:
* Add `reserved_name_handler` argument to `sanitize_filename`
function and `sanitize_filepath` function
* Add `NullValueHandler` class and `ReservedNameHandler` class
* Add `fs_encoding` property and `byte_count` property to
`ValidationError` class
* Add `additional_reserved_names` argument to validate/sanitize
functions to allow custom reserved names
* Modify the return value format of `ValidationError.__str__`
method
* Improve type annotations
- update to 3.1.0:
* Fix validation error messages to show the `target-platform`
properly: #34 (Thanks to @matanster)
* Fix README: out of date with the actual error generated by
`validate_filename` #35 (Thanks to @hXtreme)
* Add `description` property to `ErrorReason` class
* Add `as_slog` method to `ValidationError` class
* Add `docs` extras
* Change the type of the return value of
`ValidationError.reason` from `Optional[ErrorReason]` to
`ErrorReason`
* Update `[build-system]`
* Drop support for Python 3.6
-------------------------------------------------------------------
Fri Feb 24 12:52:28 UTC 2023 - Daniel Garcia <daniel.garcia@suse.com>
- Update to version 2.5.2
* Add support for Python 3.11: #22 (Thanks to @hegjon)
- v2.5.1
* Add __all__ by @eggplants in #24
* Add DeprecationWarning to deprecated functions
- v2.5.0
* Add support for Python 3.10
* Drop support for Python 3.5
* Add null_value_handler argument to
sanitize_filename/sanitize_filepath functions: #20 (Thanks to @
mkbloke)
* Add AbstractSanitizer/AbstractValidator classes to import path
* Add replace_ansi_escape function
* Add setup-ci target to Makefile
* Modify min_len/max_len to use default values when assigned minus values
- v2.4.1
* Fix filename validations that include '\' (backslash) on other
than Windows: #18 (Thanks to @Traktormaster)
-------------------------------------------------------------------
Sun Mar 21 13:33:57 UTC 2021 - Martin Hauke <mardnh@gmx.de>
- Update to version 2.4.0
* Add exclude_symbols argument to replace_symbol function.
* Fix permissions of files included in sdist package binary.
-------------------------------------------------------------------
Thu Nov 26 10:16:44 UTC 2020 - John Vandenberg <jayvdb@gmail.com>
- Update to v2.3.0
* Change not to process for "."/".." by sanitization functions
* Change to normalize with sanitize_filepath in default
-------------------------------------------------------------------
Sat Mar 28 12:35:30 UTC 2020 - Martin Hauke <mardnh@gmx.de>
- Update to version 2.2.2
* Fix __str__ method
* Fix to avoid raise an exception when an absolute path
includes "."/".."
* Modify an error message
* Modify raising exception from NullNameError to ValidationError
of validate_pathtype
-------------------------------------------------------------------
Fri Mar 20 16:48:47 UTC 2020 - Martin Hauke <mardnh@gmx.de>
- Update to version 2.2.1
* Fix to include py.typed to the package
-------------------------------------------------------------------
Sun Feb 16 09:54:22 UTC 2020 - Martin Hauke <mardnh@gmx.de>
- Update to version 2.2.0
* Add POSIX as a platform
* Change platform of validate_filepath_arg/sanitize_filepath_arg
to 'auto':
-------------------------------------------------------------------
Sat Feb 8 09:47:08 UTC 2020 - Martin Hauke <mardnh@gmx.de>
- Initial package, version 2.1.0

67
python-pathvalidate.spec Normal file
View File

@@ -0,0 +1,67 @@
#
# spec file for package python-pathvalidate
#
# Copyright (c) 2026 SUSE LLC and contributors
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?sle15_python_module_pythons}
Name: python-pathvalidate
Version: 3.3.1
Release: 0
Summary: Python library to sanitize/validate a string such as filenames
License: MIT
URL: https://github.com/thombashi/pathvalidate
Source: https://files.pythonhosted.org/packages/source/p/pathvalidate/pathvalidate-%{version}.tar.gz
BuildRequires: %{python_module pip}
BuildRequires: %{python_module setuptools >= 64}
BuildRequires: %{python_module setuptools_scm >= 8}
BuildRequires: %{python_module wheel}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildRequires: python-rpm-macros
# SECTION test requirements
BuildRequires: %{python_module Faker}
BuildRequires: %{python_module allpairspy}
BuildRequires: %{python_module click}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module tcolorpy}
# /SECTION
BuildArch: noarch
%python_subpackages
%description
pathvalidate is a Python library to sanitize/validate a string such as
filenames/file-paths/etc.
%prep
%autosetup -p1 -n pathvalidate-%{version}
%build
%pyproject_wheel
%install
%pyproject_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
%pytest
%files %{python_files}
%doc README.rst
%license LICENSE
%{python_sitelib}/pathvalidate
%{python_sitelib}/pathvalidate-%{version}.dist-info
%changelog