8000 Updating printing by john-westcott-iv · Pull Request #481 · ansible/receptor · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Updating printing #481

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

Merged
merged 5 commits into from
Jan 19, 2022

Conversation

john-westcott-iv
Copy link
Member

Changing from print to click.echo.
Adding printWarning method (prints magenta) and printError method (prints red) to distinguish messages.
Implemented our own pprint method to use click.echo w/ json.dumps.
Added a few try/catch blocks to grab some errors found during testing.
Added two spaces to fix column headers in status command.

< 8000 svg aria-label="Loading" style="box-sizing: content-box; color: var(--color-icon-primary);" width="64" height="64" viewBox="0 0 16 16" fill="none" role="img" data-view-component="true" class="my-3 mx-auto d-block anim-rotate">
@john-westcott-iv john-westcott-iv force-pushed the colored-warnings-and-errors branch from 9990d81 to 8552b76 Compare November 17, 2021 18:18
@shanemcd
Copy link
Member

The test failure here is strange. I don't see how what you did caused that, but we aren't seeing it on other runs. I don't have time to investigate today, curious if you can figure out what's going on.

@shanemcd
Copy link
Member

Got curious and tried this locally. I was able to reproduce, so should be easy to track down when you have time. Just make sure you have tox installed and run make receptorctl-test.

@john-westcott-iv john-westcott-iv force-pushed the colored-warnings-and-errors branch from 1b21683 to abbd73d Compare November 18, 2021 20:23
@john-westcott-iv
Copy link
Member Author

@shanemcd I found the issue. There were two print commands in the format print("string", variable). I missed them when converting to print_message so they were not properly displaying their variables which were parsed in the tests.

@shanemcd shanemcd merged commit e70faf6 into ansible:devel Jan 19, 2022
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.

2 participants
0