Skip to content

Fix multiple installer bugs and significantly improve reliability#149

Open
gentoo888 wants to merge 1 commit intooddlama:mainfrom
gentoo888:reliability-fixes
Open

Fix multiple installer bugs and significantly improve reliability#149
gentoo888 wants to merge 1 commit intooddlama:mainfrom
gentoo888:reliability-fixes

Conversation

@gentoo888
Copy link

Hi 👋

This PR focuses on improving the overall reliability, robustness, and correctness
of the Gentoo installer by fixing multiple bugs and edge cases discovered during
real-world usage.

Bug Fixes

  • Fixed incorrect array length usage (${#array}${#array[@]}) causing btrfs formatting issues (this was important)
  • Fixed multiple quoting issues that could break efibootmgr commands and EFI boot creation
  • Fixed race conditions in partition detection with proper wait/retry logic
  • Fixed POSIX-incompatible grep patterns (\S[^[:space:]])
  • Fixed incorrect variables used in error messages
  • Fixed unreliable time synchronization fallback logic

Reliability Improvements

  • Added retry logic for network downloads (with backoff)
  • Added comprehensive input validation for disk operations and encryption configs
  • Added timeouts for device operations to prevent infinite waits
  • Improved error handling consistency across scripts
  • Added optional debug logging via environment variable

Code Quality

  • Improved variable scoping (local usage)
  • Added ShellCheck directives where appropriate
  • Ensured all scripts pass bash -n
  • Improved comments and section structure
  • Preserved backward compatibility where applicable

All changes were tested through repeated installer runs and focus on safety and
maintainability rather than changing installer behavior.

Feedback is very welcome—happy to split this PR or adjust anything if preferred.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant