diff options
author | Damien Baty <damien@damienbaty.com> | 2023-03-03 10:18:03 +0100 |
---|---|---|
committer | Damien Baty <damien@damienbaty.com> | 2023-03-08 09:42:43 +0100 |
commit | a93442aed71d573b7bac56d2e14ad7f7f9a66ddc (patch) | |
tree | 551f3456e866b920bcee3de454ec622e4f032bed | |
parent | f4dc7969414f5c03b0e0b38062c34d5ab556379e (diff) |
lint: Remove unused variables and imported functions
-rw-r--r-- | pgcli/main.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pgcli/main.py b/pgcli/main.py index 13e1b74a..5a263f56 100644 --- a/pgcli/main.py +++ b/pgcli/main.py @@ -71,9 +71,9 @@ from .__init__ import __version__ click.disable_unicode_literals_warning = True try: - from urlparse import urlparse, unquote, parse_qs + from urlparse import urlparse except ImportError: - from urllib.parse import urlparse, unquote, parse_qs + from urllib.parse import urlparse from getpass import getuser @@ -724,7 +724,7 @@ class PGCli: "Destructive statements must be run within a transaction." ) raise KeyboardInterrupt - destroy = confirm = confirm_destructive_query( + destroy = confirm_destructive_query( text, self.destructive_warning, self.dsn_alias ) if destroy is False: @@ -753,7 +753,7 @@ class PGCli: click.secho(str(e), err=True, fg="red") if handle_closed_connection: self._handle_server_closed_connection(text) - except (PgCliQuitError, EOFError) as e: + except (PgCliQuitError, EOFError): raise except Exception as e: logger.error("sql: %r, error: %r", text, e) |