git.iko.soy/typeable/nixpkgs
on master help sign in
python3Packages.sanic: 21.3.2 -> 21.3.4

While we're at it, revise the dependencies lists; there's been a couple of break-ups with 21.3.0.

commitbd815d21219840d1aa688083179323ad0161fff5 authorAluísio Augusto Silva Gonçalves <aluisio@aasg.name> dateTue 27 Apr 2021, 10:31 (6 years ago) parent192b28a
2 files changed+21−16
pkgs/development/python-modules/sanic/default.nix+18−16 pkgs/top-level/python-packages.nix+3
pkgs/development/python-modules/sanic/default.nix+18−16
@@ -1,42 +1,44 @@
11{ lib, buildPythonPackage, fetchPypi, doCheck ? true
2−, aiofiles, httptools, httpx, multidict, ujson, uvloop, websockets
3−, pytestCheckHook, beautifulsoup4, gunicorn, httpcore, uvicorn
4−, pytest-asyncio, pytest-benchmark, pytest-dependency, pytest-sanic, pytest-sugar, pytestcov
2+, aiofiles, httptools, multidict, sanic-routing, ujson, uvloop, websockets
3+, pytestCheckHook, beautifulsoup4, gunicorn, uvicorn, sanic-testing
4+, pytest-benchmark, pytest-sanic, pytest-sugar, pytestcov
55}:
66
77buildPythonPackage rec {
88 pname = "sanic";
9− version = "21.3.2";
9+ version = "21.3.4";
1010
1111 src = fetchPypi {
1212 inherit pname version;
13− sha256 = "84a04c5f12bf321bed3942597787f1854d15c18f157aebd7ced8c851ccc49e08";
13+ sha256 = "1cbd12b9138b3ca69656286b0be91fff02b826e8cb72dd76a2ca8c5eb1288d8e";
1414 };
1515
1616 postPatch = ''
17+ # Loosen dependency requirements.
1718 substituteInPlace setup.py \
18− --replace '"multidict==5.0.0"' '"multidict"' \
19− --replace '"httpx==0.15.4"' '"httpx"' \
20− --replace '"httpcore==0.3.0"' '"httpcore"' \
21− --replace '"pytest==5.2.1"' '"pytest"'
19+ --replace '"pytest==5.2.1"' '"pytest"' \
20+ --replace '"gunicorn==20.0.4"' '"gunicorn"' \
21+ --replace '"pytest-sanic",' ""
22+ # Patch a request headers test to allow brotli encoding
23+ # (we build httpx with brotli support, upstream doesn't).
24+ substituteInPlace tests/test_headers.py \
25+ --replace "deflate\r\n" "deflate, br\r\n"
2226 '';
2327
2428 propagatedBuildInputs = [
25− aiofiles httptools httpx multidict ujson uvloop websockets
29+ sanic-routing httptools uvloop ujson aiofiles websockets multidict
2630 ];
2731
2832 checkInputs = [
29− pytestCheckHook beautifulsoup4 gunicorn httpcore uvicorn
30− pytest-asyncio pytest-benchmark pytest-dependency pytest-sanic pytest-sugar pytestcov
33+ sanic-testing gunicorn pytestcov beautifulsoup4 pytest-sanic pytest-sugar
34+ pytest-benchmark pytestCheckHook uvicorn
3135 ];
3236
3337 inherit doCheck;
3438
3539 disabledTests = [
3640 "test_gunicorn" # No "examples" directory in pypi distribution.
37− "test_logo" # Fails to filter out "DEBUG asyncio:selector_events.py:59 Using selector: EpollSelector"
3841 "test_zero_downtime" # No "examples.delayed_response.app" module in pypi distribution.
39− "test_reloader_live" # OSError: [Errno 98] error while attempting to bind on address ('127.0.0.1', 42104)
4042 ];
4143
4244 __darwinAllowLocalNetworking = true;
@@ -45,8 +47,8 @@ buildPythonPackage rec {
4547
4648 meta = with lib; {
4749 description = "A microframework based on uvloop, httptools, and learnings of flask";
48− homepage = "https://github.com/channelcat/sanic/";
50+ homepage = "https://github.com/sanic-org/sanic/";
4951 license = licenses.mit;
50− maintainers = [ maintainers.costrouc ];
52+ maintainers = with maintainers; [ costrouc AluisioASG ];
5153 };
5254}
pkgs/top-level/python-packages.nix+3
@@ -7201,6 +7201,9 @@ in {
72017201 doCheck = false;
72027202 meta.broken = false;
72037203 });
7204+ # Don't pass any `sanic` to avoid dependency loops. `sanic-testing`
7205+ # has special logic to disable tests when this is the case.
7206+ sanic-testing = self.sanic-testing.override { sanic = null; };
72047207 };
72057208
72067209 sanic-auth = callPackage ../development/python-modules/sanic-auth { };