cran_error_handler: Creates and handle a (error) condition

View source: R/handlers-.R

cran_error_handlerR Documentation

Creates and handle a (error) condition

Description

Creates and handle a (error) condition

Usage

cran_error_handler(req, res, e)

http_condition(status_code, message, ..., type = NULL, call = sys.call(-1))

Arguments

req, res

A "request"- and "response"-object, respectively

e

The error/[condition][base::conditions] that was thrown by a handler, preferable a [http_condition].

status_code

Integer HTTP Status Code

message

Optional message to display (text).

...

Other things to include in exception.

type

Type of condition to generate. Must be one of 'error', 'warning' or 'message'.

call

The call stored in the condition object.

Value

'NULL' invisibly; called to modify the response.


microCRAN documentation built on Nov. 4, 2023, 1:07 a.m.