Repository navigation
Releases: tiny-blocks/http-error-handler
Releases · tiny-blocks/http-error-handler
Release list
v2.0.4
v2.0.3
- Raise
ergebnis/composer-normalizeto^2.54,guzzlehttp/psr7to^3.2,infection/infectionto^0.35,phpstan/phpstanto^2.3,phpunit/phpunitto^13.4,sentry/sentryto^4.34,tiny-blocks/httpto^7.2. - Drop
--coveragefrom the Infection run. - Order members and parameters as the conformance hooks require, without changing any public signature.
v2.0.2
- Point the PHP tooling image at the floating
gustavofreze/php:8.5-clialias, so every rebuild of the image reaches the tooling with no change here. - Pin the CI runners to
ubuntu-26.04. - Remove the comments from the
Makefile. - Run Dependabot updates monthly and bump
gustavofreze/auto-assignto 2.1.1. - Docs: point the contributing guidelines to the
.githubrepository of the organization.
v2.0.1
- Keep the request and the user out of every event a reporter built with
SentryReporter::initializedWithsends: the SDK reads no body, and the request and the user it gathers are dropped before sending.
v2.0.0
- Add the
ErrorReporterseam and theReportedErrorcontext every reporter reads, so a handled error reaches error tracking without the middleware knowing the provider. - Add the
SentryReporteradapter, which either boots the SDK from the deployment values or captures onto a hub the application already holds. - Add
ReportingFilter, so the consumer decides which handled errors reach the provider and a client error never spends quota. - Add
ReportingPriorityandPrioritizedError, the four level urgency scale stated once in neutral terms and translated by each adapter. - Add
ReportingContextandReportingTags, the exception side and request side supplements a report carries, which is how a value resolved below the middleware crosses the PSR-7 immutability gap. - Add
RouteMiddleware, so a report carries the route the request matched instead of the raw path that names one request rather than one endpoint. - Add
withMessage, which settles the message the response answers with before the body is built, so no layer above parses and re-encodes it. - Validate the headers a mapping rule declares, so a malformed field fails while the table is declared rather than on the request that would return it.
v1.3.0
- Raise
tiny-blocks/httpto^7.0. - Raise
infection/infectionto^0.34,phpunit/phpunitto^13.2, andguzzlehttp/psr7to^3.0. - Allow multiline concatenation in
Generic.Strings.UnnecessaryStringConcat, matching the canonical ruleset. - Remove the versioned Claude configuration, now centralized in
tiny-blocks/tiny-blocks. - Remove the CodeQL workflow.
- Align
.gitattributesand.gitignorewith the canonical ecosystem assets.
v1.2.0
- Answer an unmapped exception that carries a 4xx status with that status, instead of a generic 500.
- Log a response in the 4xx range as a warning, and keep every other status as an error.
- Derive the log level from the status actually returned, so a mapped 422 is no longer logged as an error.
- Cover the routing exceptions of a PSR-15 stack with a vendor driver test suite.
- Bump
tiny-blocks/httpto^6.4andtiny-blocks/http-correlation-idto^2.1.
v1.1.0
- Adopt the tiny-blocks/http-correlation-id 2.0 API: the logger is wrapped per request with
CorrelatedLoggerwhen the correlation ID attribute is present, replacing the removedCorrelatedLogger::resolve().
v1.0.0
- Map exceptions thrown by downstream handlers to structured JSON error responses (machine-readable code, HTTP status 400-599, message, optional headers) as a PSR-15 middleware.
- Declare exception-to-error rules through a fluent, first-match-wins ExceptionMappingTable, matching by exact class, any of a list, or subclass, and resolving to a fixed MappedError or one built from the matched throwable by a closure.
- Log errors through an optional PSR-3 logger with configurable verbosity (ErrorHandlingSettings), enriched with the request correlation id via tiny-blocks/http-correlation-id.
- Handle unmapped exceptions with a configurable generic 500 fallback or a rethrow to an outer error boundary.