Skip to content

Conversation

@snennis
Copy link

@snennis snennis commented Feb 27, 2025

I added a possibility for the user to choose the path for their backup file.

@github-actions github-actions bot added the UI User interface: forms, widgets... label Feb 27, 2025
@Guts Guts requested a review from kannes October 2, 2025 16:19
Copy link
Collaborator

@jmkerloch jmkerloch left a comment

Choose a reason for hiding this comment

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

For me there is a regression for action not related to QDT profile export.

This should be fixed.

self.target_plugins = collect_plugin_names(self.target_qgis_ini_file)

def make_backup(self, profile_name: str) -> Optional[str]:
def make_backup(self, profile_name: str, backup_dir: str) -> Optional[str]:
Copy link
Collaborator

Choose a reason for hiding this comment

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

@snennis The backup_dir should be optionnal. make_backup is used outside qdt export and there will be an regression.

IMHO we should make it optional and use default value self.backup_dir if not defined.

What do you think @kannes ?

######################################################################
backup_path = Path(backup_dir)

if not backup_path.exists():
Copy link
Collaborator

Choose a reason for hiding this comment

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

If it doesn't exists it should be created. What do you think @kannes ?

backup_path = (
self.qdt_backup_file_widget.filePath()
) # NEW sets backup_path from Widget
if profile_path and backup_path: # NEW check for both
Copy link
Collaborator

Choose a reason for hiding this comment

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

See my remark for the parameter backup_path in make_backup. We should be able to left the path empty. In this case default value from profile manager will be used Path.home() / "QGIS Profile Manager Backup")

@kannes
Copy link
Contributor

kannes commented Oct 16, 2025

Thanks for your review @jmkerloch! I hope someone from us will have time to check back on it soonish.

Feel welcome to change/fix things as you like!

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

Labels

UI User interface: forms, widgets...

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants