Skip to content

Diagnostics and Tracing

Brendan Forster edited this page Oct 26, 2013 · 6 revisions

There's a couple of options available for diagnosing what's going on under the hood of Squirrel.

Squirrel Logs

When Squirrel runs an installer or update, it logs details to the %LOCALAPPDATA%\Squirrel\ directory on the user's machine.

The files are in a format {ApplicationName}.{ProcessId}.txt because of some scenarios where the same application could be installed and uninstalled. This might change to bring logs back to being more monolithic, but the timestamps in each file should help trace what happened, when.

[INFO][2013-09-19T08:43:26] UpdateManager: Uninstalling version '1.0.0.0'
[WARN][2013-09-19T08:43:26] InstallerHookOperations: Could not find any AppSetup instances
[INFO][2013-09-19T08:43:26] InstallerHookOperations: We have an exe: C:\Users\brendanforster\AppData\Local\SquirrelDesktopDemo\app-1.0.0.0\Squirrel.DesktopDemo.exe
[INFO][2013-09-19T08:43:26] InstallerHookOperations: Deleting shortcut: C:\Users\brendanforster\Desktop\Squirrel.DesktopDemo.lnk
[INFO][2013-09-19T08:43:26] InstallerHookOperations: Deleting shortcut: C:\Users\brendanforster\AppData\Roaming\Microsoft\Windows\Start Menu\SquirrelDesktopDemo\Squirrel.DesktopDemo.lnk
[ERROR][2013-09-19T08:43:26] Utility: safeDeleteFileAtNextReboot: failed - C:\Users\brendanforster\AppData\Local\SquirrelDesktopDemo\app-1.0.0.0\Autofac.dll - 5

Windows Installer logs

For the advanced users (who also have access to the registry), you can enable tracing of the Windows Installer activity - which includes events outside of the Squirrel bootstrapper.

To enable this, create a registry key under HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Installer

Reg_SZ: Logging

Value: voicewarmupx

This will generate a file under '%TEMP%' matching the application name whenever you install or uninstall an application.

More details about this are here.