Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Limit reset partitioning #237

Merged
merged 3 commits into from
May 22, 2024
Merged

Conversation

KKoukiou
Copy link
Contributor

No description provided.

@KKoukiou KKoukiou force-pushed the reset-part-limit branch 5 times, most recently from 96a966b to 3b45086 Compare April 5, 2024 13:00
@KKoukiou KKoukiou force-pushed the reset-part-limit branch 6 times, most recently from 7985961 to 51bdf80 Compare April 10, 2024 14:25
@KKoukiou KKoukiou force-pushed the reset-part-limit branch 5 times, most recently from fc34a72 to b5b37ed Compare May 8, 2024 10:35
@KKoukiou KKoukiou marked this pull request as ready for review May 8, 2024 12:14
src/helpers/storage.js Outdated Show resolved Hide resolved
src/helpers/storage.js Outdated Show resolved Hide resolved
If the type matches, (MANUAL vs AUTOMATIC) and the devices also match
then we can reuse the partitioning.

Reset the partitioning always when entering the Installation Destination
page.
Put this in a custom hook to increase component readability.
Identifying locked devices can be done prior to partitioning creation.
After unlocking the devices we had to re-create the partitioning anyway.

For implementing this change, adjust getLockedLUKSDevices helper to
parse selectedDisks instead of the partitioning requests for identifying
locked LUKS devices.
@KKoukiou
Copy link
Contributor Author

Fixed issues and rebased.

Copy link
Contributor

@rvykydal rvykydal left a comment

Choose a reason for hiding this comment

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

Looks good to me, thank you.

const initialRequests = getInitialRequests(requests, mountPointConstraints);
setUnappliedRequests(initialRequests);

setIsFormValid(getRequestsValid(initialRequests, deviceData));
}, [deviceData, setIsFormValid, partitioningDataPath, requests, mountPointConstraints]);
}, [deviceData, setIsFormValid, partitioning.path, requests, isLoadingPartitioning, unappliedRequests, mountPointConstraints]);
Copy link
Contributor

Choose a reason for hiding this comment

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

The partitioning.path dependency is listed here so that the hook is run in case applied partitioning changes, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Correct, so if we have a new partitioning we need to recalculate the displayed requests.

@KKoukiou KKoukiou merged commit b375961 into rhinstaller:main May 22, 2024
4 of 5 checks passed
@KKoukiou KKoukiou deleted the reset-part-limit branch May 22, 2024 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants