Skip to content

Output rt atc json to stdout #3190

@Chasarr

Description

@Chasarr

Describe the bug

Currently when running say jf atc blabla_generate_error_please you get this output:

$ export CI=true
$ jf atc blabla_generate_error_please >file.txt 2>err.txt
$ cat file.txt # Nothing
$ cat err.txt
15:48:56 [Info] Trace ID for JFrog Platform logs: a0bbed4710e6ae4d
15:48:56 [Error] server response: 403 Forbidden
{
  "errors": [
    {
      "code": "FORBIDDEN",
      "message": "Forbidden"
    }
  ]
}

However, when creating solution for CI interfaces, you may want to parse this message and handle the errors. I see two potential solutions:

  1. CI=true disables extra error dumping that doesn't conform to JSON
  2. Separate the outputs into two different output streams

JFrog CLI version

2.82.0

Operating system type and version

Arch Linux, rolling release and recently updated

JFrog Artifactory version

Enterprise Plus 7.117.14 rev 81714900

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions