Skip to content

Releases: seanmonstar/warp

v0.1.13

26 Jul 16:56
Compare
Choose a tag to compare
  • Features:
    • Implement Reply for Vec<u8> and &'static [u8].
    • Set content-type header automatically for string and bytes replies.
    • Add expose_headers to warp::cors filter.

v0.1.12

29 Jan 20:16
Compare
Choose a tag to compare
  • Features:
    • Implement PartialEq, Eq, and Clone for warp::ws::Message.
  • Fixes:
    • Fix panic when incoming request URI may not have a path (such as CONNECT requests).

v0.1.11

14 Jan 22:40
Compare
Choose a tag to compare
  • Features:
    • Add warp::sse filters for handling Server-Sent-Events.
    • Add allow_headers to warp::cors filter.
  • Fixes:
    • Fix TLS handshake to close the connection if handshake fails.

v0.1.10

29 Dec 02:22
Compare
Choose a tag to compare
  • Features:
    • Add optional TLS support. Enable the tls feature, and then use Server::tls.
    • Add warp::cors filter for CORS support.
    • Add warp::addr::remote to access the remote address of a request.
    • Add warp::log::custom to support customizing of access logging.
    • Add warp::test::ws to improve testing Websocket filters.

v0.1.9

31 Oct 18:38
Compare
Choose a tag to compare
  • Features:
    • Add warp::ext::get and warp::ext::set to set request extensions.
    • Add Filter::untuple_one to unroll nested tuple layers from extractions.
    • Add Ws2::max_send_queue configuration method.
    • Add ws::Message::is_ping method, and yield pings to user code.
  • Fixes:
    • Fix panic in debug mode when receiving a websocket ping.

v0.1.8

25 Oct 23:53
Compare
Choose a tag to compare
  • Features:
    • Improved flexibility of Rejection system.

      The Rejection type can now nest and combine arbitrary rejections,
      so it is no longer bound to a small set of meanings. The ranking of
      status codes is still used to determine which rejection gets priority.

      A different priority can be implemented by handling rejections with
      a Filter::recover, and searching for causes in order via
      Rejection::find_cause.

      • Adds warp::reject::custom() to create a Rejection with
        any Into<Box<std::error::Error>>. These rejections should be
        handled with an eventual Filter::recover. Any unhandled
        custom rejections are considered a server error.
      • Deprecates Rejection::with. Use custom rejections instead.
      • Deprecates Rejection::into_cause, as it can no longer work. Always
        returns Err(Rejection).
      • Deprecates Rejection::json, since the format needed is too generic.
        The errors.rs example shows how to send custom JSON when recovering
        from rejections.
      • Deprecates warp::reject(), since it current signals a 400 Bad Request, but in newer versions, it will signal 404 Not Found.
        It's deprecated simply to warn that the semantics are changing,
        but the function won't actually go away.
      • Deprecates reject::bad_request(), reject::forbidden(), and
        reject::server_error(). Uses custom rejections instead.
    • Renamed warp::path::index to warp::path::end.

v0.1.7

15 Oct 17:32
Compare
Choose a tag to compare
  • Features:

    • Export the types returned from the warp::body::stream() filter, BodyStream and StreamBuf.
    • Deprecated Rejection::into_cause, since an upcoming Rejection refactor will make it impossible to support.
  • Fixes:

    • Fix websocket filters to do a case-insensitive match of the Connection header.

v0.1.6

05 Oct 22:20
Compare
Choose a tag to compare
  • Features:
    • Add Conditional and Range request support for warp::fs filters.
    • Relaxed bounds on Rejection::with to no longer need to be Sized.
    • Add warp::path::peek() which gets the unmatched tail without adjusting the currently matched path.

v0.1.5

03 Oct 21:00
Compare
Choose a tag to compare
  • Features:

    • Serve index.html automatically with warp::fs::dir filter.
    • Include last-modified header with warp::fs filters.
    • Add warp::redirect to easily reply with redirections.
    • Add warp::reply::{with_status, with_header} to wrap impl Replys directly with a new status code or header.
    • Add support for running a warp Server with a custom source of incoming connections.
      • Server::run_incoming to have the runtime started automatically.
      • Server::serve_incoming to get a future to run on existing runtime.
      • These can be used to support Unix Domain Sockets, TLS, and other transports.
    • Add Rejection::into_cause() to retrieve the original error of a rejection back.
    • Add Rejection::json() to convert a rejection into a JSON response.
  • Fixes

    • Internal errors in warp that result in rendering a 500 Internal Server Error are now also logged at the error level.

v0.1.4

03 Oct 20:59
Compare
Choose a tag to compare
  • Features:
    • Add warp::reply::with::headers(HeaderMap) filter wrapper.
    • Add warp::cookie::optional() to get an optional cookie value.
    • Add warp::path::full() to be able to extract the full request path without affecting route matching.
    • Add graceful shutdown support to the Server.
    • Allow empty query strings to be treated as for warp::query().