Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-path for openSUSE:Factory checked in at 2022-12-08 16:50:05 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-path (Old) and /work/SRC/openSUSE:Factory/.python-path.new.1835 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-path" Thu Dec 8 16:50:05 2022 rev:5 rq:1041240 version:16.6.0 Changes: -------- --- /work/SRC/openSUSE:Factory/python-path/python-path.changes 2022-10-14 15:40:25.455706493 +0200 +++ /work/SRC/openSUSE:Factory/.python-path.new.1835/python-path.changes 2022-12-08 16:50:11.999180466 +0100 @@ -1,0 +2,6 @@ +Wed Dec 7 20:00:17 UTC 2022 - Yogalakshmi Arunachalam <yarunacha...@suse.com> + +- Update to version 16.6.0 + * .mtime and .atime are now settable. + +------------------------------------------------------------------- Old: ---- path-16.5.0.tar.gz New: ---- path-16.6.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-path.spec ++++++ --- /var/tmp/diff_new_pack.SvFB4W/_old 2022-12-08 16:50:12.503183045 +0100 +++ /var/tmp/diff_new_pack.SvFB4W/_new 2022-12-08 16:50:12.511183086 +0100 @@ -28,7 +28,7 @@ %define skip_python2 1 %define modname path Name: python-path%{psuffix} -Version: 16.5.0 +Version: 16.6.0 Release: 0 Summary: A module wrapper for os.path License: MIT ++++++ path-16.5.0.tar.gz -> path-16.6.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/.github/workflows/main.yml new/path-16.6.0/.github/workflows/main.yml --- old/path-16.5.0/.github/workflows/main.yml 2022-09-25 18:21:57.000000000 +0200 +++ new/path-16.6.0/.github/workflows/main.yml 2022-11-30 23:46:48.000000000 +0100 @@ -2,14 +2,44 @@ on: [push, pull_request] +env: + # Environment variables to support color support (jaraco/skeleton#66): + # Request colored output from CLI tools supporting it. Different tools + # interpret the value differently. For some, just being set is sufficient. + # For others, it must be a non-zero integer. For yet others, being set + # to a non-empty value is sufficient. + FORCE_COLOR: -106 + # MyPy's color enforcement (must be a non-zero number) + MYPY_FORCE_COLOR: -42 + # Recognized by the `py` package, dependency of `pytest` (must be "1") + PY_COLORS: 1 + # Make tox-wrapped tools see color requests + TOX_TESTENV_PASSENV: >- + FORCE_COLOR + MYPY_FORCE_COLOR + NO_COLOR + PY_COLORS + PYTEST_THEME + PYTEST_THEME_MODE + + # Suppress noisy pip warnings + PIP_DISABLE_PIP_VERSION_CHECK: 'true' + PIP_NO_PYTHON_VERSION_WARNING: 'true' + PIP_NO_WARN_SCRIPT_LOCATION: 'true' + + # Disable the spinner, noise in GHA; TODO(webknjaz): Fix this upstream + # Must be "1". + TOX_PARALLEL_NO_SPINNER: 1 + + jobs: test: strategy: matrix: python: - "3.7" - - "3.10" - "3.11" + - "3.12" # Workaround for actions/setup-python#508 dev: - -dev @@ -18,6 +48,12 @@ - macos-latest - windows-latest include: + - python: "3.8" + platform: ubuntu-latest + - python: "3.9" + platform: ubuntu-latest + - python: "3.10" + platform: ubuntu-latest - python: pypy3.9 platform: ubuntu-latest runs-on: ${{ matrix.platform }} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/.readthedocs.yaml new/path-16.6.0/.readthedocs.yaml --- old/path-16.5.0/.readthedocs.yaml 1970-01-01 01:00:00.000000000 +0100 +++ new/path-16.6.0/.readthedocs.yaml 2022-11-30 23:46:48.000000000 +0100 @@ -0,0 +1,13 @@ +version: 2 +python: + install: + - path: . + extra_requirements: + - docs + +# workaround for readthedocs/readthedocs.org#9623 +build: + # workaround for readthedocs/readthedocs.org#9635 + os: ubuntu-22.04 + tools: + python: "3" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/.readthedocs.yml new/path-16.6.0/.readthedocs.yml --- old/path-16.5.0/.readthedocs.yml 2022-09-25 18:21:57.000000000 +0200 +++ new/path-16.6.0/.readthedocs.yml 1970-01-01 01:00:00.000000000 +0100 @@ -1,6 +0,0 @@ -version: 2 -python: - install: - - path: . - extra_requirements: - - docs diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/CHANGES.rst new/path-16.6.0/CHANGES.rst --- old/path-16.5.0/CHANGES.rst 2022-09-25 18:21:57.000000000 +0200 +++ new/path-16.6.0/CHANGES.rst 2022-11-30 23:46:48.000000000 +0100 @@ -1,3 +1,8 @@ +v16.6.0 +------- + +- ``.mtime`` and ``.atime`` are now settable. + v16.5.0 ------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/PKG-INFO new/path-16.6.0/PKG-INFO --- old/path-16.5.0/PKG-INFO 2022-09-25 18:22:42.166541800 +0200 +++ new/path-16.6.0/PKG-INFO 2022-11-30 23:47:17.048983000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: path -Version: 16.5.0 +Version: 16.6.0 Summary: A module wrapper for os.path Home-page: https://github.com/jaraco/path Author: Jason Orendorff @@ -20,12 +20,9 @@ License-File: LICENSE .. image:: https://img.shields.io/pypi/v/path.svg - :target: `PyPI link`_ + :target: https://pypi.org/project/path .. image:: https://img.shields.io/pypi/pyversions/path.svg - :target: `PyPI link`_ - -.. _PyPI link: https://pypi.org/project/path .. image:: https://github.com/jaraco/path/workflows/tests/badge.svg :target: https://github.com/jaraco/path/actions?query=workflow%3A%22tests%22 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/README.rst new/path-16.6.0/README.rst --- old/path-16.5.0/README.rst 2022-09-25 18:21:57.000000000 +0200 +++ new/path-16.6.0/README.rst 2022-11-30 23:46:48.000000000 +0100 @@ -1,10 +1,7 @@ .. image:: https://img.shields.io/pypi/v/path.svg - :target: `PyPI link`_ + :target: https://pypi.org/project/path .. image:: https://img.shields.io/pypi/pyversions/path.svg - :target: `PyPI link`_ - -.. _PyPI link: https://pypi.org/project/path .. image:: https://github.com/jaraco/path/workflows/tests/badge.svg :target: https://github.com/jaraco/path/actions?query=workflow%3A%22tests%22 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/docs/conf.py new/path-16.6.0/docs/conf.py --- old/path-16.5.0/docs/conf.py 2022-09-25 18:21:57.000000000 +0200 +++ new/path-16.6.0/docs/conf.py 2022-11-30 23:46:48.000000000 +0100 @@ -7,6 +7,7 @@ ] master_doc = "index" +html_theme = "furo" pygments_style = "sphinx" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/mypy.ini new/path-16.6.0/mypy.ini --- old/path-16.5.0/mypy.ini 2022-09-25 18:21:57.000000000 +0200 +++ new/path-16.6.0/mypy.ini 2022-11-30 23:46:48.000000000 +0100 @@ -1,2 +1,5 @@ [mypy] ignore_missing_imports = True +# required to support namespace packages +# https://github.com/python/mypy/issues/14057 +explicit_package_bases = True diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/path/__init__.py new/path-16.6.0/path/__init__.py --- old/path-16.5.0/path/__init__.py 2022-09-25 18:21:57.000000000 +0200 +++ new/path-16.6.0/path/__init__.py 2022-11-30 23:46:48.000000000 +0100 @@ -37,6 +37,9 @@ import io import importlib import itertools +import datetime +from numbers import Number +from typing import Union with contextlib.suppress(ImportError): import win32security @@ -66,6 +69,11 @@ _default_linesep = object() +def _make_timestamp_ns(value: Union[Number, datetime.datetime]) -> Number: + timestamp_s = value if isinstance(value, Number) else value.timestamp() + return int(timestamp_s * 10**9) + + class TreeWalkWarning(Warning): pass @@ -906,9 +914,13 @@ """.. seealso:: :attr:`atime`, :func:`os.path.getatime`""" return self.module.getatime(self) + def set_atime(self, value): + mtime_ns = self.stat().st_atime_ns + self.utime(ns=(_make_timestamp_ns(value), mtime_ns)) + atime = property( getatime, - None, + set_atime, None, """ Last access time of the file. @@ -916,6 +928,14 @@ >>> Path('.').atime > 0 True + Allows setting: + + >>> some_file = Path(getfixture('tmp_path')).joinpath('file.txt').touch() + >>> MST = datetime.timezone(datetime.timedelta(hours=-7)) + >>> some_file.atime = datetime.datetime(1976, 5, 7, 10, tzinfo=MST) + >>> some_file.atime + 200336400.0 + .. seealso:: :meth:`getatime`, :func:`os.path.getatime` """, ) @@ -924,13 +944,25 @@ """.. seealso:: :attr:`mtime`, :func:`os.path.getmtime`""" return self.module.getmtime(self) + def set_mtime(self, value): + atime_ns = self.stat().st_atime_ns + self.utime(ns=(atime_ns, _make_timestamp_ns(value))) + mtime = property( getmtime, - None, + set_mtime, None, """ Last modified time of the file. + Allows setting: + + >>> some_file = Path(getfixture('tmp_path')).joinpath('file.txt').touch() + >>> MST = datetime.timezone(datetime.timedelta(hours=-7)) + >>> some_file.mtime = datetime.datetime(1976, 5, 7, 10, tzinfo=MST) + >>> some_file.mtime + 200336400.0 + .. seealso:: :meth:`getmtime`, :func:`os.path.getmtime` """, ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/path.egg-info/PKG-INFO new/path-16.6.0/path.egg-info/PKG-INFO --- old/path-16.5.0/path.egg-info/PKG-INFO 2022-09-25 18:22:42.000000000 +0200 +++ new/path-16.6.0/path.egg-info/PKG-INFO 2022-11-30 23:47:17.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: path -Version: 16.5.0 +Version: 16.6.0 Summary: A module wrapper for os.path Home-page: https://github.com/jaraco/path Author: Jason Orendorff @@ -20,12 +20,9 @@ License-File: LICENSE .. image:: https://img.shields.io/pypi/v/path.svg - :target: `PyPI link`_ + :target: https://pypi.org/project/path .. image:: https://img.shields.io/pypi/pyversions/path.svg - :target: `PyPI link`_ - -.. _PyPI link: https://pypi.org/project/path .. image:: https://github.com/jaraco/path/workflows/tests/badge.svg :target: https://github.com/jaraco/path/actions?query=workflow%3A%22tests%22 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/path.egg-info/SOURCES.txt new/path-16.6.0/path.egg-info/SOURCES.txt --- old/path-16.5.0/path.egg-info/SOURCES.txt 2022-09-25 18:22:42.000000000 +0200 +++ new/path-16.6.0/path.egg-info/SOURCES.txt 2022-11-30 23:47:17.000000000 +0100 @@ -4,7 +4,7 @@ .flake8 .gitignore .pre-commit-config.yaml -.readthedocs.yml +.readthedocs.yaml CHANGES.rst Dockerfile LICENSE diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/path.egg-info/requires.txt new/path-16.6.0/path.egg-info/requires.txt --- old/path-16.5.0/path.egg-info/requires.txt 2022-09-25 18:22:42.000000000 +0200 +++ new/path-16.6.0/path.egg-info/requires.txt 2022-11-30 23:47:17.000000000 +0100 @@ -3,12 +3,12 @@ sphinx>=3.5 jaraco.packaging>=9 rst.linker>=1.9 +furo jaraco.tidelift>=1.4 [testing] pytest>=6 pytest-checkdocs>=2.4 -pytest-flake8 flake8<5 pytest-cov pytest-enabler>=1.3 @@ -20,5 +20,8 @@ pytest-black>=0.3.7 pytest-mypy>=0.9.1 -[testing:platform_system == "Windows"] +[testing:platform_system == "Windows" and python_version < "3.12"] pywin32 + +[testing:python_version < "3.12"] +pytest-flake8 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/setup.cfg new/path-16.6.0/setup.cfg --- old/path-16.5.0/setup.cfg 2022-09-25 18:22:42.166541800 +0200 +++ new/path-16.6.0/setup.cfg 2022-11-30 23:47:17.048983000 +0100 @@ -33,7 +33,8 @@ testing = pytest >= 6 pytest-checkdocs >= 2.4 - pytest-flake8 + pytest-flake8; \ + python_version < "3.12" flake8 < 5 pytest-black >= 0.3.7; \ python_implementation != "PyPy" @@ -44,13 +45,14 @@ appdirs packaging - pywin32; platform_system == "Windows" + pywin32; platform_system == "Windows" and python_version < "3.12" pygments docs = sphinx >= 3.5 jaraco.packaging >= 9 rst.linker >= 1.9 + furo jaraco.tidelift >= 1.4 [options.entry_points] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/path-16.5.0/test_path.py new/path-16.6.0/test_path.py --- old/path-16.5.0/test_path.py 2022-09-25 18:21:57.000000000 +0200 +++ new/path-16.6.0/test_path.py 2022-11-30 23:46:48.000000000 +0100 @@ -334,6 +334,7 @@ class TestOwnership: + @pytest.mark.skipif('platform.system() == "Windows" and sys.version_info > (3, 12)') def test_get_owner(self): Path('/').get_owner()