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

[DRAFT] Make ChecksumMismatch prettier, CLI and __str__ #27

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Commits on Oct 8, 2022

  1. Make ChecksumMismatch prettier, CLI and __str__

    Change:
    - [checksum] Make ChecksumMismatch carry differences as a class parameter
      so that when things like the CLI render it, they can use that information.
    
    - [checksum] Make ChecksumMismatch implement __str__ and give a pretter
      error. AWX currently uses str(exc) to render the errors, so this is a UX
      improvement there as well.
    
    - [cli] Make the UI show these errors nicer as well. Now it will truncate the
      listing of files by default to avoid flooding the user's screen if they
      forgot (for example) to exclude their .git directory. A new flag,
      --no-truncate, is added to disable this truncation. Also, now the files are
      listed out in a readable way, one per line, rather than as a literal Python
      dictionary representation.
    
    Test Plan:
    - Updated tests for the new __str__ output
    
    Signed-off-by: Rick Elrod <[email protected]>
    relrod committed Oct 8, 2022
    Configuration menu
    Copy the full SHA
    d383088 View commit details
    Browse the repository at this point in the history
  2. run black

    Signed-off-by: Rick Elrod <[email protected]>
    relrod committed Oct 8, 2022
    Configuration menu
    Copy the full SHA
    fed2967 View commit details
    Browse the repository at this point in the history