Skip to content

Commit

Permalink
Force backup set to run when manually run via GUI, even if disabled (f…
Browse files Browse the repository at this point in the history
…ixes #4)
  • Loading branch information
stewartadam committed Jul 6, 2023
1 parent 66c0bce commit 96481a1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions fwbackups/operations/backup.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,8 @@ def checkRemoteServer(self):
self.logger.logmsg('DEBUG', _('Connecting to SFTP host {RemoteHost} succeeded.').format(RemoteHost=self.options['RemoteHost']))
return True
else:
if thread.exception is None:
self.logger.logmsg('ERROR', _('Connecting succeeded, but the SFTP destination path "%s" is not a folder.' % self.options['RemoteFolder']))
if isinstance(thread.exception, paramiko.AuthenticationException):
self.logger.logmsg('ERROR', _('A connection was established, but authentication ' +
'failed. Please verify the username and password ' +
Expand Down
2 changes: 1 addition & 1 deletion fwbackups/ui/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2332,7 +2332,7 @@ def updateProgress(self):
self.main2BackupProgress.startPulse()
self.main2BackupProgress.set_text(_('Please wait...'))
try:
self.backupHandle = backup.SetBackupOperation(os.path.join(constants.SETLOC, "%s.conf" % name))
self.backupHandle = backup.SetBackupOperation(os.path.join(constants.SETLOC, "%s.conf" % name), forceRun=True)
self.backupThread = fwbackups.runFuncAsThread(self.backupHandle.start)
self.ui.main2CancelBackupButton.show()
self.ui.main2CancelBackupButton.set_sensitive(True)
Expand Down

0 comments on commit 96481a1

Please sign in to comment.