Skip to content

Commit 3a39895

Browse files
committed
fix: show stack trace in verbose mode for GitError
1 parent 28ef9b7 commit 3a39895

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ggshield/core/errors.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
from pygitguardian.models import Detail, TokenScope
1515

1616
from ggshield.core.text_utils import pluralize
17-
from ggshield.utils.git_shell import GitError, InvalidGitRefError
17+
from ggshield.utils.git_shell import InvalidGitRefError
1818

1919

2020
logger = logging.getLogger(__name__)
@@ -193,7 +193,7 @@ def handle_exception(exc: Exception) -> int:
193193
" To workaround that, try setting the PYTHONUTF8 environment variable to 1."
194194
)
195195

196-
if not isinstance(exc, (click.ClickException, GitError)):
196+
if not isinstance(exc, click.ClickException):
197197
click.echo()
198198
if ui.is_verbose():
199199
traceback.print_exc()

0 commit comments

Comments
 (0)