Remove dead code from __main__.py (#98694)

This commit is contained in:
Erik Montnemery 2023-08-20 10:17:28 +02:00 committed by GitHub
parent 3fc043d99e
commit e484066f2b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -148,16 +148,6 @@ def get_arguments() -> argparse.Namespace:
return arguments
def cmdline() -> list[str]:
"""Collect path and arguments to re-execute the current hass instance."""
if os.path.basename(sys.argv[0]) == "__main__.py":
modulepath = os.path.dirname(sys.argv[0])
os.environ["PYTHONPATH"] = os.path.dirname(modulepath)
return [sys.executable, "-m", "homeassistant"] + list(sys.argv[1:])
return sys.argv
def check_threads() -> None:
"""Check if there are any lingering threads."""
try: