diff --git a/app/main-window.cpp b/app/main-window.cpp index 45f0752..9ce5def 100644 --- a/app/main-window.cpp +++ b/app/main-window.cpp @@ -1642,12 +1642,25 @@ void MainWindow::onCoreUpdateCheckFinished(bool hasUpdate, const QString& latest } // Called when the background git pull + build finishes. A success hands over to -// the freshly installed binary right away; a failure is reported in a dialog. +// the freshly installed binary right away; a failure is reported in a dialog and +// kept whole in the journal. void MainWindow::onCoreSelfUpdateFinished(bool success, const QString& message) { if (!success) { + // A failing build prints far more than a dialog can hold, and the part + // that gets cut is precisely the error line. The journal keeps the whole + // output as a command block, so the Logs screen shows it and the file can + // be sent as it is — without it, a failed update leaves no trace at all + // (the outcome is not a provider command, so nothing else records it). + LogManager& journal = LogManager::instance(); + journal.beginCommand(QStringLiteral("maj-app"), + QStringLiteral("mise à jour de l'application")); + journal.endCommand(false, message); + qCWarning(pacmgrUpdate) << "self-update failed, output in" << journal.filePath(); + QMessageBox::warning(this, tr("Échec de la mise à jour"), - QString(tr("

La mise à jour a échoué :

%1
")) - .arg(message.toHtmlEscaped())); + QString(tr("

La mise à jour a échoué :

%1
" + "

Le journal complet est dans %2.

")) + .arg(message.toHtmlEscaped(), journal.filePath().toHtmlEscaped())); return; } diff --git a/doc/mise-a-jour.md b/doc/mise-a-jour.md index 496a1f3..7d3d744 100644 --- a/doc/mise-a-jour.md +++ b/doc/mise-a-jour.md @@ -122,6 +122,7 @@ installation hors Arch sans outillage ni archive ouvre la page des releases. | L'application redémarre sur l'ancienne version | Le `version` voisin du binaire n'a pas pu être réécrit : sans lui, `newestVersion()` retombe sur la version compilée, souvent plus ancienne. Vérifier les droits du fichier. | | Recompilation interminable | Méthode *Clone*/*Tarball* : c'est le comportement attendu sans archive précompilée attachée à la release. | | « sudo: a password is required » dans le journal | La mise à jour a tourné sans mot de passe et le dossier cible (ou l'installation des déps) le demandait : relancer et saisir le mot de passe dans le dialogue. | +| Le dialogue d'échec est coupé et la fin du build manque | La boîte ne montre que ce qui tient sur l'écran. La sortie **complète** du script est écrite dans le journal sous le bloc `maj-app` (`⟶ échec` puis les lignes brutes) : la lire depuis l'écran **Logs**, ou ouvrir le fichier donné dans le dialogue. | Voir aussi [installation.md](installation.md) pour les chemins concernés et [operations.md](operations.md) pour le rôle de `sudo` dans le reste de diff --git a/translations/de.json b/translations/de.json index e61e891..270f829 100644 --- a/translations/de.json +++ b/translations/de.json @@ -40,7 +40,7 @@ "

PacManager v%1

Gestionnaire de paquets pour Arch Linux (pacman).

": "

PacManager v%1

Paketverwaltung für Arch Linux (pacman).

", "

PacManager a été mis à jour

La nouvelle version sera active au prochain démarrage.

%1
": "

PacManager wurde aktualisiert

Die neue Version ist beim nächsten Start aktiv.

%1
", "

PacManager v%1 est disponible

Vous utilisez actuellement la version %2.

": "

PacManager v%1 ist verfügbar

Du verwendest derzeit Version %2.

", - "

La mise à jour a échoué :

%1
": "

Die Aktualisierung ist fehlgeschlagen:

%1
", + "

La mise à jour a échoué :

%1

Le journal complet est dans %2.

": "

Die Aktualisierung ist fehlgeschlagen:

%1

Das vollständige Protokoll liegt in %2.

", "ACTIONS RAPIDES": "SCHNELLAKTIONEN", "ACTIVITÉ RÉCENTE": "LETZTE AKTIVITÄT", "AJOUTER UN PLUGIN": "PLUGIN HINZUFÜGEN", diff --git a/translations/en.json b/translations/en.json index 40cef64..c453289 100644 --- a/translations/en.json +++ b/translations/en.json @@ -40,7 +40,7 @@ "

PacManager v%1

Gestionnaire de paquets pour Arch Linux (pacman).

": "

PacManager v%1

Package manager for Arch Linux (pacman).

", "

PacManager a été mis à jour

La nouvelle version sera active au prochain démarrage.

%1
": "

PacManager has been updated

The new version will be active on the next start.

%1
", "

PacManager v%1 est disponible

Vous utilisez actuellement la version %2.

": "

PacManager v%1 is available

You are currently running version %2.

", - "

La mise à jour a échoué :

%1
": "

The update failed:

%1
", + "

La mise à jour a échoué :

%1

Le journal complet est dans %2.

": "

The update failed:

%1

The full log is in %2.

", "ACTIONS RAPIDES": "QUICK ACTIONS", "ACTIVITÉ RÉCENTE": "RECENT ACTIVITY", "AJOUTER UN PLUGIN": "ADD A PLUGIN", diff --git a/translations/es.json b/translations/es.json index 28ea3ea..4b1158d 100644 --- a/translations/es.json +++ b/translations/es.json @@ -40,7 +40,7 @@ "

PacManager v%1

Gestionnaire de paquets pour Arch Linux (pacman).

": "

PacManager v%1

Gestor de paquetes para Arch Linux (pacman).

", "

PacManager a été mis à jour

La nouvelle version sera active au prochain démarrage.

%1
": "

PacManager se ha actualizado

La nueva versión estará activa en el próximo inicio.

%1
", "

PacManager v%1 est disponible

Vous utilisez actuellement la version %2.

": "

PacManager v%1 está disponible

Actualmente usas la versión %2.

", - "

La mise à jour a échoué :

%1
": "

La actualización ha fallado:

%1
", + "

La mise à jour a échoué :

%1

Le journal complet est dans %2.

": "

La actualización ha fallado:

%1

El registro completo está en %2.

", "ACTIONS RAPIDES": "ACCIONES RÁPIDAS", "ACTIVITÉ RÉCENTE": "ACTIVIDAD RECIENTE", "AJOUTER UN PLUGIN": "AÑADIR UN PLUGIN", diff --git a/translations/it.json b/translations/it.json index 1de27f8..e9a449b 100644 --- a/translations/it.json +++ b/translations/it.json @@ -40,7 +40,7 @@ "

PacManager v%1

Gestionnaire de paquets pour Arch Linux (pacman).

": "

PacManager v%1

Gestore di pacchetti per Arch Linux (pacman).

", "

PacManager a été mis à jour

La nouvelle version sera active au prochain démarrage.

%1
": "

PacManager è stato aggiornato

La nuova versione sarà attiva al prossimo avvio.

%1
", "

PacManager v%1 est disponible

Vous utilisez actuellement la version %2.

": "

PacManager v%1 è disponibile

Al momento usi la versione %2.

", - "

La mise à jour a échoué :

%1
": "

L'aggiornamento non è riuscito:

%1
", + "

La mise à jour a échoué :

%1

Le journal complet est dans %2.

": "

L'aggiornamento non è riuscito:

%1

Il registro completo è in %2.

", "ACTIONS RAPIDES": "AZIONI RAPIDE", "ACTIVITÉ RÉCENTE": "ATTIVITÀ RECENTE", "AJOUTER UN PLUGIN": "AGGIUNGI UN PLUGIN",