-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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
🚧 [Hosts] Backup Settings #37778
🚧 [Hosts] Backup Settings #37778
Conversation
<value>Specify the number of days to retain backups</value> | ||
</data> | ||
<data name="Hosts_DeleteBackupWarning.Title" xml:space="preserve"> | ||
<value>Backups will never will be kept indefinitely with the current configuration</value> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<value>Backups will never will be kept indefinitely with the current configuration</value> | |
<value>Backups never will be kept indefinitely with the current configuration</value> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for catching this (haven't reviewed the PR yet 😄).
What I wanted here is Backups will be kept indefinitely with the current configuration.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The UI is confusing: If I keep my backups 0 days, then I have no backups. 🤔
I suggest as we have the on/of checkbox for cleanup to set the number boxes to min=1. |
The idea is that user can configure retention by:
In case both are set to 0 the warning is displayed and no backups are deleted. Do you think this makes sense? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some ui nits
IsTabStop="{x:Bind ViewModel.ShowDeleteBackupWarning, Mode=OneWay}" | ||
Severity="Warning" /> | ||
</tkcontrols:SettingsCard> | ||
<tkcontrols:SettingsCard x:Uid="Hosts_Backup_DaysToKeep" IsEnabled="{x:Bind ViewModel.BackupHosts, Mode=OneWay}"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is enabled should be bind against both: backup hosts and automatic deletion
SpinButtonPlacementMode="Compact" | ||
Value="{x:Bind ViewModel.DaysToKeep, Mode=TwoWay}" /> | ||
</tkcontrols:SettingsCard> | ||
<tkcontrols:SettingsCard x:Uid="Hosts_Backup_CopiesToKeep" IsEnabled="{x:Bind ViewModel.BackupHosts, Mode=OneWay}"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is enabled should be bind against both: backup hosts and automatic deletion
Background="{ThemeResource SystemFillColorCautionBackgroundBrush}" | ||
ContentAlignment="Vertical" | ||
Visibility="{x:Bind ViewModel.ShowDeleteBackupWarning, Mode=OneWay}"> | ||
<InfoBar |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For a nicer UI: Can we move it as first element in the expander.
These all feels to complicated. I think keep it simple is the way to go. And simple for me is:
|
I started with this idea, but #37666 (comment) made me change it.
But I am happy to have a feedback on this. |
Okay. But then lets allow the following logic: Remove backups older x days (x = setting >= 1) and hard coded keep always 1 backup. The if-else-else solution is to complicated. We can add a description to cleanup checkbox that at least one backup is always kept regardless of its age. |
I need to think about this: the idea around the PR is to remove any hardcoded/hidden logic related to backups. |
The point that we have multiple ways of doing it which influence each other. And that you can configure it to not clean up even that zhe clean up is enabled. |
@htcfreek any thoughts on this UX?
|
@davidegiacometti With zero as date or time all backups will be deleted on the |
The backups cleanup is always executed on editor startup. These options are used to determine for how many days backups are kept or/and how many fixed backups are kept. |
Yes. What I mean is: It makes a difference with 0 days if I start Hosts multiple times per day or not. And for me keeping 0 days means deleting at the day of creating and not keeping indefinitely. That is confusing. |
I think the drop downs are limiting.. 🤔 |
Hey @htcfreek Can I have a feedback on these mocks? ![]() ![]() ![]() Let me know if you think this solution is clear. If your answer is positive I am going to reopen this PR and tweak the implementation. |
Two suggestions:
Can't follow you. There are only these two number boxes in the screenshots. Are there any screenshots missing? And I still see see the problem that 0 means nothing. So we should explain the meaning of 0 in the number box description. |
Ok for the suggestions. Please see the update screenshot. |
Sory. My mistake. Was confused after all the solutions we discussed. |
Yes. It is clear. Let's implement that solution. |
Summary of the Pull Request
PR Checklist
Detailed Description of the Pull Request / Additional comments
Validation Steps Performed