Skip to content

capture.output() does not work in non-interactive mode #153

Description

@gaborcsardi

We need to use stdout when there is an active sink, I suppose? I am not entirely sure. Reprex:

❯ R -q -e 'capture.output(cli::cli_text("time: {100} year{?s}"))'
> capture.output(cli::cli_text("time: {100} year{?s}"))
time: 100 years
character(0)

Activity

  1. added
    bugan unexpected problem or unintended behavior
    on May 20, 2020
  2. gaborcsardi commented on Sep 29, 2020

    @gaborcsardi
    MemberAuthor

    Or rather, the other way. Messages go to stderr by default and we only want to deter them to stdout, if this does not cause any detectable difference.

    So that means that if there is a sink for stdout or stderr, then we output to stderr.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugan unexpected problem or unintended behavior

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions