PatchMyPC Log Parser
A Visual Studio Code extension that parses and displays PatchMyPC log files with color-coded entries and structured table view.
Features

- Interactive filtering:
- Filter by log type (All/Info/Warning/Error)
- Statistics showing count of each log type
- Search within log messages
- Navigate to context of search result
- Sort ascending or descending by Date & Time
- Switch date format between UK and US
- Enable file watcher to update log in realtime

Usage
Parse a log file
- Right-click on a .log file in the VSCode Explorer and select "Parse Log File(s)"
2. Open a .log file and click the "Parse Active Log File" button in the editor toolbar
3. Use Command Palette and search for "Parse Log Files(s)"

This extension automatically detects and parses multiple log formats:
The main format used by PatchMyPC applications:
<![LOG[Upload of MigrationId: 687e949ac60e6bcad3b2d23e progress: 74% (37/50 chunks)]LOG]!><time="13:24:32.400967" date="07-21-2025" component="<<UploadMultiFile>b__2>d" context="" type="1" thread="39" file="">
Extracted fields:
- Message: "Upload of MigrationId: 687e949ac60e6bcad3b2d23e progress: 74% (37/50 chunks)"
- Date: 07-21-2025
- Time: 13:24:32.400967
- Component: <b__2>d
- Type: 1 (Info), 2 (Warning), 3 (Error)
- Thread: 39
- Context and File information
Used by Windows components, WSUS, and SMS Provider logs:
Adding Handle -277882112 to async call map~ $$<SMS Provider><08-08-2025 13:14:03.084-60><thread=19996 (0x4E1C)>
Extracted fields:
- Message: "Adding Handle -277882112 to async call map"
- Component: SMS Provider
- Date: 08-08-2025
- Time: 13:14:03.084-60
- Thread: 19996 (0x4E1C)
- Type: Auto-detected from message content
Supports various common log formats with timestamps:
ISO Format (YYYY-MM-DD HH:MM:SS):
2025-08-08 15:26:42.522 [CoreSettings] The settings file is not opened in another process
2025-08-08 15:26:43.099 [ERROR] Failed to connect to database
US Format (MM/DD/YYYY HH:MM:SS):
08/08/2025 15:26:42 [Service] Starting application service
08/08/2025 15:26:43 WARNING: Configuration file not found
European Format (DD/MM/YYYY HH:MM:SS):
08/08/2025 15:26:42 INFO: Processing completed successfully
08/08/2025 15:26:43 ERROR: Connection timeout occurred
Time-only Format (HH:MM:SS):
15:26:42.522 [INFO] Application started
15:26:43.099 [WARN] Low disk space detected
Smart Type Detection
When log entries don't have explicit type information, the parser automatically detects the log level based on message content:
- Error (Type 3): Messages containing "error", "failed", "failure", "exception", "critical", "fatal"
- Warning (Type 2): Messages containing "warning", "warn"
- Info (Type 1): Messages containing "info", "information", "success", "completed", "started", etc.
- Default: Falls back to Info if no keywords are detected
Requirements
- Visual Studio Code 1.102.0 or higher
- Log files in supported formats (auto-detected):
- PatchMyPC XML-like format
- Windows/SMS Provider CMTrace format
- Generic timestamp-based formats (ISO, US, European)
- Plain text logs with time-only timestamps
Known Issues
- Very large log files (>10MB) may cause performance issues during initial parsing
- Complex multi-line log entries may not be parsed correctly in generic formats
- Date formats are auto-detected but may occasionally misinterpret ambiguous dates (e.g., 01/02/2025 could be Jan 2 or Feb 1)