Wed Jul 28 12:14:16 2021 UTC ()
py-sanic: updated to 21.6.1

Version 21.6.1

Bugfixes

Update sanic-routing to allow for better splitting of complex URI templates
Proper handling of chunked request bodies to resolve phantom 503 in logs
Resolve regression in exception logging
Cleanup request info in pipelined requests
Version 21.6.0

Features

Add response.eof() method for closing a stream in a handler

Allow case-insensitive HTTP Upgrade header

Explicit usage of CIMultiDict getters

Consistent use of error loggers

New client_ip access of connection info instance

Alternatate classes on instantiation for Config and Sanic.ctx

Implement new version of AST router

Proper differentiation between alpha and string param types
Adds a slug param type, example: <foo:slug>
Deprecates <foo:string> in favor of <foo:str>
Deprecates <foo:number> in favor of <foo:float>
Adds a route.uri accessor
CLI improvements with new optional params

Add version_prefix to URL builders

Event autoregistration with EVENT_AUTOREGISTER

Require stricter names on Sanic() and Blueprint()

Infinitely reusable and nestable Blueprint and BlueprintGroup

Upgrade websockets dependency to min version

Allow for maximum header sizes to be increased: REQUEST_MAX_HEADER_SIZE

Allow app factory pattern in CLI

Change HTTP methods to enums

Allow auto-reloading on additional directories

Add simple HTTP server to CLI

Additional methods for attaching HTTPMethodView

Bugfixes

Fix UserWarning in ASGI mode for missing __slots__
Fix static request handler logging exception on 404
Fix request.args.pop removes parameters inconsistently
Fix type hinting for load_env
Make sure ASGI ws subprotocols is a list
Fix issue where Blueprint exception handlers do not consistently route to proper handler
Deprecations and Removals

Remove config value REQUEST_BUFFER_QUEUE_SIZE
CompositionView deprecated and marked for removal in 21.12
Deprecate StreamingHTTPResponse
Developer infrastructure

Remove Travis CI in favor of GitHub Actions
Improved Documentation

Fix typo in documentation
Remove documentation for non-existent arguments
Version 21.3.2

Bugfixes

Disable response timeout on websocket connections
Make sure that blueprints with no slash is maintained when applied
Version 21.3.1

Bugfixes

Static files inside subfolders are not accessible (404)
Version 21.3.0

Release Notes

Features

Unified streaming server
New Request.id property
Allow Pathlib Path objects to be passed to app.static() helper
New startup-optimized router
Listeners for main server process
Add raw header info to request object
Introduce Signals API
Add __str__ and __repr__ to Sanic and Blueprint
Enable versioning and strict slash on BlueprintGroup
Make get_app name argument optional
JSON encoder change via app
App and connection level context objects
Bugfixes and issues resolved

Resolve 1420 url_for where strict_slashes are on for a path ending in /
Resolve 1525 Routing is incorrect with some special characters
Resolve 1653 ASGI headers in body
Resolve 1722 Using curl in chunk mode
Resolve 1730 Extra content in ASGI streaming response
Resolve 1749 Restore broken middleware edge cases
Resolve 1785 1804 Synchronous error handlers
Resolve 1790 Protocol errors did not support async error handlers
Resolve 1824 Timeout on specific methods
Resolve 1875 Response timeout error from all routes after returning several timeouts from a specific route
Resolve 1988 Handling of safe methods with body
Raise ValueError when cookie max-age is not an integer
Deprecations and Removals

Config using from_envvar
Config using from_pyfile
Config using from_object
Remove Sanic test client to its own package
Drop Python 3.6 support
Request.endpoint deprecated in favor of Request.name
handler type name prefixes removed (static, websocket, etc)
Developer infrastructure

Create FUNDING.yml
Add codeql to CI pipeline
Codecov configuration updates
Updated setup.py to use find_packages
Improved Documentation

Documentation for sanic.log.* is missing
Add documentation on calver and LTS
Support mounting application elsewhere than at root path
Upgraded type annotations and improved docstrings and API documentation
Fix some examples and docs
Miscellaneous

Request.route property
Better websocket subprotocols support
Resolve bug with middleware in Blueprint Group when passed callable
Moves common logic between Blueprint and Sanic into mixins
Route naming changed to be more consistent
request endpoint is the route name
route names are fully namespaced
Some new convenience decorators:
@app.main_process_start
@app.main_process_stop
@app.before_server_start
@app.after_server_start
@app.before_server_stop
@app.after_server_stop
@app.on_request
@app.on_response
Fixes Allow header that did not include HEAD
Using "name" keyword in url_for for a "static" route where name does not exist
Cannot have multiple app.static() without using the named param
Using "filename" keyword in url_for on a file route
unquote in route def (not automatic)
routes_all is tuples
Handler arguments are kwarg only
request.match_info is now a cached (and not computed) property
Unknown static file mimetype is sent as application/octet-stream
_host keyword in url_for
Add charset default to utf-8 for text and js content types if not specified
Version for a route can be str, float, or int
Route has ctx property
App has routes_static, routes_dynamic, routes_regex
Code cleanup and refactoring
Remove BaseSanic metaclass
Performance adjustments in handle_request_


(adam)
diff -r1.19 -r1.20 pkgsrc/www/py-sanic/Makefile
diff -r1.10 -r1.11 pkgsrc/www/py-sanic/PLIST
diff -r1.16 -r1.17 pkgsrc/www/py-sanic/distinfo
diff -r1.9 -r0 pkgsrc/www/py-sanic/patches/patch-setup.py

cvs diff -r1.19 -r1.20 pkgsrc/www/py-sanic/Makefile (expand / switch to unified diff)

--- pkgsrc/www/py-sanic/Makefile 2021/02/16 18:56:05 1.19
+++ pkgsrc/www/py-sanic/Makefile 2021/07/28 12:14:16 1.20
@@ -1,31 +1,30 @@ @@ -1,31 +1,30 @@
1# $NetBSD: Makefile,v 1.19 2021/02/16 18:56:05 adam Exp $ 1# $NetBSD: Makefile,v 1.20 2021/07/28 12:14:16 adam Exp $
2 2
3DISTNAME= sanic-20.12.2 3DISTNAME= sanic-21.6.1
4PKGNAME= ${PYPKGPREFIX}-${DISTNAME} 4PKGNAME= ${PYPKGPREFIX}-${DISTNAME}
5CATEGORIES= www python 5CATEGORIES= www python
6MASTER_SITES= ${MASTER_SITE_PYPI:=s/sanic/} 6MASTER_SITES= ${MASTER_SITE_PYPI:=s/sanic/}
7 7
8MAINTAINER= pkgsrc-users@NetBSD.org 8MAINTAINER= pkgsrc-users@NetBSD.org
9HOMEPAGE= https://github.com/sanic-org/sanic 9HOMEPAGE= https://github.com/sanic-org/sanic
10COMMENT= Microframework based on uvloop, httptools, and learnings of flask 10COMMENT= Microframework based on uvloop, httptools, and learnings of flask
11LICENSE= mit AND apache-2.0 11LICENSE= mit AND apache-2.0
12 12
13DEPENDS+= ${PYPKGPREFIX}-aiofiles>=0.6.0:../../devel/py-aiofiles 13DEPENDS+= ${PYPKGPREFIX}-aiofiles>=0.6.0:../../devel/py-aiofiles
14DEPENDS+= ${PYPKGPREFIX}-httptools>=0.0.10:../../www/py-httptools 14DEPENDS+= ${PYPKGPREFIX}-httptools>=0.0.10:../../www/py-httptools
15DEPENDS+= ${PYPKGPREFIX}-httpx>=0.15.4:../../www/py-httpx 
16DEPENDS+= ${PYPKGPREFIX}-multidict>=5.0.0:../../databases/py-multidict 15DEPENDS+= ${PYPKGPREFIX}-multidict>=5.0.0:../../databases/py-multidict
17DEPENDS+= ${PYPKGPREFIX}-ujson>=1.35:../../textproc/py-ujson 16DEPENDS+= ${PYPKGPREFIX}-ujson>=1.35:../../textproc/py-ujson
18DEPENDS+= ${PYPKGPREFIX}-uvloop>=0.5.3:../../devel/py-uvloop 17DEPENDS+= ${PYPKGPREFIX}-uvloop>=0.5.3:../../devel/py-uvloop
19DEPENDS+= ${PYPKGPREFIX}-websockets>=8.1:../../www/py-websockets 18DEPENDS+= ${PYPKGPREFIX}-sanic-routing>=0.7.0:../../www/py-sanic-routing
20TEST_DEPENDS+= ${PYPKGPREFIX}-uvicorn-[0-9]*:../../www/py-uvicorn 19DEPENDS+= ${PYPKGPREFIX}-websockets>=9.0:../../www/py-websockets
21 20
22USE_LANGUAGES= # none 21USE_LANGUAGES= # none
23 22
24PYTHON_VERSIONS_INCOMPATIBLE= 27 36 23PYTHON_VERSIONS_INCOMPATIBLE= 27 36
25 24
26post-install: 25post-install:
27 cd ${DESTDIR}${PREFIX}/bin && \ 26 cd ${DESTDIR}${PREFIX}/bin && \
28 ${MV} sanic sanic-${PYVERSSUFFIX} || ${TRUE} 27 ${MV} sanic sanic-${PYVERSSUFFIX} || ${TRUE}
29 28
30.include "../../lang/python/egg.mk" 29.include "../../lang/python/egg.mk"
31.include "../../mk/bsd.pkg.mk" 30.include "../../mk/bsd.pkg.mk"

cvs diff -r1.10 -r1.11 pkgsrc/www/py-sanic/PLIST (expand / switch to unified diff)

--- pkgsrc/www/py-sanic/PLIST 2021/01/03 22:41:44 1.10
+++ pkgsrc/www/py-sanic/PLIST 2021/07/28 12:14:16 1.11
@@ -1,96 +1,132 @@ @@ -1,96 +1,132 @@
1@comment $NetBSD: PLIST,v 1.10 2021/01/03 22:41:44 adam Exp $ 1@comment $NetBSD: PLIST,v 1.11 2021/07/28 12:14:16 adam Exp $
2bin/sanic-${PYVERSSUFFIX} 2bin/sanic-${PYVERSSUFFIX}
3${PYSITELIB}/${EGG_INFODIR}/PKG-INFO 3${PYSITELIB}/${EGG_INFODIR}/PKG-INFO
4${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt 4${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt
5${PYSITELIB}/${EGG_INFODIR}/dependency_links.txt 5${PYSITELIB}/${EGG_INFODIR}/dependency_links.txt
6${PYSITELIB}/${EGG_INFODIR}/entry_points.txt 6${PYSITELIB}/${EGG_INFODIR}/entry_points.txt
7${PYSITELIB}/${EGG_INFODIR}/requires.txt 7${PYSITELIB}/${EGG_INFODIR}/requires.txt
8${PYSITELIB}/${EGG_INFODIR}/top_level.txt 8${PYSITELIB}/${EGG_INFODIR}/top_level.txt
9${PYSITELIB}/sanic/__init__.py 9${PYSITELIB}/sanic/__init__.py
10${PYSITELIB}/sanic/__init__.pyc 10${PYSITELIB}/sanic/__init__.pyc
11${PYSITELIB}/sanic/__init__.pyo 11${PYSITELIB}/sanic/__init__.pyo
12${PYSITELIB}/sanic/__main__.py 12${PYSITELIB}/sanic/__main__.py
13${PYSITELIB}/sanic/__main__.pyc 13${PYSITELIB}/sanic/__main__.pyc
14${PYSITELIB}/sanic/__main__.pyo 14${PYSITELIB}/sanic/__main__.pyo
15${PYSITELIB}/sanic/__version__.py 15${PYSITELIB}/sanic/__version__.py
16${PYSITELIB}/sanic/__version__.pyc 16${PYSITELIB}/sanic/__version__.pyc
17${PYSITELIB}/sanic/__version__.pyo 17${PYSITELIB}/sanic/__version__.pyo
18${PYSITELIB}/sanic/app.py 18${PYSITELIB}/sanic/app.py
19${PYSITELIB}/sanic/app.pyc 19${PYSITELIB}/sanic/app.pyc
20${PYSITELIB}/sanic/app.pyo 20${PYSITELIB}/sanic/app.pyo
21${PYSITELIB}/sanic/asgi.py 21${PYSITELIB}/sanic/asgi.py
22${PYSITELIB}/sanic/asgi.pyc 22${PYSITELIB}/sanic/asgi.pyc
23${PYSITELIB}/sanic/asgi.pyo 23${PYSITELIB}/sanic/asgi.pyo
 24${PYSITELIB}/sanic/base.py
 25${PYSITELIB}/sanic/base.pyc
 26${PYSITELIB}/sanic/base.pyo
24${PYSITELIB}/sanic/blueprint_group.py 27${PYSITELIB}/sanic/blueprint_group.py
25${PYSITELIB}/sanic/blueprint_group.pyc 28${PYSITELIB}/sanic/blueprint_group.pyc
26${PYSITELIB}/sanic/blueprint_group.pyo 29${PYSITELIB}/sanic/blueprint_group.pyo
27${PYSITELIB}/sanic/blueprints.py 30${PYSITELIB}/sanic/blueprints.py
28${PYSITELIB}/sanic/blueprints.pyc 31${PYSITELIB}/sanic/blueprints.pyc
29${PYSITELIB}/sanic/blueprints.pyo 32${PYSITELIB}/sanic/blueprints.pyo
30${PYSITELIB}/sanic/compat.py 33${PYSITELIB}/sanic/compat.py
31${PYSITELIB}/sanic/compat.pyc 34${PYSITELIB}/sanic/compat.pyc
32${PYSITELIB}/sanic/compat.pyo 35${PYSITELIB}/sanic/compat.pyo
33${PYSITELIB}/sanic/config.py 36${PYSITELIB}/sanic/config.py
34${PYSITELIB}/sanic/config.pyc 37${PYSITELIB}/sanic/config.pyc
35${PYSITELIB}/sanic/config.pyo 38${PYSITELIB}/sanic/config.pyo
36${PYSITELIB}/sanic/constants.py 39${PYSITELIB}/sanic/constants.py
37${PYSITELIB}/sanic/constants.pyc 40${PYSITELIB}/sanic/constants.pyc
38${PYSITELIB}/sanic/constants.pyo 41${PYSITELIB}/sanic/constants.pyo
39${PYSITELIB}/sanic/cookies.py 42${PYSITELIB}/sanic/cookies.py
40${PYSITELIB}/sanic/cookies.pyc 43${PYSITELIB}/sanic/cookies.pyc
41${PYSITELIB}/sanic/cookies.pyo 44${PYSITELIB}/sanic/cookies.pyo
42${PYSITELIB}/sanic/deprecated.py 
43${PYSITELIB}/sanic/deprecated.pyc 
44${PYSITELIB}/sanic/deprecated.pyo 
45${PYSITELIB}/sanic/errorpages.py 45${PYSITELIB}/sanic/errorpages.py
46${PYSITELIB}/sanic/errorpages.pyc 46${PYSITELIB}/sanic/errorpages.pyc
47${PYSITELIB}/sanic/errorpages.pyo 47${PYSITELIB}/sanic/errorpages.pyo
48${PYSITELIB}/sanic/exceptions.py 48${PYSITELIB}/sanic/exceptions.py
49${PYSITELIB}/sanic/exceptions.pyc 49${PYSITELIB}/sanic/exceptions.pyc
50${PYSITELIB}/sanic/exceptions.pyo 50${PYSITELIB}/sanic/exceptions.pyo
51${PYSITELIB}/sanic/handlers.py 51${PYSITELIB}/sanic/handlers.py
52${PYSITELIB}/sanic/handlers.pyc 52${PYSITELIB}/sanic/handlers.pyc
53${PYSITELIB}/sanic/handlers.pyo 53${PYSITELIB}/sanic/handlers.pyo
54${PYSITELIB}/sanic/headers.py 54${PYSITELIB}/sanic/headers.py
55${PYSITELIB}/sanic/headers.pyc 55${PYSITELIB}/sanic/headers.pyc
56${PYSITELIB}/sanic/headers.pyo 56${PYSITELIB}/sanic/headers.pyo
57${PYSITELIB}/sanic/helpers.py 57${PYSITELIB}/sanic/helpers.py
58${PYSITELIB}/sanic/helpers.pyc 58${PYSITELIB}/sanic/helpers.pyc
59${PYSITELIB}/sanic/helpers.pyo 59${PYSITELIB}/sanic/helpers.pyo
 60${PYSITELIB}/sanic/http.py
 61${PYSITELIB}/sanic/http.pyc
 62${PYSITELIB}/sanic/http.pyo
60${PYSITELIB}/sanic/log.py 63${PYSITELIB}/sanic/log.py
61${PYSITELIB}/sanic/log.pyc 64${PYSITELIB}/sanic/log.pyc
62${PYSITELIB}/sanic/log.pyo 65${PYSITELIB}/sanic/log.pyo
 66${PYSITELIB}/sanic/mixins/__init__.py
 67${PYSITELIB}/sanic/mixins/__init__.pyc
 68${PYSITELIB}/sanic/mixins/__init__.pyo
 69${PYSITELIB}/sanic/mixins/exceptions.py
 70${PYSITELIB}/sanic/mixins/exceptions.pyc
 71${PYSITELIB}/sanic/mixins/exceptions.pyo
 72${PYSITELIB}/sanic/mixins/listeners.py
 73${PYSITELIB}/sanic/mixins/listeners.pyc
 74${PYSITELIB}/sanic/mixins/listeners.pyo
 75${PYSITELIB}/sanic/mixins/middleware.py
 76${PYSITELIB}/sanic/mixins/middleware.pyc
 77${PYSITELIB}/sanic/mixins/middleware.pyo
 78${PYSITELIB}/sanic/mixins/routes.py
 79${PYSITELIB}/sanic/mixins/routes.pyc
 80${PYSITELIB}/sanic/mixins/routes.pyo
 81${PYSITELIB}/sanic/mixins/signals.py
 82${PYSITELIB}/sanic/mixins/signals.pyc
 83${PYSITELIB}/sanic/mixins/signals.pyo
 84${PYSITELIB}/sanic/models/__init__.py
 85${PYSITELIB}/sanic/models/__init__.pyc
 86${PYSITELIB}/sanic/models/__init__.pyo
 87${PYSITELIB}/sanic/models/asgi.py
 88${PYSITELIB}/sanic/models/asgi.pyc
 89${PYSITELIB}/sanic/models/asgi.pyo
 90${PYSITELIB}/sanic/models/futures.py
 91${PYSITELIB}/sanic/models/futures.pyc
 92${PYSITELIB}/sanic/models/futures.pyo
 93${PYSITELIB}/sanic/models/handler_types.py
 94${PYSITELIB}/sanic/models/handler_types.pyc
 95${PYSITELIB}/sanic/models/handler_types.pyo
 96${PYSITELIB}/sanic/models/protocol_types.py
 97${PYSITELIB}/sanic/models/protocol_types.pyc
 98${PYSITELIB}/sanic/models/protocol_types.pyo
63${PYSITELIB}/sanic/py.typed 99${PYSITELIB}/sanic/py.typed
64${PYSITELIB}/sanic/reloader_helpers.py 100${PYSITELIB}/sanic/reloader_helpers.py
65${PYSITELIB}/sanic/reloader_helpers.pyc 101${PYSITELIB}/sanic/reloader_helpers.pyc
66${PYSITELIB}/sanic/reloader_helpers.pyo 102${PYSITELIB}/sanic/reloader_helpers.pyo
67${PYSITELIB}/sanic/request.py 103${PYSITELIB}/sanic/request.py
68${PYSITELIB}/sanic/request.pyc 104${PYSITELIB}/sanic/request.pyc
69${PYSITELIB}/sanic/request.pyo 105${PYSITELIB}/sanic/request.pyo
70${PYSITELIB}/sanic/response.py 106${PYSITELIB}/sanic/response.py
71${PYSITELIB}/sanic/response.pyc 107${PYSITELIB}/sanic/response.pyc
72${PYSITELIB}/sanic/response.pyo 108${PYSITELIB}/sanic/response.pyo
73${PYSITELIB}/sanic/router.py 109${PYSITELIB}/sanic/router.py
74${PYSITELIB}/sanic/router.pyc 110${PYSITELIB}/sanic/router.pyc
75${PYSITELIB}/sanic/router.pyo 111${PYSITELIB}/sanic/router.pyo
76${PYSITELIB}/sanic/server.py 112${PYSITELIB}/sanic/server.py
77${PYSITELIB}/sanic/server.pyc 113${PYSITELIB}/sanic/server.pyc
78${PYSITELIB}/sanic/server.pyo 114${PYSITELIB}/sanic/server.pyo
79${PYSITELIB}/sanic/static.py 115${PYSITELIB}/sanic/signals.py
80${PYSITELIB}/sanic/static.pyc 116${PYSITELIB}/sanic/signals.pyc
81${PYSITELIB}/sanic/static.pyo 117${PYSITELIB}/sanic/signals.pyo
82${PYSITELIB}/sanic/testing.py 118${PYSITELIB}/sanic/simple.py
83${PYSITELIB}/sanic/testing.pyc 119${PYSITELIB}/sanic/simple.pyc
84${PYSITELIB}/sanic/testing.pyo 120${PYSITELIB}/sanic/simple.pyo
85${PYSITELIB}/sanic/utils.py 121${PYSITELIB}/sanic/utils.py
86${PYSITELIB}/sanic/utils.pyc 122${PYSITELIB}/sanic/utils.pyc
87${PYSITELIB}/sanic/utils.pyo 123${PYSITELIB}/sanic/utils.pyo
88${PYSITELIB}/sanic/views.py 124${PYSITELIB}/sanic/views.py
89${PYSITELIB}/sanic/views.pyc 125${PYSITELIB}/sanic/views.pyc
90${PYSITELIB}/sanic/views.pyo 126${PYSITELIB}/sanic/views.pyo
91${PYSITELIB}/sanic/websocket.py 127${PYSITELIB}/sanic/websocket.py
92${PYSITELIB}/sanic/websocket.pyc 128${PYSITELIB}/sanic/websocket.pyc
93${PYSITELIB}/sanic/websocket.pyo 129${PYSITELIB}/sanic/websocket.pyo
94${PYSITELIB}/sanic/worker.py 130${PYSITELIB}/sanic/worker.py
95${PYSITELIB}/sanic/worker.pyc 131${PYSITELIB}/sanic/worker.pyc
96${PYSITELIB}/sanic/worker.pyo 132${PYSITELIB}/sanic/worker.pyo

cvs diff -r1.16 -r1.17 pkgsrc/www/py-sanic/distinfo (expand / switch to unified diff)

--- pkgsrc/www/py-sanic/distinfo 2021/02/16 18:56:05 1.16
+++ pkgsrc/www/py-sanic/distinfo 2021/07/28 12:14:16 1.17
@@ -1,7 +1,6 @@ @@ -1,7 +1,6 @@
1$NetBSD: distinfo,v 1.16 2021/02/16 18:56:05 adam Exp $ 1$NetBSD: distinfo,v 1.17 2021/07/28 12:14:16 adam Exp $
2 2
3SHA1 (sanic-20.12.2.tar.gz) = 8802e0cc5dd7c3752faccdda92adbdd25aa410a3 3SHA1 (sanic-21.6.1.tar.gz) = 75001f74aa39be97b6a7cc0884737ae05b6e85df
4RMD160 (sanic-20.12.2.tar.gz) = 930c877e13771ab012de385d67af733d973b4176 4RMD160 (sanic-21.6.1.tar.gz) = 260c06a4f05305fd47811c961c9960cdd64cb09e
5SHA512 (sanic-20.12.2.tar.gz) = dee7e1688fb3f450b490d95dae7ec47b2f6d2823756e86480931f0f3a56862d3e97df31eb091b66cecc7a141d4a82b4e4bd615d7762767e8b78e13030be9d5d4 5SHA512 (sanic-21.6.1.tar.gz) = ff1ea9269b25c60be3cb982f42b9ed391111b818f10efb02c221e7d150a3f50a6620385691e004e808b5043d1bbf3a2c01714c5871ff86cfc8a2c86b0b375474
6Size (sanic-20.12.2.tar.gz) = 147979 bytes 6Size (sanic-21.6.1.tar.gz) = 173788 bytes
7SHA1 (patch-setup.py) = bcd9b4baaff7c6ffc08d34d0ed2db1e35e97dd7f 

File Deleted: pkgsrc/www/py-sanic/patches/Attic/patch-setup.py