Ignore exceptions in the environment modifier

This commit is contained in:
Kovid Goyal 2021-11-07 10:13:09 +05:30
parent 4c0a7a9566
commit 2f5d3b073d
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C

View file

@ -129,5 +129,10 @@ def modify_shell_environ(argv0: str, opts: Options, env: Dict[str, str]) -> None
return
f = ENV_MODIFIERS.get(shell)
if f is not None:
f(env)
try:
f(env)
except Exception:
import traceback
traceback.print_exc()
log_error(f'Failed to setup shell integration for: {shell}')
return