diff --git a/plinth/modules/upgrades/distupgrade.py b/plinth/modules/upgrades/distupgrade.py index 01b278254..f60658ba6 100644 --- a/plinth/modules/upgrades/distupgrade.py +++ b/plinth/modules/upgrades/distupgrade.py @@ -338,11 +338,7 @@ def _apt_autoremove(): def _apt_full_upgrade(): """Run and check if apt upgrade was successful.""" logger.info('Running apt full-upgrade...') - returncode = _apt_run(['full-upgrade']) - if returncode: - raise RuntimeError( - 'Apt full-upgrade was not successful. Distribution upgrade ' - 'will be retried at a later time.') + _apt_run(['full-upgrade']) def _unattended_upgrades_run(): diff --git a/plinth/modules/upgrades/tests/test_distupgrade.py b/plinth/modules/upgrades/tests/test_distupgrade.py index 4a5314ed9..bfd07b87c 100644 --- a/plinth/modules/upgrades/tests/test_distupgrade.py +++ b/plinth/modules/upgrades/tests/test_distupgrade.py @@ -396,10 +396,6 @@ def test_apt_full_upgrade(apt_run): distupgrade._apt_full_upgrade() apt_run.assert_called_with(['full-upgrade']) - apt_run.return_value = 1 - with pytest.raises(RuntimeError): - distupgrade._apt_full_upgrade() - @patch('subprocess.run') def test_unatteneded_upgrades_run(run):