fix(update): survive an exe that cannot be renamed
Several operators hit "stage current exe: rename …\OpsLog.exe …\OpsLog.exe.old: Accès refusé" and could not update again. Two separate causes, both ours to handle. The staging name was fixed. os.Rename replaces its target, so a single leftover ".old" that could not be deleted — a scanner holding it open is the usual reason, and the pre-existing os.Remove was best-effort and ignored — made every later update fail with that error, permanently, recoverable only by deleting the file by hand. Staging now uses a unique ".old-<nanos>", which no leftover can block, and the startup cleanup sweeps the pattern instead of one name. Renaming a running image is legal on Windows, but some endpoint protection (Bitdefender's ransomware remediation among them) blocks it outright, and no retry gets past that. So the swap is deferred: the new build is parked beside the old one and a detached helper moves it into place after this process exits, when the file is no longer a running image. It keeps trying for ten seconds, since a scanner tends to let go a beat after the process dies. A short retry stays in front of both, for the ordinary case of a scanner holding the file it has just watched being written. If even the deferred move fails, OpsLog restarts on the CURRENT version rather than leaving the operator with nothing — someone mid-QSO losing their logger is worse than an update that waits — and only a successful swap passes --post-update, so the download survives for the next attempt instead of being swept by the cleanup.
This commit is contained in:
@@ -3,9 +3,11 @@
|
||||
"version": "0.24.1",
|
||||
"date": "",
|
||||
"en": [
|
||||
"Update: \"stage current exe: … Accès refusé\" is fixed. Two causes, both handled. The previous build was always staged under the same name, so one leftover that could not be deleted — an antivirus holding it open is the usual reason — blocked every later update, permanently, with no way out but deleting the file by hand; the staging name is now unique. And when the running program cannot be renamed at all, which some endpoint protection deliberately prevents, OpsLog no longer gives up: it leaves the new build beside the old one and swaps them after closing, when its own file is an ordinary file again. If even that fails, OpsLog restarts on the current version rather than leaving you with nothing, and the download is kept for the next attempt.",
|
||||
"Band map: the width can be dragged. Both the map docked beside the tables and the per-band cards in the Band map tab were locked at a fixed width, so an operator watching a busy band could not give the map more room — nor take it back for the log. Grab the edge to resize, double-click it to go back to the default. The width is remembered and travels with your data folder, like the other layout settings. In the tab, one width applies to every card: they sit side by side, and columns of different widths read as a mistake."
|
||||
],
|
||||
"fr": [
|
||||
"Mise à jour : le « stage current exe : … Accès refusé » est corrigé. Deux causes, traitées toutes les deux. L'ancienne version était toujours mise de côté sous le même nom : un seul reliquat impossible à supprimer — un antivirus qui le garde ouvert, le plus souvent — bloquait définitivement toutes les mises à jour suivantes, sans autre issue que d'effacer le fichier à la main ; ce nom est désormais unique. Et quand le programme en cours d'exécution ne peut pas être renommé du tout, ce que certaines protections empêchent volontairement, OpsLog n'abandonne plus : il laisse la nouvelle version à côté de l'ancienne et les échange après sa fermeture, quand son propre fichier redevient un fichier ordinaire. Si même cela échoue, OpsLog redémarre sur la version actuelle plutôt que de te laisser sans rien, et le téléchargement est conservé pour la prochaine tentative.",
|
||||
"Band map : la largeur se règle à la souris. La carte ancrée à côté des tableaux et les cartes par bande de l'onglet Band map étaient figées à une largeur fixe : impossible de donner plus de place à la carte sur une bande chargée, ni de la reprendre pour le journal. Attrape le bord pour redimensionner, double-clic pour revenir au défaut. La largeur est mémorisée et voyage avec ton dossier de données, comme les autres réglages de disposition. Dans l'onglet, une seule largeur vaut pour toutes les cartes : elles sont côte à côte, et des colonnes de largeurs différentes se lisent comme une erreur."
|
||||
]
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user