pkgsrc-Changes archive

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

CVS commit: pkgsrc/www/py-websockets



Module Name:    pkgsrc
Committed By:   adam
Date:           Tue Nov 23 21:02:13 UTC 2021

Modified Files:
        pkgsrc/www/py-websockets: Makefile PLIST distinfo

Log Message:
py-websockets: updated to 10.1

10.1

New features

Added a tutorial.

Made the second parameter of connection handlers optional. It will be deprecated in the next major release. The request path is available in the :attr:`~legacy.protocol.WebSocketCommonProtocol.path` 
attribute of the first argument.

If you implemented the connection handler of a server as:

async def handler(request, path):
    ...
You should replace it by:

async def handler(request):
    path = request.path  # if handler() uses the path argument
    ...
Added python -m websockets --version.

Improvements

Added wheels for Python 3.10, PyPy 3.7, and for more platforms.
Reverted optimization of default compression settings for clients, mainly to avoid triggering bugs in poorly implemented servers like AWS API Gateway.
Mirrored the entire :class:`~asyncio.Server` API in :class:`~server.WebSocketServer`.
Improved performance for large messages on ARM processors.
Documented how to auto-reload on code changes in development.
Bug fixes

Avoided half-closing TCP connections that are already closed.

10.0

Backwards-incompatible changes

websockets 10.0 requires Python ≥ 3.7.

websockets 9.1 is the last version supporting Python 3.6.

The loop parameter is deprecated from all APIs.

This reflects a decision made in Python 3.8. See the release notes of Python 3.10 for details.

The loop parameter is also removed from :class:`~server.WebSocketServer`. This should be transparent.

:func:`~client.connect` times out after 10 seconds by default.

You can adjust the timeout with the open_timeout parameter. Set it to :obj:`None` to disable the timeout entirely.

The legacy_recv option is deprecated.

See the release notes of websockets 3.0 for details.

The signature of :exc:`~exceptions.ConnectionClosed` changed.

If you raise :exc:`~exceptions.ConnectionClosed` or a subclass, rather than catch them when websockets raises them, you must change your code.

A msg parameter was added to :exc:`~exceptions.InvalidURI`.

If you raise :exc:`~exceptions.InvalidURI`, rather than catch it when websockets raises it, you must change your code.

New features

websockets 10.0 introduces a Sans-I/O API for easier integration in third-party libraries.

If you're integrating websockets in a library, rather than just using it, look at the :doc:`Sans-I/O integration guide <../howto/sansio>`.

Added compatibility with Python 3.10.
Added :func:`~websockets.broadcast` to send a message to many clients.
Added support for reconnecting automatically by using :func:`~client.connect` as an asynchronous iterator.
Added open_timeout to :func:`~client.connect`.
Documented how to integrate with Django.
Documented how to deploy websockets in production, with several options.
Documented how to authenticate connections.
Documented how to broadcast messages to many connections.
Improvements

Improved logging. See the :doc:`logging guide <../topics/logging>`.
Optimized default compression settings to reduce memory usage.
Optimized processing of client-to-server messages when the C extension isn't available.
Supported relative redirects in :func:`~client.connect`.
Handled TCP connection drops during the opening handshake.
Made it easier to customize authentication with :meth:`~auth.BasicAuthWebSocketServerProtocol.check_credentials`.
Provided additional information in :exc:`~exceptions.ConnectionClosed` exceptions.
Clarified several exceptions or log messages.
Restructured documentation.
Improved API documentation.
Extended FAQ.
Bug fixes

Avoided a crash when receiving a ping while the connection is closing.


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 pkgsrc/www/py-websockets/Makefile \
    pkgsrc/www/py-websockets/distinfo
cvs rdiff -u -r1.10 -r1.11 pkgsrc/www/py-websockets/PLIST

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

Modified files:

Index: pkgsrc/www/py-websockets/Makefile
diff -u pkgsrc/www/py-websockets/Makefile:1.12 pkgsrc/www/py-websockets/Makefile:1.13
--- pkgsrc/www/py-websockets/Makefile:1.12      Fri Jun  4 12:46:55 2021
+++ pkgsrc/www/py-websockets/Makefile   Tue Nov 23 21:02:13 2021
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.12 2021/06/04 12:46:55 adam Exp $
+# $NetBSD: Makefile,v 1.13 2021/11/23 21:02:13 adam Exp $
 
-DISTNAME=      websockets-9.1
+DISTNAME=      websockets-10.1
 PKGNAME=       ${PYPKGPREFIX}-${DISTNAME}
 CATEGORIES=    www python
 MASTER_SITES=  ${MASTER_SITE_PYPI:=w/websockets/}
@@ -10,7 +10,7 @@ HOMEPAGE=     https://github.com/aaugustin/w
 COMMENT=       Implementation of the WebSocket Protocol (RFC 6455)
 LICENSE=       modified-bsd
 
-PYTHON_VERSIONS_INCOMPATIBLE=  27
+PYTHON_VERSIONS_INCOMPATIBLE=  27 36
 
 .include "../../lang/python/egg.mk"
 .include "../../mk/bsd.pkg.mk"
Index: pkgsrc/www/py-websockets/distinfo
diff -u pkgsrc/www/py-websockets/distinfo:1.12 pkgsrc/www/py-websockets/distinfo:1.13
--- pkgsrc/www/py-websockets/distinfo:1.12      Tue Oct 26 11:30:51 2021
+++ pkgsrc/www/py-websockets/distinfo   Tue Nov 23 21:02:13 2021
@@ -1,5 +1,5 @@
-$NetBSD: distinfo,v 1.12 2021/10/26 11:30:51 nia Exp $
+$NetBSD: distinfo,v 1.13 2021/11/23 21:02:13 adam Exp $
 
-BLAKE2s (websockets-9.1.tar.gz) = 8530ced9b91e4adb787d33ad525452ec5eb3cfb0bf63ad906a2e86f84359e1ba
-SHA512 (websockets-9.1.tar.gz) = b3459a0e11d5af6f4979dec4c63cd09c84efb06870a6cf674036c86bf9333e8442ee9768d03c95bae7e55cbf7f21d31caa93f9c6b1fba0b80a7b44c45f41bc96
-Size (websockets-9.1.tar.gz) = 76694 bytes
+BLAKE2s (websockets-10.1.tar.gz) = e16003933b6bcf02733b80e02a6de01d2688034e25ecc2f03a8b86c36e734094
+SHA512 (websockets-10.1.tar.gz) = b329f1853a6c077adbdca92c453cbd449d1d0d932fe5a919092a674701d785ad43054c104554b54dc490ea647dfad1a9d95404e078447c57650902e36eb2d878
+Size (websockets-10.1.tar.gz) = 83091 bytes

Index: pkgsrc/www/py-websockets/PLIST
diff -u pkgsrc/www/py-websockets/PLIST:1.10 pkgsrc/www/py-websockets/PLIST:1.11
--- pkgsrc/www/py-websockets/PLIST:1.10 Mon May 17 10:21:09 2021
+++ pkgsrc/www/py-websockets/PLIST      Tue Nov 23 21:02:13 2021
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.10 2021/05/17 10:21:09 adam Exp $
+@comment $NetBSD: PLIST,v 1.11 2021/11/23 21:02:13 adam Exp $
 ${PYSITELIB}/${EGG_INFODIR}/PKG-INFO
 ${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt
 ${PYSITELIB}/${EGG_INFODIR}/dependency_links.txt
@@ -58,6 +58,9 @@ ${PYSITELIB}/websockets/legacy/auth.pyo
 ${PYSITELIB}/websockets/legacy/client.py
 ${PYSITELIB}/websockets/legacy/client.pyc
 ${PYSITELIB}/websockets/legacy/client.pyo
+${PYSITELIB}/websockets/legacy/compatibility.py
+${PYSITELIB}/websockets/legacy/compatibility.pyc
+${PYSITELIB}/websockets/legacy/compatibility.pyo
 ${PYSITELIB}/websockets/legacy/framing.py
 ${PYSITELIB}/websockets/legacy/framing.pyc
 ${PYSITELIB}/websockets/legacy/framing.pyo



Home | Main Index | Thread Index | Old Index