Skip to content

Latest commit

 

History

History
605 lines (346 loc) · 23.4 KB

File metadata and controls

605 lines (346 loc) · 23.4 KB

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

[Unreleased]

0.2.10 - 2025-11-10

⛰️ Features

  • Minimize diagnostic noise when Pavex attributes emit an error (#559) (by @Duckaet) - #559
  • Emit an error if #[pavex::methods] is used on an impl block with no Pavex-annotated methods (by @Duckaet) - #558

Contributors

  • @LukeMathWalker
  • @Duckaet

0.2.9 - 2025-10-06

⛰️ Features

  • Upgrade to latest nightly (2025-10-04) (by @LukeMathWalker) - #553

Contributors

  • @LukeMathWalker

0.2.5 - 2025-09-26

⛰️ Features

  • Don't raise an error for malformed request cookies (by @LukeMathWalker) - #526
  • Implement Debug for pavex::Response (by @LukeMathWalker) - #525

🐛 Bug Fixes

  • Replace '{CONSOLE_URL}' with the concrete URL value before showing the error message to the user (by @LukeMathWalker) - #540

Contributors

  • @LukeMathWalker

0.2.4 - 2025-08-09

📚 Documentation

  • Document allow(unused) for #[pavex::prebuilt] (by @LukeMathWalker) - #519

Contributors

  • @LukeMathWalker

0.2.3 - 2025-08-04

⛰️ Features

  • Emit a warning if a type marked as prebuilt doesn't get used (by @LukeMathWalker) - #516

Contributors

  • @LukeMathWalker

0.2.2 - 2025-03-22

⛰️ Features

  • Use the default session configuration if the user hasn't specified one, rather than throwing an error.

0.2.1 - 2025-03-22

‼️ Breaking changes

  • A complete revamp of the dependency injection system, using annotations and imports rather than manually specified paths. Check out the updated guide on pavex.dev for a thorough overview of the new system.
  • Response and IntoResponse are now top-level items in the pavex crate.

⛰️ Features

  • It is no longer necessary to specify an error handler for every single error type. Check out the guide on error fallbacks for more details.
  • There is a new backend for HTTP sessions built on top of SQLite (by @oliverbarnes) - #497

Contributors

  • @LukeMathWalker
  • @oliverbarnes
  • @leonqadirie

0.1.80 - 2025-03-22

🐛 Bug Fixes

  • Always check if pavexc dependencies are installed (by @LukeMathWalker) - #475
  • Fix the path to the configuration folder in the Dockerfile of the starter project (by @LukeMathWalker) - #475

Contributors

  • @LukeMathWalker

0.1.79 - 2025-03-14

‼️ Breaking changes

  • pavex::time now re-exports jiff@0.2 instead of time@0.3 (by @LukeMathWalker) - #470

⛰️ Features

  • Configuration is now a first-class concept for Pavex (by @LukeMathWalker) - #469

    Check out the new configuration guide to see how the new configuration system can be used to simplify your project and cut down the boilerplate that was previously required to work with configuration values.

Contributors

  • @LukeMathWalker

0.1.78 - 2025-03-01

‼️ Breaking changes

  • Finalize the API for pavex_session, the HTTP session implementation for Pavex.

    The previous API gave equal standing to client-side and server-side state manipulation, while the latter is to be preferred and likely to be more widely used. This change moves all server-related method to appear directly on the Session type, while client-side method remain on dedicated accessors. Capabilities are unchanged, but the user-experience should be more pleasant.

📚 Documentation

Contributors

  • @LukeMathWalker

0.1.77 - 2025-02-26

🧪 Testing

  • Use cargo-mutants to further increase test effectiveness for pavex_session (by @LukeMathWalker)

Contributors

  • @LukeMathWalker

0.1.76 - 2025-02-24

⛰️ Features

  • Bump nightly version used by pavexc to generate JSON docs from 'nightly-2025-01-04' to 'nightly-2025-02-22' (by @LukeMathWalker) - #454
  • Use Rust 2024 edition in the generated server SDK as well as in the starter project generated by 'pavex new' (by @LukeMathWalker) - #454

Contributors

  • @LukeMathWalker

0.1.75 - 2025-02-23

🐛 Bug Fixes

  • Compare path length before iterating in lock step over their segments. (by @LukeMathWalker) - #450

🧪 Testing

  • Push pavex_session test coverage over 90% (by @LukeMathWalker) - #449

Contributors

  • @LukeMathWalker

0.1.74 - 2025-02-12

🐛 Bug Fixes

  • Don't show the 'PAVEX_DEBUG' note if the exit code is successful (by @LukeMathWalker)
  • Quickstart template doesn't require an AppConfig instance as input to the application state (by @LukeMathWalker)
  • Ensure that the starter project compiles straight away (by @LukeMathWalker)

Contributors

  • @LukeMathWalker

0.1.73 - 2025-02-11

⛰️ Features

  • Don't require native libraries to decompress archives from GitHub. (by @LukeMathWalker) - #442

Contributors

  • @LukeMathWalker

0.1.72 - 2025-02-09

⛰️ Features

  • Nudge users towards PAVEX_DEBUG if they need to investigate errors further (by @LukeMathWalker) - #438
  • Add a '-w' option to 'pavex self setup' to streamline the onboard process. (by @LukeMathWalker) - #436
  • When printing an error chain, deduplicate identical errors to reduce visual noise (by @LukeMathWalker) - #438

🐛 Bug Fixes

  • Add a '--skip-activation' flag to 'pavex self setup' to fix the CI/CD pipeline of the starter project (by @LukeMathWalker) - #437

Contributors

  • @LukeMathWalker

0.1.71 - 2025-02-01

⛰️ Features

  • Inform the user when generating JSON docs for crates in the workspace (by @LukeMathWalker) - #430
  • Strive to use the path with the smallest number of segments in the generated code (by @LukeMathWalker) - #430
  • All ApplicationState fields should be public to allow manipulation of the state ahead of request serving. This is particularly important for end-to-end tests. (by @LukeMathWalker) - #430
  • Assign unique and intelligible field names to the singletons stored inside ApplicationState (by @LukeMathWalker) - #430

🐛 Bug Fixes

  • Don't confuse the JSON docs for different versions of the same crate. Be defensive against cargo's broken caching strategy. (by @LukeMathWalker) - #430

Contributors

  • @LukeMathWalker

0.1.70 - 2025-01-24

🐛 Bug Fixes

  • Don't install the current nightly when checking the freshness of a project. Pavex will install the specific nightly version it requires when it initializes (by @LukeMathWalker)
  • Use the new install URL in the starter project template (#425) (by @LukeMathWalker) - #425

🫧 Polishing

  • Use 'tracing_log_error::log_error!' in the project template to ensure consistent error logging (by @LukeMathWalker) - #427

Contributors

  • @LukeMathWalker
  • @pavex-releaser[bot]
  • @github-actions[bot]

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

0.1.69 - 2025-01-21

Added

  • When Pavex's Server fails to spawn a worker thread, capture that thread's name in the error message
  • Add Server::try_serve to give users a chance to handle the case where no connection sources have been registered
  • Cache accesses for path dependencies are now significantly faster, since 'cargo' is no longer in the hot path of determining the crate checksum
  • Reduce the time spent generating JSON docs by leveraging 'cargo rustdoc' built-in caching mechanism for the single-crate usecase.
  • Update Pavex's nightly to 2025-01-04. It unlocks the 2024 edition for Pavex users
  • Enable backtraces for panics in the project template, being careful not to capture backtraces for normal errors in libraries such as anyhow. Update the command to force the toolchain install to work with the latest rustup version

Fixed

  • Use hyper_util's GracefulShutdown utility to ensure connections are indeed shut down gracefully
  • Don't panic if we fail to serve a connection. Log the error as a warning.
  • Lower the logging level to info when reporting a failure to establish a connection. This event kind is common enough not to deserve a higher logging level.
  • Use the blueprint location as the project fingerprint rather than the workspace path, since a workspace may contain multiple blueprints, as it happens for Pavex's UI tests

Other

  • Migrate all tracing events that touch errors to log_error! to ensure consistent field naming
  • Clarify why it's fine to panic if tokio can't create a current-thread runtime inside a Pavex server worker thread
  • Improve suggested resolution for a missing nightly toolchain
  • Re-export error-related fields in pavex_tracing from tracing_log_error
  • Update dependency versions

0.1.68 - 2025-01-05

Fixed

  • Fallbacks can now successfully inject all framework primitives.

Other

  • Fix intra-doc link
  • Fix clippy lints

0.1.67 - 2025-01-02

Added

  • Improve panic message when generic binding fails

Fixed

  • Don't panic when using a non-specific error handler for a generic constructor

0.1.66 - 2024-12-31

Other

  • update Cargo.toml dependencies

0.1.65 - 2024-12-31

Other

  • Pavex will rely on Rust's coercion rule when a & is required but only a &mut is bound (#404)

0.1.64 - 2024-12-30

Fixed

  • Pavex no longer returns a borrow checker error when a &mut reference must be coerced to a shared reference (#401)

0.1.63 - 2024-12-21

Fixed

  • Execute post-processing middlewares when a pre-processing middleware returns early or fails (#398)

0.1.62 - 2024-12-11

Fixed

  • [pavex_session] Fix a runtime panic: the server-side state should be loaded if it hasn't been loaded yet.

0.1.61 - 2024-12-11

Features

  • Track which field failed to be deserialized when working with query parameters

Other

  • [Breaking] Rework pavex_session::Session to avoid requiring a &mut reference when performing read operations (#389)

0.1.59 - 2024-12-01

Fixed

  • Disable default features for server SDK's dependencies (#386)

0.1.58 - 2024-11-29

Fixed

  • Ensure the code-generation phase respects the ordering determined by the borrow-checker analysis phase

0.1.57 - 2024-11-27

Fixed

  • Pavex won't panic if it can't find a transitive dependency in the package graph. It'll log details about the failed searches.

0.1.54 - 2024-11-26

Added

  • Pavex now supports domain guards! You can restrict routes to specific domains and/or serve different websites from the same Pavex application. Check out the relevant guide for more information.
  • There is now a dedicated guide explaining how common path prefixes work.

Breaking ⚠️

  • Blueprint::nest_at has been removed. Use Blueprint::prefix("/my_prefix").nest(nested_bp) as a replacement.
  • The syntax for path parameters has changed. Instead of :param_name, use {param_name}.

0.1.53 - 2024-11-12

Added

  • 'pavex' and 'pavexc' check a dedicated environment variable, in addition to invocation flags, to determine if diagnostic information should be outputted

Fixed

  • Avoid processing the same nodes multiple times in order to avoid duplicated transient nodes.

Other

  • Update thiserror to 2.x.y in generated code

0.1.52 - 2024-11-05

Fixed

  • Don't allow the basic block visitor to simultaneously engage with multiple branching nodes. It fixes a panic for more complex call graphs.

Other

  • Add a span around the generation of the application state initializer function
  • Print the call graph for the application state initializer if the log level is set to 'trace'

0.1.51 - 2024-11-05

Added

  • The diagnostic representation of all call graphs now includes call order information—e.g. does this constructor get invoked before or after this other one?

Fixed

  • Respect the order identified by the borrow-checking analysis phase when generating code

0.1.50 - 2024-11-01

Added

  • Support lifetime parameters in type aliases

Fixed

  • Supply an (empty) instance of UrlParams to the root fallback handler, if it needs it.
  • Look for the 'impl' block in the crate that define the type, rather than the trait, when resolving trait methods
  • Improve error message when we fail to find a method item in the JSON docs
  • Don't complain about missing constructors when looking at a naked generic input parameter
  • Bind generic parameters correctly in all instances
  • Panic eagerly if internal invariants are not upheld when binding generic parameters
  • Pavex correctly handles type aliases with generic parameters that differ from the target type
  • Pavex will correctly set the name of the defining crate when resolving local type aliases that refer to remote types
  • Pavex will never use private modules in the paths used to refer to methods in the generated server SDK code. (#355)

Other

  • Improve panic message with details about the rustdoc item we couldn't handle
  • Display the available constructibles when PAVEX_DEBUG is set and we incur into a 'missing constructor' error
  • Display the cyclic dependency graph when PAVEX_DEBUG is set
  • Provide an easy-to-examine representation for the set of constructibles in a given scope tree

0.1.49 - 2024-10-23

Added

  • First release of Pavex's HTTP sessions toolkit 🎉 (#338)
  • Distinguish between methods and functions in error messages (#344)
  • Start caching the JSON documentation of path dependencies. We rely on the hash of their contents to avoid serving stale data
  • Pavex will no longer emit duplicated diagnostics, thus reducing visual noise when code generation fails

Fixed

  • Pavex always uses a public path to refer to public items, even if they are defined in a private module
  • Detect infinite paths and break early to avoid stalls when generating server SDK crates
  • Ensure error observers are correctly added when dealing with errors in the call graph of a middleware of any kind
  • Perform cross-call-graph analysis to determine if additional .clone() statements are needed before invoking a middleware.
  • Don't discard spans if they match the provided log filter in pavexc

Other

  • Update dependencies to latest possible version. In particular, update 'rustdoc-types' and the nightly version used by 'pavexc'

0.1.48 - 2024-09-02

Fixed

  • Avoid panic petgraph-related panic when inserting clone nodes to fix borrow checking errors (#334)

0.1.47 - 2024-08-14

Fixed

  • always use the specified toolchain, remove yet another location where nightly was hard-coded

Other

  • Pin a specific nightly version for each version of pavexc, ensuring they are compatible (#331)
  • Allow overriding the nightly toolchain used to generate JSON docs via PAVEXC_DOCS_TOOLCHAIN (#331)
  • Fix panics when performing dependency injection for complex call graphs (#329)

0.1.46 - 2024-07-27

Other

  • Feature gate tokio net feature for pavex behind server feature (#324)
  • update Cargo.toml dependencies

0.1.45 - 2024-07-02

Added

  • enable 'std' feature on the 'time' crate in 'pavex'

Fixed

  • std's collections can be used as prebuilt types (#321)

Other

  • Add constructor for RequestHead (#319)

0.1.44 - 2024-06-22

Fixed

  • Don't use public items via paths that include private modules (#316)

0.1.43 - 2024-06-19

Added

  • Add status_mut() function to Response (#313)

0.1.42 - 2024-06-18

Fixed

  • elided lifetime parameters in generic structs are handled correctly (#310)

0.1.41 - 2024-06-16

Fixed

  • Pavex will reject singleton constructors if they return a type with non-'static lifetime parameters. Singletons must be shared across worker threads, therefore they must be 'static.

0.1.40 - 2024-06-16

Fixed

  • 'pavex new' no longer panics if 'cargo fmt' fails. (#303)

0.1.39 - 2024-06-15

Added

  • Add a workspace-hack crate to the generated starter project to minimise (re)build times
  • Introduce prebuilt types (#298)
  • Add a new '--template' option to 'pavex new' and 'pavexc new'. It includes a dedicated 'quickstart' template as well as the 'api' template, the default.
  • In the starter project, use a meaningful example to showcase how the configuration system works, rather than a dummy with no usage
  • Shorthand methods (.clone_if_necessary() and .never_clone()) to tweak the default cloning strategy on constructors and prebuilt types

Fixed

  • Set new Cargo lint to allow 'cfg(pavex_ide_hint)' in Pavex, its snapshot tests and its scaffolded projects
  • Use the [env] section of .cargo/config.toml to store non-sensitive env variables used for local development. It fixes configuration for newly generated projects.
  • Don't use colored logs if color is not enabled.
  • Include super and self as valid prefixes for relative paths in error messages (#296)
  • You can no longer register a type with a non-'static lifetime parameter (implicit or explicit) as a singleton. (#298)

0.1.38 - 2024-04-28

Added

  • Rework CLI introspections (#292)

Fixed

  • anyhow::Result can be returned from constructors and other fallible components (#293)

0.1.37 - 2024-04-27

Fixed

  • Interpolate error message when failing to download a prebuilt pavexc binary
  • Remove dependency on OpenSSL on Linux

0.1.36 - 2024-04-27

Fixed

  • Use the correct name for package names that contain hyphens in the (generated) server SDK Cargo.toml (#287) For example, sqlx-query used to be renamed to sqlx_query in the generated Cargo.toml, causing a cargo error.

Other

  • Update dependencies (#285)
  • Activation keys are now validated server-side (#283)

0.1.35 - 2024-04-26

Fixed

  • Allow &mut references to be held by Next's state. (#280)

0.1.34 - 2024-04-25

Fixes

  • Use Unix path separator in Cargo.toml manifests when specifying path dependencies (#275) It allows the same Pavex project to be built on all platforms with no changes.
  • Re-add default .env file (#276) It allows cargo px r to "just work" on a newly scaffolded Pavex project.

Other

  • Re-order Cargo.toml file (#277)

0.1.33 - 2024-04-21

Added

  • Server request id is now represented as a TypeId (#272)

0.1.31 - 2024-04-21

Other

  • Centralize version.