Skip to content

Boardwalk CLI: Use python logger; have debug logs#53

Merged
m4wh6k merged 8 commits intomainfrom
boardwalk-cli-use-logger
Jan 6, 2023
Merged

Boardwalk CLI: Use python logger; have debug logs#53
m4wh6k merged 8 commits intomainfrom
boardwalk-cli-use-logger

Conversation

@m4wh6k
Copy link
Copy Markdown
Contributor

@m4wh6k m4wh6k commented Jan 6, 2023

What and why?

This fixes #7 by using a logger for most log messages emitted by boardwalk. It also adds a new global CLI option and env variable to enable debug logging. Usage of ClickException is replaced by a new general "BoardwalkException" so that a logger can be used along with exception messages.

There are a couple known issues coming out of this:

  • The debug output is very verbose and not meant for typical usage. It's easy to miss prompts from the CLI because of ongoing messages from background activity.
  • The default log format is meant to give the user some idea of where in the application a log message is being emitted. At the moment, the BoardwalkException output doesn't really give the user a better idea of where an error occurred unless another log message preceded it.

How was this tested?

Tested locally using the test Boardwalkfile.py. Also some spot checking with a live workspace.

Checklist

  • Have you updated the VERSION file (if applicable)?

@m4wh6k m4wh6k requested a review from asullivan-blze January 6, 2023 21:46
Copy link
Copy Markdown
Contributor

@asullivan-blze asullivan-blze left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@m4wh6k m4wh6k merged commit 6151836 into main Jan 6, 2023
@m4wh6k m4wh6k deleted the boardwalk-cli-use-logger branch January 6, 2023 23:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

boardwalk CLI should emit logs from a logger

2 participants