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

chore: Fix pylint 2.16.2 complains #145

Merged
merged 2 commits into from Mar 14, 2023
Merged

Commits on Mar 13, 2023

  1. chore: Remove unreachable code

    pylint 2.16.2 complains:
    
    ```
    ************* Module apport.ui
    apport/ui.py:1567:20: W0101: Unreachable code (unreachable)
    ************* Module gtk.apport-gtk
    gtk/apport-gtk:678:8: W0101: Unreachable code (unreachable)
    ```
    
    Remove the unreachable code.
    
    Signed-off-by: Benjamin Drung <benjamin.drung@canonical.com>
    bdrung committed Mar 13, 2023
    Copy the full SHA
    8c3fddd View commit details
    Browse the repository at this point in the history
  2. chore: Raise more specific exceptions

    pylint 2.16.2 complains:
    
    ```
    ************* Module apport.packaging_impl.rpm
    apport/packaging_impl/rpm.py:184:12: W0719: Raising too general exception: Exception (broad-exception-raised)
    ************* Module apport.crashdb_impl.launchpad
    apport/crashdb_impl/launchpad.py:397:16: W0719: Raising too general exception: Exception (broad-exception-raised)
    ```
    
    Replace both instances with `NotImplementedError` which is more precise.
    
    Signed-off-by: Benjamin Drung <benjamin.drung@canonical.com>
    bdrung committed Mar 13, 2023
    Copy the full SHA
    807a857 View commit details
    Browse the repository at this point in the history