Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display log of JSON documents via the CLI #429

Closed
callumforrester opened this issue Apr 22, 2024 · 1 comment
Closed

Display log of JSON documents via the CLI #429

callumforrester opened this issue Apr 22, 2024 · 1 comment
Assignees
Labels
cli Relates to CLI code client Relates to client code enhancement New feature or request

Comments

@callumforrester
Copy link
Collaborator

As a developer I would like to produce a set of copy/pasteable JSON documents in a log while I am running plans so that I can use them as test data for downstream applications.

Prior Art

Running blueapi controller listen will log all events coming off the message bus, including bluesky documents and other blueapi events. There is a WIP PR to provide filtering down to just documents: #337, which allows the user to write blueapi controller listen -t data.

However, that is not enough as the logs still aren't valid JSON, they are printouts of python dictionaries.

Possible Solution

Take over and complete #337, either include a format argument or raise in a separate PR such that a user can type blueapi controller listen -t data -o json and have the documents printed out in valid JSON form.

Acceptance Criteria

  • blueapi controller listen -t data -o json (exactly syntax may vary) will print out valid JSON of all documents produced by blueapi until the user presses CTRL-C
  • Tests in CLI tests
@callumforrester callumforrester added enhancement New feature or request client Relates to client code cli Relates to CLI code labels Apr 22, 2024
@callumforrester
Copy link
Collaborator Author

Done as part of #539

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli Relates to CLI code client Relates to client code enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants