TriFrost

TriFrost 0.20.1

|peterver

News

Improved

  • qol: Otel http.status_code and otel.status_code attributes are now set early in the routing chain before middleware runs, giving better observability out of the box. Also, ctx.setStatus now only updates logger attributes if the status code actually changes, avoiding unnecessary writes.
  • qol: ctx.html no longer defaults to 200 if a previous ctx.setStatus was called — it respects the existing status unless explicitly overridden.
  • qol: ctx.json no longer defaults to 200 if a previous ctx.setStatus was called — it respects the existing status unless explicitly overridden.
  • qol: ctx.text no longer defaults to 200 if a previous ctx.setStatus was called — it respects the existing status unless explicitly overridden.
  • qol: Triaging (internal check to ensure the context is properly locked on error or status) now also runs after each middleware if the context has a status ≥ 400 but is not aborted — improving graceful handling when middleware signals an error without explicitly calling abort().
  • cicd: Added codecov.yml to enforce that coverage must not drop below 60%.

Fixed

  • bug: Fixed an off-by-one error in the middleware iteration loop that could cause Reflect.get to throw (TypeError: Reflect.get called on non-object) when accessing beyond array bounds. This surfaced in certain routing configurations.

Loved the read? Share it with others