Add handling for backup in progress
Shows a better error message when a given backup is already running. fixes QubesOS/qubes-issues#5432 requires https://github.com/QubesOS/qubes-core-admin/pull/292
This commit is contained in:
		
							parent
							
								
									2c132d9b83
								
							
						
					
					
						commit
						b27c10f1d4
					
				| @ -52,6 +52,9 @@ class BackupThread(QtCore.QThread): | ||||
|             self.vm.app.qubesd_call( | ||||
|                 'dom0', 'admin.backup.Execute', | ||||
|                 backup_utils.get_profile_name(True)) | ||||
|         except exc.BackupAlreadyRunningError: | ||||
|             msg.append("This backup is already in progress! Cancel it " | ||||
|                        "or wait until it finishes.") | ||||
|         except Exception as ex:  # pylint: disable=broad-except | ||||
|             msg.append(str(ex)) | ||||
| 
 | ||||
|  | ||||
| @ -16,3 +16,7 @@ class QubesDaemonNoResponseError(BaseException): | ||||
| 
 | ||||
| class BackupCancelledError(BaseException): | ||||
|     pass | ||||
| 
 | ||||
| 
 | ||||
| class BackupAlreadyRunningError(BaseException): | ||||
|     pass | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Marta Marczykowska-Górecka
						Marta Marczykowska-Górecka