Added a more humane error message on no initial network (#3501)

* Added a more humane error message on no initial network

* Fixed ruff complaints
This commit is contained in:
Anton Hvornum 2025-05-25 13:30:47 +02:00 committed by GitHub
parent 6d1a450440
commit 6c7260fa33
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 5 additions and 0 deletions

View File

@ -40,6 +40,11 @@ def _fetch_arch_db() -> None:
try:
Pacman.run('-Sy')
except Exception as e:
error('Failed to sync Arch Linux package database.')
if 'could not resolve host' in str(e).lower():
error('Most likely due to a missing network connection or DNS issue.')
error('Run archinstall --debug and check /var/log/archinstall/install.log for details.')
debug(f'Failed to sync Arch Linux package database: {e}')
exit(1)