pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/sysutils/py-structlog



Module Name:    pkgsrc
Committed By:   adam
Date:           Sun Feb  7 15:42:49 UTC 2021

Modified Files:
        pkgsrc/sysutils/py-structlog: Makefile PLIST distinfo

Log Message:
py-structlog: updated to 20.2.0

20.2.0

Backward-incompatible changes:

- Python 2.7 and 3.5 aren't supported anymore.
  The package meta data should ensure that you keep getting 20.1.0 on those versions.

- ``structlog`` is now fully type-annotated.
  This won't break your applications, but if you use Mypy, it will most likely break your CI.

  Check out the new chapter on typing for details.

Deprecations:

- Accessing the ``_context`` attribute of a bound logger is now deprecated.
  Please use the new ``structlog.get_context()``.

Changes:

- ``structlog`` has now type hints for all of its APIs!
  Since ``structlog`` is highly dynamic and configurable, this led to a few concessions like a specialized ``structlog.stdlib.get_logger()`` whose only difference to ``structlog.get_logger()`` is 
that it has the correct type hints.

  We consider them provisional for the time being – i.e. the backward compatibility does not apply to them in its full strength until we feel we got it right.
  Please feel free to provide feedback!
- Added ``structlog.make_filtering_logger`` that can be used like ``configure(wrapper_class=make_filtering_bound_logger(logging.INFO))``.
  It creates a highly optimized bound logger whose inactive methods only consist of a ``return None``.
  This is now also the default logger.
- As a complement, ``structlog.stdlib.add_log_level()`` can now additionally be imported as ``structlog.processors.add_log_level`` since it just adds the method name to the event dict.
- ``structlog.processors.add_log_level()`` is now part of the default configuration.
- ``structlog.stdlib.ProcessorFormatter`` no longer uses exceptions for control flow, allowing ``foreign_pre_chain`` processors to use ``sys.exc_info()`` to access the real exception.
- Added ``structlog.BytesLogger`` to avoid unnecessary encoding round trips.
  Concretely this is useful with *orjson* which returns bytes.
- The final processor now also may return bytes that are passed untouched to the wrapped logger.
- ``structlog.get_context()`` allows you to retrieve the original context of a bound logger.
- ``structlog.PrintLogger`` now supports ``copy.deepcopy()``.
- Added ``structlog.testing.CapturingLogger`` for more unit testing goodness.
- Added ``structlog.stdlib.AsyncBoundLogger`` that executes logging calls in a thread executor and therefore doesn't block.


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 pkgsrc/sysutils/py-structlog/Makefile
cvs rdiff -u -r1.3 -r1.4 pkgsrc/sysutils/py-structlog/PLIST
cvs rdiff -u -r1.9 -r1.10 pkgsrc/sysutils/py-structlog/distinfo

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/sysutils/py-structlog/Makefile
diff -u pkgsrc/sysutils/py-structlog/Makefile:1.10 pkgsrc/sysutils/py-structlog/Makefile:1.11
--- pkgsrc/sysutils/py-structlog/Makefile:1.10  Wed Sep 30 07:01:52 2020
+++ pkgsrc/sysutils/py-structlog/Makefile       Sun Feb  7 15:42:49 2021
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.10 2020/09/30 07:01:52 adam Exp $
+# $NetBSD: Makefile,v 1.11 2021/02/07 15:42:49 adam Exp $
 
-DISTNAME=      structlog-20.1.0
+DISTNAME=      structlog-20.2.0
 PKGNAME=       ${PYPKGPREFIX}-${DISTNAME}
 CATEGORIES=    sysutils python
 MASTER_SITES=  ${MASTER_SITE_PYPI:=s/structlog/}
@@ -10,16 +10,23 @@ HOMEPAGE=   http://www.structlog.org/
 COMMENT=       Painless structural logging
 LICENSE=       apache-2.0 AND mit
 
-DEPENDS+=      ${PYPKGPREFIX}-six-[0-9]*:../../lang/py-six
 TEST_DEPENDS+= ${PYPKGPREFIX}-freezegun>=0.2.8:../../devel/py-freezegun
 TEST_DEPENDS+= ${PYPKGPREFIX}-pretend-[0-9]*:../../devel/py-pretend
 TEST_DEPENDS+= ${PYPKGPREFIX}-simplejson-[0-9]*:../../converters/py-simplejson
+TEST_DEPENDS+= ${PYPKGPREFIX}-test-asyncio-[0-9]*:../../devel/py-test-asyncio
+TEST_DEPENDS+= ${PYPKGPREFIX}-test-randomly-[0-9]*:../../devel/py-test-randomly
 TEST_DEPENDS+= ${PYPKGPREFIX}-test-runner-[0-9]*:../../devel/py-test-runner
-TEST_DEPENDS+= ${PYPKGPREFIX}-twisted-[0-9]*:../../net/py-twisted
+
+.include "../../lang/python/pyversion.mk"
+.if ${_PYTHON_VERSION} < 38
+DEPENDS+=      ${PYPKGPREFIX}-typing-extensions-[0-9]*:../../devel/py-typing-extensions
+.endif
 
 USE_LANGUAGES= # none
 
 PYSETUPTESTTARGET=     pytest
 
+PYTHON_VERSIONS_INCOMPATIBLE=  27
+
 .include "../../lang/python/egg.mk"
 .include "../../mk/bsd.pkg.mk"

Index: pkgsrc/sysutils/py-structlog/PLIST
diff -u pkgsrc/sysutils/py-structlog/PLIST:1.3 pkgsrc/sysutils/py-structlog/PLIST:1.4
--- pkgsrc/sysutils/py-structlog/PLIST:1.3      Wed Sep 30 07:01:52 2020
+++ pkgsrc/sysutils/py-structlog/PLIST  Sun Feb  7 15:42:49 2021
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.3 2020/09/30 07:01:52 adam Exp $
+@comment $NetBSD: PLIST,v 1.4 2021/02/07 15:42:49 adam Exp $
 ${PYSITELIB}/${EGG_INFODIR}/PKG-INFO
 ${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt
 ${PYSITELIB}/${EGG_INFODIR}/dependency_links.txt
@@ -20,6 +20,12 @@ ${PYSITELIB}/structlog/_frames.pyo
 ${PYSITELIB}/structlog/_generic.py
 ${PYSITELIB}/structlog/_generic.pyc
 ${PYSITELIB}/structlog/_generic.pyo
+${PYSITELIB}/structlog/_greenlets.py
+${PYSITELIB}/structlog/_greenlets.pyc
+${PYSITELIB}/structlog/_greenlets.pyo
+${PYSITELIB}/structlog/_log_levels.py
+${PYSITELIB}/structlog/_log_levels.pyc
+${PYSITELIB}/structlog/_log_levels.pyo
 ${PYSITELIB}/structlog/_loggers.py
 ${PYSITELIB}/structlog/_loggers.pyc
 ${PYSITELIB}/structlog/_loggers.pyo
@@ -38,6 +44,7 @@ ${PYSITELIB}/structlog/exceptions.pyo
 ${PYSITELIB}/structlog/processors.py
 ${PYSITELIB}/structlog/processors.pyc
 ${PYSITELIB}/structlog/processors.pyo
+${PYSITELIB}/structlog/py.typed
 ${PYSITELIB}/structlog/stdlib.py
 ${PYSITELIB}/structlog/stdlib.pyc
 ${PYSITELIB}/structlog/stdlib.pyo
@@ -50,3 +57,6 @@ ${PYSITELIB}/structlog/threadlocal.pyo
 ${PYSITELIB}/structlog/twisted.py
 ${PYSITELIB}/structlog/twisted.pyc
 ${PYSITELIB}/structlog/twisted.pyo
+${PYSITELIB}/structlog/types.py
+${PYSITELIB}/structlog/types.pyc
+${PYSITELIB}/structlog/types.pyo

Index: pkgsrc/sysutils/py-structlog/distinfo
diff -u pkgsrc/sysutils/py-structlog/distinfo:1.9 pkgsrc/sysutils/py-structlog/distinfo:1.10
--- pkgsrc/sysutils/py-structlog/distinfo:1.9   Wed Sep 30 07:01:52 2020
+++ pkgsrc/sysutils/py-structlog/distinfo       Sun Feb  7 15:42:49 2021
@@ -1,6 +1,6 @@
-$NetBSD: distinfo,v 1.9 2020/09/30 07:01:52 adam Exp $
+$NetBSD: distinfo,v 1.10 2021/02/07 15:42:49 adam Exp $
 
-SHA1 (structlog-20.1.0.tar.gz) = 8e0fe9ee26c4d39a0b96be7ceeea12e3565ba691
-RMD160 (structlog-20.1.0.tar.gz) = 30cdae480081f30c8f51aba859eec94758e7d2af
-SHA512 (structlog-20.1.0.tar.gz) = 87e4909e4a8cee396cc9b78212f13819632c303448bea28e78d574b981435aa29dc5620d59785788ae165af805761cbf97fa4d1ec49a3bf3b887ae76c91b18f3
-Size (structlog-20.1.0.tar.gz) = 332376 bytes
+SHA1 (structlog-20.2.0.tar.gz) = e7a1f2fb6ed8ba4627c2211bbebcddc71eadec1d
+RMD160 (structlog-20.2.0.tar.gz) = f4b2adfb97efb5a0018fd1003f8d162e787daa05
+SHA512 (structlog-20.2.0.tar.gz) = 950807ce131464e102807e2ee17a830ad227110a12a05078dc42f97588b77b0dcab78428aae3fabb2d6cd1a249f5cec05a95acb3097602af2ab41b7bcc0d099a
+Size (structlog-20.2.0.tar.gz) = 371793 bytes



Home | Main Index | Thread Index | Old Index