Hello community, here is the log from the commit of package python-pluggy for openSUSE:Factory checked in at 2019-09-23 12:16:58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-pluggy (Old) and /work/SRC/openSUSE:Factory/.python-pluggy.new.7948 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pluggy" Mon Sep 23 12:16:58 2019 rev:13 rq:730734 version:0.13.0 Changes: -------- --- /work/SRC/openSUSE:Factory/python-pluggy/python-pluggy.changes 2019-06-18 14:45:11.705736118 +0200 +++ /work/SRC/openSUSE:Factory/.python-pluggy.new.7948/python-pluggy.changes 2019-09-23 12:16:59.513810863 +0200 @@ -1,0 +2,6 @@ +Fri Sep 13 13:20:01 UTC 2019 - Tomáš Chvátal <tchva...@suse.com> + +- Update to 0.13.0: + * support python 3.8 + +------------------------------------------------------------------- Old: ---- pluggy-0.12.0.tar.gz New: ---- pluggy-0.13.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-pluggy.spec ++++++ --- /var/tmp/diff_new_pack.gPCPnL/_old 2019-09-23 12:16:59.981810786 +0200 +++ /var/tmp/diff_new_pack.gPCPnL/_new 2019-09-23 12:16:59.985810786 +0200 @@ -26,7 +26,7 @@ %bcond_with test %endif Name: python-pluggy%{psuffix} -Version: 0.12.0 +Version: 0.13.0 Release: 0 Summary: Plugin registration and hook calling mechanisms for Python License: MIT ++++++ pluggy-0.12.0.tar.gz -> pluggy-0.13.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/.travis.yml new/pluggy-0.13.0/.travis.yml --- old/pluggy-0.12.0/.travis.yml 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/.travis.yml 2019-09-10 22:14:28.000000000 +0200 @@ -17,31 +17,31 @@ - python: '3.6' env: TOXENV=docs - python: '2.7' - env: TOXENV=py27-pytestrelease-coverage + env: TOXENV=py27-coverage - python: '3.4' - env: TOXENV=py34-pytestrelease-coverage + env: TOXENV=py34-coverage - python: '3.5' - env: TOXENV=py35-pytestrelease-coverage + env: TOXENV=py35-coverage - python: '3.6' - env: TOXENV=py36-pytestrelease-coverage + env: TOXENV=py36-coverage - python: 'pypy2.7-6.0' - env: TOXENV=pypy-pytestrelease-coverage + env: TOXENV=pypy-coverage - python: 'pypy3.5-6.0' - env: TOXENV=pypy3-pytestrelease-coverage + env: TOXENV=pypy3-coverage - python: '3.7' - env: TOXENV=py37-pytestrelease-coverage + env: TOXENV=py37-coverage - python: '3.8-dev' - env: TOXENV=py38-pytestrelease-coverage - - python: '2.7' - env: TOXENV=py27-pytestmaster-coverage - - python: '2.7' - env: TOXENV=py27-pytestfeatures-coverage + env: TOXENV=py38-coverage - python: '3.6' env: TOXENV=py36-pytestmaster-coverage - python: '3.6' env: TOXENV=py36-pytestfeatures-coverage - python: '3.6' env: TOXENV=benchmark + - python: '3.7' + env: TOXENV=py37-pytestmaster-coverage + - python: '3.7' + env: TOXENV=py37-pytestfeatures-coverage - stage: deploy python: '3.6' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/CHANGELOG.rst new/pluggy-0.13.0/CHANGELOG.rst --- old/pluggy-0.12.0/CHANGELOG.rst 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/CHANGELOG.rst 2019-09-10 22:14:28.000000000 +0200 @@ -4,6 +4,16 @@ .. towncrier release notes start +pluggy 0.13.0 (2019-09-10) +========================== + +Trivial/Internal Changes +------------------------ + +- `#222 <https://github.com/pytest-dev/pluggy/issues/222>`_: Replace ``importlib_metadata`` backport with ``importlib.metadata`` from the + standard library on Python 3.8+. + + pluggy 0.12.0 (2019-05-27) ========================== diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/PKG-INFO new/pluggy-0.13.0/PKG-INFO --- old/pluggy-0.12.0/PKG-INFO 2019-05-27 22:20:09.000000000 +0200 +++ new/pluggy-0.13.0/PKG-INFO 2019-09-10 22:14:47.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: pluggy -Version: 0.12.0 +Version: 0.13.0 Summary: plugin and hook calling mechanisms for python Home-page: https://github.com/pytest-dev/pluggy Author: Holger Krekel @@ -114,6 +114,16 @@ .. towncrier release notes start + pluggy 0.13.0 (2019-09-10) + ========================== + + Trivial/Internal Changes + ------------------------ + + - `#222 <https://github.com/pytest-dev/pluggy/issues/222>`_: Replace ``importlib_metadata`` backport with ``importlib.metadata`` from the + standard library on Python 3.8+. + + pluggy 0.12.0 (2019-05-27) ========================== diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/appveyor.yml new/pluggy-0.13.0/appveyor.yml --- old/pluggy-0.12.0/appveyor.yml 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/appveyor.yml 2019-09-10 22:14:28.000000000 +0200 @@ -3,13 +3,12 @@ # note: please use "tox --listenvs" to populate the build matrix below - TOXENV: "linting" - TOXENV: "docs" - - TOXENV: "py27-pytestrelease" - - TOXENV: "py34-pytestrelease" - - TOXENV: "py35-pytestrelease" - - TOXENV: "py36-pytestrelease" - - TOXENV: "pypy-pytestrelease" - - TOXENV: "py27-pytestmaster" - - TOXENV: "py27-pytestfeatures" + - TOXENV: "py27" + - TOXENV: "py34" + - TOXENV: "py35" + - TOXENV: "py36" + - TOXENV: "py37" + - TOXENV: "pypy" - TOXENV: "py36-pytestmaster" - TOXENV: "py36-pytestfeatures" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/docs/conf.py new/pluggy-0.13.0/docs/conf.py --- old/pluggy-0.12.0/docs/conf.py 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/docs/conf.py 2019-09-10 22:14:28.000000000 +0200 @@ -1,5 +1,10 @@ # -*- coding: utf-8 -*- -import importlib_metadata +import sys + +if sys.version_info >= (3, 8): + from importlib import metadata +else: + import importlib_metadata as metadata extensions = [ @@ -24,7 +29,7 @@ copyright = u"2016, Holger Krekel" author = "Holger Krekel" -release = importlib_metadata.version(project) +release = metadata.version(project) # The short X.Y version. version = u".".join(release.split(".")[:2]) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/docs/index.rst new/pluggy-0.13.0/docs/index.rst --- old/pluggy-0.12.0/docs/index.rst 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/docs/index.rst 2019-09-10 22:14:28.000000000 +0200 @@ -777,7 +777,9 @@ # call with history; no results returned - pm.hook.myhook.call_historic(config=config, args=sys.argv, result_callback=callback) + pm.hook.myhook.call_historic( + kwargs={"config": config, "args": sys.argv}, result_callback=callback + ) # ... more of our program ... diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/setup.py new/pluggy-0.13.0/setup.py --- old/pluggy-0.12.0/setup.py 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/setup.py 2019-09-10 22:14:28.000000000 +0200 @@ -37,7 +37,7 @@ author_email="hol...@merlinux.eu", url="https://github.com/pytest-dev/pluggy", python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*", - install_requires=["importlib-metadata>=0.12"], + install_requires=['importlib-metadata>=0.12;python_version<"3.8"'], extras_require={"dev": ["pre-commit", "tox"]}, classifiers=classifiers, packages=["pluggy"], diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/src/pluggy/_tracing.py new/pluggy-0.13.0/src/pluggy/_tracing.py --- old/pluggy-0.12.0/src/pluggy/_tracing.py 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/src/pluggy/_tracing.py 2019-09-10 22:14:28.000000000 +0200 @@ -1,19 +1,18 @@ """ Tracing utils """ -from .callers import _Result class TagTracer(object): def __init__(self): - self._tag2proc = {} - self.writer = None + self._tags2proc = {} + self._writer = None self.indent = 0 def get(self, name): return TagTracerSub(self, (name,)) - def format_message(self, tags, args): + def _format_message(self, tags, args): if isinstance(args[-1], dict): extra = args[-1] args = args[:-1] @@ -27,26 +26,28 @@ for name, value in extra.items(): lines.append("%s %s: %s\n" % (indent, name, value)) - return lines - def processmessage(self, tags, args): - if self.writer is not None and args: - lines = self.format_message(tags, args) - self.writer("".join(lines)) + return "".join(lines) + + def _processmessage(self, tags, args): + if self._writer is not None and args: + self._writer(self._format_message(tags, args)) try: - self._tag2proc[tags](tags, args) + processor = self._tags2proc[tags] except KeyError: pass + else: + processor(tags, args) def setwriter(self, writer): - self.writer = writer + self._writer = writer def setprocessor(self, tags, processor): if isinstance(tags, str): tags = tuple(tags.split(":")) else: assert isinstance(tags, tuple) - self._tag2proc[tags] = processor + self._tags2proc[tags] = processor class TagTracerSub(object): @@ -55,29 +56,7 @@ self.tags = tags def __call__(self, *args): - self.root.processmessage(self.tags, args) - - def setmyprocessor(self, processor): - self.root.setprocessor(self.tags, processor) + self.root._processmessage(self.tags, args) def get(self, name): return self.__class__(self.root, self.tags + (name,)) - - -class _TracedHookExecution(object): - def __init__(self, pluginmanager, before, after): - self.pluginmanager = pluginmanager - self.before = before - self.after = after - self.oldcall = pluginmanager._inner_hookexec - assert not isinstance(self.oldcall, _TracedHookExecution) - self.pluginmanager._inner_hookexec = self - - def __call__(self, hook, hook_impls, kwargs): - self.before(hook.name, hook_impls, kwargs) - outcome = _Result.from_call(lambda: self.oldcall(hook, hook_impls, kwargs)) - self.after(outcome, hook.name, hook_impls, kwargs) - return outcome.get_result() - - def undo(self): - self.pluginmanager._inner_hookexec = self.oldcall diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/src/pluggy/_version.py new/pluggy-0.13.0/src/pluggy/_version.py --- old/pluggy-0.12.0/src/pluggy/_version.py 2019-05-27 22:20:08.000000000 +0200 +++ new/pluggy-0.13.0/src/pluggy/_version.py 2019-09-10 22:14:46.000000000 +0200 @@ -1,4 +1,4 @@ # coding: utf-8 # file generated by setuptools_scm # don't change, don't track in version control -version = '0.12.0' +version = '0.13.0' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/src/pluggy/hooks.py new/pluggy-0.13.0/src/pluggy/hooks.py --- old/pluggy-0.12.0/src/pluggy/hooks.py 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/src/pluggy/hooks.py 2019-09-10 22:14:28.000000000 +0200 @@ -84,7 +84,7 @@ in an error (by default it is an error if no matching spec is found). If tryfirst is True this hook implementation will run as early as possible - in the chain of N hook implementations for a specfication. + in the chain of N hook implementations for a specification. If trylast is True this hook implementation will run as late as possible in the chain of N hook implementations. @@ -161,7 +161,7 @@ try: func = getattr(func, "__call__", func) except Exception: - return () + return (), () try: # func MUST be a function or method here or we won't parse any args spec = _getargspec(func) @@ -171,9 +171,9 @@ args, defaults = tuple(spec.args), spec.defaults if defaults: index = -len(defaults) - args, defaults = args[:index], tuple(args[index:]) + args, kwargs = args[:index], tuple(args[index:]) else: - defaults = () + kwargs = () # strip any implicit instance arg # pypy3 uses "obj" instead of "self" for default dunder methods @@ -185,10 +185,10 @@ args = args[1:] try: - cache["_varnames"] = args, defaults + cache["_varnames"] = args, kwargs except TypeError: pass - return args, defaults + return args, kwargs class _HookRelay(object): @@ -197,9 +197,6 @@ """ - def __init__(self, trace): - self._trace = trace - class _HookCaller(object): def __init__(self, name, hook_execute, specmodule_or_class=None, spec_opts=None): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/src/pluggy/manager.py new/pluggy-0.13.0/src/pluggy/manager.py --- old/pluggy-0.12.0/src/pluggy/manager.py 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/src/pluggy/manager.py 2019-09-10 22:14:28.000000000 +0200 @@ -1,9 +1,14 @@ import inspect +import sys from . import _tracing +from .callers import _Result from .hooks import HookImpl, _HookRelay, _HookCaller, normalize_hookimpl_opts import warnings -import importlib_metadata +if sys.version_info >= (3, 8): + from importlib import metadata as importlib_metadata +else: + import importlib_metadata def _warn_for_function(warning, function): @@ -66,7 +71,7 @@ self._plugin2hookcallers = {} self._plugin_distinfo = [] self.trace = _tracing.TagTracer().get("pluginmanage") - self.hook = _HookRelay(self.trace.root.get("hook")) + self.hook = _HookRelay() if implprefix is not None: warnings.warn( "Support for the `implprefix` arg is now deprecated and will " @@ -321,11 +326,24 @@ same arguments as ``before`` but also a :py:class:`_Result`` object which represents the result of the overall hook call. """ - return _tracing._TracedHookExecution(self, before, after).undo + oldcall = self._inner_hookexec + + def traced_hookexec(hook, hook_impls, kwargs): + before(hook.name, hook_impls, kwargs) + outcome = _Result.from_call(lambda: oldcall(hook, hook_impls, kwargs)) + after(outcome, hook.name, hook_impls, kwargs) + return outcome.get_result() + + self._inner_hookexec = traced_hookexec + + def undo(): + self._inner_hookexec = oldcall + + return undo def enable_tracing(self): """ enable tracing of hook calls and return an undo function. """ - hooktrace = self.hook._trace + hooktrace = self.trace.root.get("hook") def before(hook_name, methods, kwargs): hooktrace.root.indent += 1 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/src/pluggy.egg-info/PKG-INFO new/pluggy-0.13.0/src/pluggy.egg-info/PKG-INFO --- old/pluggy-0.12.0/src/pluggy.egg-info/PKG-INFO 2019-05-27 22:20:08.000000000 +0200 +++ new/pluggy-0.13.0/src/pluggy.egg-info/PKG-INFO 2019-09-10 22:14:46.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: pluggy -Version: 0.12.0 +Version: 0.13.0 Summary: plugin and hook calling mechanisms for python Home-page: https://github.com/pytest-dev/pluggy Author: Holger Krekel @@ -114,6 +114,16 @@ .. towncrier release notes start + pluggy 0.13.0 (2019-09-10) + ========================== + + Trivial/Internal Changes + ------------------------ + + - `#222 <https://github.com/pytest-dev/pluggy/issues/222>`_: Replace ``importlib_metadata`` backport with ``importlib.metadata`` from the + standard library on Python 3.8+. + + pluggy 0.12.0 (2019-05-27) ========================== diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/src/pluggy.egg-info/requires.txt new/pluggy-0.13.0/src/pluggy.egg-info/requires.txt --- old/pluggy-0.12.0/src/pluggy.egg-info/requires.txt 2019-05-27 22:20:08.000000000 +0200 +++ new/pluggy-0.13.0/src/pluggy.egg-info/requires.txt 2019-09-10 22:14:46.000000000 +0200 @@ -1,3 +1,5 @@ + +[:python_version < "3.8"] importlib-metadata>=0.12 [dev] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/testing/test_multicall.py new/pluggy-0.13.0/testing/test_multicall.py --- old/pluggy-0.12.0/testing/test_multicall.py 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/testing/test_multicall.py 2019-09-10 22:14:28.000000000 +0200 @@ -1,22 +1,13 @@ import pytest from pluggy import HookCallError, HookspecMarker, HookimplMarker from pluggy.hooks import HookImpl -from pluggy.callers import _multicall, _legacymulticall, _LegacyMultiCall +from pluggy.callers import _multicall, _legacymulticall hookspec = HookspecMarker("example") hookimpl = HookimplMarker("example") -def test_uses_copy_of_methods(): - out = [lambda: 42] - mc = _LegacyMultiCall(out, {}) - repr(mc) - out[:] = [] - res = mc.execute() - return res == 42 - - def MC(methods, kwargs, firstresult=False): caller = _multicall hookfuncs = [] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/testing/test_pluginmanager.py new/pluggy-0.13.0/testing/test_pluginmanager.py --- old/pluggy-0.12.0/testing/test_pluginmanager.py 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/testing/test_pluginmanager.py 2019-09-10 22:14:28.000000000 +0200 @@ -3,7 +3,7 @@ """ import pytest import types -import importlib_metadata + from pluggy import ( PluginManager, PluginValidationError, @@ -11,6 +11,7 @@ HookimplMarker, HookspecMarker, ) +from pluggy.manager import importlib_metadata hookspec = HookspecMarker("example") diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/testing/test_tracer.py new/pluggy-0.13.0/testing/test_tracer.py --- old/pluggy-0.12.0/testing/test_tracer.py 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/testing/test_tracer.py 2019-09-10 22:14:28.000000000 +0200 @@ -51,11 +51,11 @@ def test_readable_output_dictargs(rootlogger): - out = rootlogger.format_message(["test"], [1]) - assert out == ["1 [test]\n"] + out = rootlogger._format_message(["test"], [1]) + assert out == "1 [test]\n" - out2 = rootlogger.format_message(["test"], ["test", {"a": 1}]) - assert out2 == ["test [test]\n", " a: 1\n"] + out2 = rootlogger._format_message(["test"], ["test", {"a": 1}]) + assert out2 == "test [test]\n a: 1\n" def test_setprocessor(rootlogger): @@ -76,18 +76,3 @@ log2("seen") tags, args = l2[0] assert args == ("seen",) - - -def test_setmyprocessor(rootlogger): - log = rootlogger.get("1") - log2 = log.get("2") - out = [] - log2.setmyprocessor(lambda *args: out.append(args)) - log("not seen") - assert not out - log2(42) - assert len(out) == 1 - tags, args = out[0] - assert "1" in tags - assert "2" in tags - assert args == (42,) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pluggy-0.12.0/tox.ini new/pluggy-0.13.0/tox.ini --- old/pluggy-0.12.0/tox.ini 2019-05-27 22:19:53.000000000 +0200 +++ new/pluggy-0.13.0/tox.ini 2019-09-10 22:14:28.000000000 +0200 @@ -1,5 +1,5 @@ [tox] -envlist=linting,docs,py{27,34,35,36,py,py3}-pytestrelease,py{27,36}-pytest{master,features} +envlist=linting,docs,py{27,34,35,36,37,38,py,py3},py{36,37}-pytest{master,features} [testenv] commands= @@ -9,11 +9,11 @@ setenv= _PYTEST_SETUP_SKIP_PLUGGY_DEP=1 coverage: _PLUGGY_TOX_CMD=coverage run -m pytest + pytestmaster: _PYTEST_DEP=git+https://github.com/pytest-dev/pytest.git@master + pytestfeatures: _PYTEST_DEP=git+https://github.com/pytest-dev/pytest.git@features deps= - pytestrelease: pytest - pytestmaster: git+https://github.com/pytest-dev/pytest.git@master - pytestfeatures: git+https://github.com/pytest-dev/pytest.git@features coverage: coverage + {env:_PYTEST_DEP:pytest} [testenv:benchmark] commands=pytest {posargs:testing/benchmark.py} @@ -38,7 +38,7 @@ minversion=2.0 testpaths = testing #--pyargs --doctest-modules --ignore=.tox -addopts=-ra +addopts=-r a filterwarnings = error