Make sure all except statements are no longer empty, should help a lot with debugging.

This commit is contained in:
Storm Dragon
2025-06-20 03:03:43 -04:00
parent 4e193f133f
commit a5ca1d28e8
42 changed files with 223 additions and 194 deletions

View File

@ -117,7 +117,8 @@ def getPhonetic(currChar):
if currChar.isupper():
phonChar = phonChar[0].upper() + phonChar[1:]
return phonChar
except:
except Exception as e:
# Utility function, no env access - return fallback
return currChar
def presentCharForReview(env, char, interrupt=True, announceCapital=True, flush=False):

View File

@ -58,8 +58,10 @@ def isValidShell(shell = ''):
return False
if not os.access(shell,os.X_OK):
return False
except:
return False
except Exception as e:
# Utility function, no env access - use fallback logging
print(f'screen_utils isValidShell: Error checking shell {shell}: {e}')
return False
return True
def getShell():
@ -67,13 +69,15 @@ def getShell():
shell = os.environ["FENRIRSHELL"]
if isValidShell(shell):
return shell
except:
except Exception as e:
# Utility function, no env access - continue silently
pass
try:
shell = os.environ["SHELL"]
if isValidShell(shell):
return shell
except:
except Exception as e:
# Utility function, no env access - continue silently
pass
try:
if os.access('/etc/passwd', os.R_OK):
@ -85,7 +89,8 @@ def getShell():
if username == getpass.getuser():
if isValidShell(shell):
return shell
except:
except Exception as e:
# Utility function, no env access - continue silently
pass
if isValidShell('/bin/bash'):
return '/bin/bash'