diff options
-rw-r--r-- | Cargo.toml | 7 | ||||
-rw-r--r-- | tests/api.py | 4 |
2 files changed, 9 insertions, 2 deletions
@@ -28,13 +28,18 @@ subtle = "2.4.1" time = { version = "0.3.11", features = [ "serde" ] } url = "2.2.2" validator = { version = "0.15", features = [ "derive" ] } -web-push = "0.9.2" [dependencies.lettre] version = "0.10" default-features = false features = [ "smtp-transport", "hostname", "builder", "tokio1-native-tls", "serde" ] +# default client (isahc) uses libnghttp2-sys which stopped building in nix +[dependencies.web-push] +version = "0.9.2" +default-features = false +features = ["hyper-client"] + [dev-dependencies] hex-literal = "0.3.4" diff --git a/tests/api.py b/tests/api.py index da82d37..f76abc7 100644 --- a/tests/api.py +++ b/tests/api.py @@ -208,7 +208,9 @@ class PushServer: self.send_response(200) self.end_headers() - q.put((self.path, self.headers, self.rfile.read(int(self.headers['content-length'])))) + q.put((self.path, + self.headers, + self.rfile.read(int(self.headers.get('content-length', 0))))) server = self.server = http.server.ThreadingHTTPServer(("localhost", PUSH_PORT), Handler) threading.Thread(target=server.serve_forever).start() |