{"action":"created","issue":{"url":"https://api.github.com/repos/rstudio/shiny/issues/1117","repository_url":"https://api.github.com/repos/rstudio/shiny","labels_url":"https://api.github.com/repos/rstudio/shiny/issues/1117/labels{/name}","comments_url":"https://api.github.com/repos/rstudio/shiny/issues/1117/comments","events_url":"https://api.github.com/repos/rstudio/shiny/issues/1117/events","html_url":"https://github.com/rstudio/shiny/pull/1117","id":134805435,"number":1117,"title":"Add ability to abort the processing of outputs","user":{"login":"jcheng5","id":129551,"avatar_url":"https://avatars.githubusercontent.com/u/129551?v=3","gravatar_id":"","url":"https://api.github.com/users/jcheng5","html_url":"https://github.com/jcheng5","followers_url":"https://api.github.com/users/jcheng5/followers","following_url":"https://api.github.com/users/jcheng5/following{/other_user}","gists_url":"https://api.github.com/users/jcheng5/gists{/gist_id}","starred_url":"https://api.github.com/users/jcheng5/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jcheng5/subscriptions","organizations_url":"https://api.github.com/users/jcheng5/orgs","repos_url":"https://api.github.com/users/jcheng5/repos","events_url":"https://api.github.com/users/jcheng5/events{/privacy}","received_events_url":"https://api.github.com/users/jcheng5/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":17,"created_at":"2016-02-19T08:35:56Z","updated_at":"2016-02-22T21:06:56Z","closed_at":"2016-02-22T17:20:17Z","pull_request":{"url":"https://api.github.com/repos/rstudio/shiny/pulls/1117","html_url":"https://github.com/rstudio/shiny/pull/1117","diff_url":"https://github.com/rstudio/shiny/pull/1117.diff","patch_url":"https://github.com/rstudio/shiny/pull/1117.patch"},"body":"`abortOutput()` leaves the state of the output unchanged, unlike `req()` (clears it), `validate()` (grey message), or `stop()` (red error message).\r\n\r\nAnd help me find a better name than `abortOutput()` please!\r\n\r\nThis is a dumb example, it just halts the output if the value is less than 10. I made an error throw if n > 80 to demonstrate that abortOutput will also preserve errors, not just valid values.\r\n\r\n```r\r\nlibrary(shiny)\r\n\r\nui <- fluidPage(\r\n  sliderInput(\"n\", \"bins\", 1, 100, 5),\r\n  plotOutput(\"plot\")\r\n)\r\n\r\nserver <- function(input, output, session) {\r\n  output$plot <- renderPlot({\r\n    if (input$n < 10) {\r\n      abortOutput()\r\n    } else if (input$n > 80) {\r\n      stop(\"boom\")\r\n    }\r\n    \r\n    hist(runif(100), input$n)\r\n  })\r\n}\r\n\r\nshinyApp(ui, server)\r\n```"},"comment":{"url":"https://api.github.com/repos/rstudio/shiny/issues/comments/187383554","html_url":"https://github.com/rstudio/shiny/pull/1117#issuecomment-187383554","issue_url":"https://api.github.com/repos/rstudio/shiny/issues/1117","id":187383554,"user":{"login":"vnijs","id":2998956,"avatar_url":"https://avatars.githubusercontent.com/u/2998956?v=3","gravatar_id":"","url":"https://api.github.com/users/vnijs","html_url":"https://github.com/vnijs","followers_url":"https://api.github.com/users/vnijs/followers","following_url":"https://api.github.com/users/vnijs/following{/other_user}","gists_url":"https://api.github.com/users/vnijs/gists{/gist_id}","starred_url":"https://api.github.com/users/vnijs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vnijs/subscriptions","organizations_url":"https://api.github.com/users/vnijs/orgs","repos_url":"https://api.github.com/users/vnijs/repos","events_url":"https://api.github.com/users/vnijs/events{/privacy}","received_events_url":"https://api.github.com/users/vnijs/received_events","type":"User","site_admin":false},"created_at":"2016-02-22T21:06:56Z","updated_at":"2016-02-22T21:06:56Z","body":"That sounds great @jcheng5!"}}