-
Notifications
You must be signed in to change notification settings - Fork 228
feat: Persistent icon style in toolbar #2002
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
Conversation
Co-authored-by: Christian Buhtz <c.buhtz@posteo.jp>
Co-authored-by: Christian Buhtz <c.buhtz@posteo.jp>
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.
Hello Samuel,
thank you very much for this contribution. I appreciate that.
Have you installed one of that linters on your system? ruff
, pylint
or flake8
?
I recommend to install all of them and then run the unit tests. The tests also run that linters and you will find some minor warnings related to code styling.
You can also try to add a changelog entry.
I have a question related to the state file in general and not to this PR. Might it be appropriate to move the state file code into the "qt" part of the code base? As I can see all variables in this file are somehow related to the GUI and not relevant for the command line version of BIT. Moving it to the GUI would solve two other problems: 1) Saving it at application exit without using "atexit" module but exit handler of Qt and 2) risk to lose state data by overwriting the file from different BIT instances running at the same time. What do you think? |
Regarding the linters, I have started using ruff but need to get into the habit of checking every time. I will start to use flake8 and pylint as well as per your suggestion. Do you have a preferred configuration to share or should I just set them up myself. I assume that with ruff, you're ignoring E: 402, 712, 713, 714, 721, 722, 731, 741, 751; F: 401, 403, 405, 811, 821, 841, is that right? (I'm quite new to linters (and contributing in general) so any suggestions/advice would be appreciated) Your suggestion to move the state data into the qt code makes sense to me. The only issue I could think of would be if two gui instances were open at once but that seems quite unlikely and is not handled in the current setup anyway, I guess it's much more likely that a user might exit a gui instance while a cron job is running so it seems like a logical step to move it. Do yout want me to work on that? Otherwise I was thinking of working on #1018 (unless there's something else you suggest)? |
I've added an entry to the changleog, please let me know if any issues with format / wording. |
Please see I recommend to stick to the unit tests with running As you can see in the unit tests. The current approach is to use the linters with all warnings disabled and only some of them enabled. See Issue #1755 for details about how we reduce the amount of linter errors step by step. We also have tests using a linter in its default configuration (all warnings enabled) but only for an exclusive set of files. Let me give you a short overview via looking into
The numbers in the method names are there to set the execution order of them. Ruff is very fast and will cover a big amount of possible errors, so use it as first. Next use flake8 to cover errors not caught by Ruff. At the end use PyLint which is extrem slow but also extrem pedantic and covering much more then code styling but also common bad coding habits and other code smells.
Thanks for your thought. I'll work on that.
Looks OK to me. |
# Summary This is a release candidate. Please report if you use it even if there are no new problems. This version is set to be released with Debian 13 (Trixie) this early summer and will remain available for the long lifetime of that Debian version. EncFS, used for encrypted profiles, has been marked as deprecated and is schedule for removal in 2026. The Smart & Auto remove GUI has been reorganized and renamed into "Remove & Retention", with improvements to the user manual section. Its behavior remains unchange. An offse 8000 t minute can now be configured for hourly schedule options. Some config file fields have been moved to a newly introduced state file. License and copyright information is now provided in machine-readable SPDX format, following the REUSE standard. # Contributors This version received extensive support from contributors (in alphabetical order): - @bremnere - David Gibbs @fallingrock - graysky @graysky2 - Samuel More @mooresamuel - Iván Rodríguez @ivanrdgz03 - Peter Sevens @sevens - David Wales @daviewales - Dylan Wilson @dylan-wilson-usq - Also not to be forgotten are the many people who supported the project by testing it, providing feedback, reporting issues, and analyzing problems. # Known major issues open - qt_probing.py may hang with high CPU usage when running Back In Time as root via cron (#1592) - File permissions handling and therefore possible non-differential backups (#988 & #994) # Changelog * Changed: More clear and intense warning about EncFS deprecation and removal (#1904) * Changed: Updated desktop entry files * Changed: Move several values from config file into new introduce state file ($XDG_STATE_HOME/backintime.json) * Changed: Completed license information to conform the REUSE.software and SPDX standards. * Breaking Change: Auto-remove rules "Free inodes" and "Free space" disabled by default (#1976) * Fix!: Smart-remove rule "Keep one snapshots per week or the last week" use calendar weeks * Fix: The width of the fourth column in files view is now saved * Fix: Snapshot compare copy symlink as symlink (#1902) (Peter Sevens @sevens) * Fix: Crash when comparing a snapshot with a symlink pointing to a nonexistent target (Peter Sevens @sevens) * Fix: Crash (KeyError) opening language setup dialog with unknown locale/language * Feature: Open user manual (local if available otherwise online) via Help menu * Feature: Toolbar context menu to display the buttons in different combinations with icons and text (#1105, #2002) (Samuel Moore @s4moore) * Feature: Add offset minutes to hourly schedules (David Gibbs @fallingrock) * Doc: Remove & Retention (formally known as Auto-/Smart-Remove) with improved GUI and user manual section (#2000)
Added toolbar_button_style property to the state data so the selected main toolbar icon styling persists between sessions.