Skip to content

Resume/abort - #4036

Closed
h8d13 wants to merge 7 commits into
archlinux:masterfrom
h8d13:dot-resume
Closed

Resume/abort#4036
h8d13 wants to merge 7 commits into
archlinux:masterfrom
h8d13:dot-resume

Conversation

@h8d13

@h8d13 h8d13 commented Dec 26, 2025

Copy link
Copy Markdown
Contributor

#4035 draft (comes from my dev fork)

This would be especially good for testing ;)

@Torxed

Torxed commented Dec 26, 2025

Copy link
Copy Markdown
Member

Well holy crap that was fast 😅

@h8d13

h8d13 commented Dec 26, 2025

Copy link
Copy Markdown
Contributor Author

Comes from a fork so this is passage 2. Also my logic was bad your pre-commit checks help a lot

  ⎿  c848f947 (h8d13 2025-11-14 09:44:17 +0100 292) def load_saved_config() -> dict | None:                     
     c848f947 (h8d13 2025-11-14 09:44:17 +0100 293)     """Load saved config and credentials from hade_box folder"""

@h8d13
h8d13 marked this pull request as ready for review December 26, 2025 17:28
@h8d13
h8d13 requested a review from Torxed as a code owner December 26, 2025 17:28
@h8d13

h8d13 commented Dec 26, 2025

Copy link
Copy Markdown
Contributor Author

I'll mark this as ready as the logic looks sound and feels correct on testing branch

@Torxed

Torxed commented Dec 26, 2025

Copy link
Copy Markdown
Member

Thoughts on this one @svartkanin? :)

(Aside from having to move it to the new TUI in #3997)

Comment thread archinstall/lib/configuration.py Outdated

def has_saved_config() -> bool:
"""Check if there's a saved config in /var/log/archinstall"""
config_file = logger.directory / 'user_configuration.json'

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the file names are defined here

self._user_config_file = Path('user_configuration.json')
, to make sure any future changes are easy we should define them once and reuse a variable instead of c/p

Comment thread archinstall/scripts/guided.py Outdated
Comment thread archinstall/lib/configuration.py Outdated
@svartkanin

Copy link
Copy Markdown
Collaborator

In addition to the comments, I can see some benefits for it but also it's not fully self-contained for regular users as the user_credentials.json is not saved and so a full "automatic" re-installation cannot be done.
That does not mean that I'm suggesting to store the credentials file as that would be quite bad from a security perspective.

If the intention with this is to "be easier during dev" I'd suggest to put this behind the --debug flag which we have already

@Torxed

Torxed commented Dec 27, 2025

Copy link
Copy Markdown
Member

In addition to the comments, I can see some benefits for it but also it's not fully self-contained for regular users as the user_credentials.json is not saved and so a full "automatic" re-installation cannot be done. That does not mean that I'm suggesting to store the credentials file as that would be quite bad from a security perspective.

If the intention with this is to "be easier during dev" I'd suggest to put this behind the --debug flag which we have already

I agree, skipping credentials is good and if that's the only step when re-running it still save time.

And putting it behind --debug makes sense for now if nothing else :)

Integrate resume behind --debug flag
  - With --debug: "Save selections and abort", "Abort without saving", "Cancel"
  - Without --debug: "Abort", "Cancel"

@h8d13 h8d13 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Address feedback rounds from torxed/svart

Do lmk I'd more changes are needed

Comment thread archinstall/scripts/guided.py Outdated
@h8d13
h8d13 requested a review from svartkanin December 28, 2025 13:37
@h8d13

h8d13 commented Dec 29, 2025

Copy link
Copy Markdown
Contributor Author

It's now hidden behind --debug and changes based on feedback. (In a seperate lib file)

Also tested a little, and is really helpful to be able to test stuff faster.

Remove mentions of hardcoded paths.
@h8d13 h8d13 closed this Jan 10, 2026
@h8d13
h8d13 deleted the dot-resume branch January 30, 2026 10:21
@h8d13

h8d13 commented Apr 19, 2026

Copy link
Copy Markdown
Contributor Author

This conversation would still be nice to re-open for dev :)

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.

3 participants