Skip to content

Add helpful error message to shiny::need() #2509

@chasemc

Description

@chasemc

Sorry not to issue a PR, but I'm currently super busy.

If label is left out of shiny::need(), the error message is not easy to figure out.
It would be nice to include something like "label is missing in need()"

> shiny::need(1+1)
Error in paste(label, "must be provided") : 
  argument "label" is missing, with no default

Relevant line is here:

shiny/R/utils.R

Line 1199 in e6c2133

force(message) # Fail fast on message/label both being missing

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions