Skip to content

Add Intel CI testing and diagnostic logging for issue #169#177

Merged
schuyler merged 2 commits intomainfrom
claude/add-intel-ci-and-logging-011y25svcU3Yq4KiRYqP5BV5
Nov 24, 2025
Merged

Add Intel CI testing and diagnostic logging for issue #169#177
schuyler merged 2 commits intomainfrom
claude/add-intel-ci-and-logging-011y25svcU3Yq4KiRYqP5BV5

Conversation

@schuyler
Copy link
Copy Markdown
Owner

Summary

This PR addresses the Intel-specific crash on macOS Sequoia (#169) by adding Intel testing to CI and comprehensive diagnostic logging.

Changes

1. Add macos-15-intel Runner to CI Test Matrix

  • Tests now run on 3 platforms: ARM Sonoma (macos-14), ARM Sequoia (macos-15), and Intel Sequoia (macos-15-intel)
  • Intel code path is now executed in CI, not just cross-compiled
  • Free GitHub Actions runner, available until August 2027
  • Catches Intel-specific bugs before release

2. Add Architecture Verification Step

  • Logs system architecture (uname -m), CPU info, and macOS version
  • Helps verify tests run on correct architecture in CI logs

3. Add Comprehensive Diagnostic Logging

  • Instruments MPPreferences initialization with detailed logging
  • Logs entry/exit of cleanupObsoleteAutosaveValues and migration methods
  • Includes timestamps and thread information
  • Specifically logs dictionaryRepresentation calls that may hang on Intel Sequoia
  • Output to NSLog, visible in Console.app for user diagnosis

Testing Approach

This PR enables two diagnostic paths:

  1. CI Detection: If the crash reproduces on the Intel runner, we'll get logs and stack traces
  2. User-Assisted Diagnosis: If it doesn't reproduce in CI, users (like @benel) can capture Console.app logs to identify the exact crash point

Expected Outcomes

  • ✅ Intel-specific bugs caught in CI
  • ✅ Diagnostic data for crash investigation
  • ✅ Future prevention of architecture-specific issues

Related Issue

Related to #169

Notes

The diagnostic logging is intentionally verbose to help identify the crash point. Once #169 is resolved, we can reduce verbosity if needed.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Nov 24, 2025

Code Coverage Report

Current Coverage: 35.50%

Coverage Details (Summary)
Name                                                                                                                                   Coverage            
-------------------------------------------------------------------------------------------------------------------------------------- ------------------- 
MASPreferences.bundle                                                                                                                  0.00% (0/0)         
MacDown 3000.app                                                                                                                       42.00% (5228/12448) 
    /Users/runner/work/macdown3000/macdown3000/MacDown/Code/Utility/MPMathJaxListener.m                                                0.00% (0/26)        
        -[MPMathJaxListener callbacks]                                                                                                 0.00% (0/5)         
        -[MPMathJaxListener addCallback:forKey:]                                                                                       0.00% (0/3)         
        -[MPMathJaxListener invokeCallbackForKey:]                                                                                     0.00% (0/8)         
        +[MPMathJaxListener isSelectorExcludedFromWebScript:]                                                                          0.00% (0/5)         
        +[MPMathJaxListener isKeyExcludedFromWebScript:]                                                                               0.00% (0/5)         
    /Users/runner/work/macdown3000/macdown3000/MacDown/Code/Document/MPAsset.m                                                         92.79% (103/111)    
        -[MPAsset typeName]                                                                                                            100.00% (3/3)       
        -[MPAsset defaultTypeName]                                                                                                     100.00% (3/3)       
        +[MPAsset assetWithURL:andType:]                                                                                               100.00% (3/3)       
        -[MPAsset initWithURL:andType:]                                                                                                87.50% (7/8)        
        -[MPAsset init]                                                                                                                100.00% (3/3)       
        -[MPAsset templateForOption:]                                                                                                  0.00% (0/6)         
        -[MPAsset htmlForOption:]                                                                                                      96.43% (27/28)      
        -[MPStyleSheet defaultTypeName]                                                                                                100.00% (3/3)       
        +[MPStyleSheet CSSWithURL:]                                                                                                    100.00% (3/3)       
        -[MPStyleSheet templateForOption:]                                                                                             100.00% (20/20)     
        -[MPScript defaultTypeName]                                                                                                    100.00% (3/3)       
        +[MPScript javaScriptWithURL:]                                                                                                 100.00% (3/3)       
        -[MPScript templateForOption:]                                                                                                 100.00% (20/20)     
        -[MPEmbeddedScript htmlForOption:]                                                                                             100.00% (5/5)       
    /Users/runner/work/macdown3000/macdown3000/Dependency/peg-markdown-highlight/HGMarkdownHighlightingStyle.m                         87.69% (57/65)      
        +[HGMarkdownHighlightingStyle colorFromARGBColor:]                                                                             100.00% (6/6)       
        -[HGMarkdownHighlightingStyle initWithType:attributesToAdd:toRemove:fontTraitsToAdd:]                                          88.89% (8/9)        
        -[HGMarkdownHighlightingStyle initWithStyleAttributes:baseFont:]                                                               86.00% (43/50)      
    /Users/runner/work/macdown3000/macdown3000/MacDown/Code/Utility/MPPlugIn.m                                                         0.00% (0/36)        
        -[MPPlugIn setName:]                                                                                                           0.00% (0/3)         
        -[MPPlugIn initWithBundle:]                                                                                                    0.00% (0/24)        
        -[MPPlugIn plugInDidInitialize]                                                                                                0.00% (0/4)         
        -[MPPlugIn run:]                                                                                                               0.00% (0/5)         
    /Users/runner/work/macdown3000/macdown3000/MacDown/Code/Extension/hoedown_html_patch.c                                             73.64% (95/129)     
        hoedown_patch_render_blockcode                                                                                                 89.09% (49/55)      
        hoedown_patch_render_listitem                                                                                                  100.00% (46/46)     
        hoedown_patch_render_toc_header                                                                                                0.00% (0/28)        
    /Users/runner/work/macdown3000/macdown3000/MacDown/Code/Application/MPMainController.m                                             40.76% (97/238)     
        MPOpenBundledFile                                                                                                              95.24% (20/21)      
        __MPOpenBundledFile_block_invoke                                                                                               85.71% (6/7)        
        treat                                                                                                                          20.00% (6/30)       
        __treat_block_invoke                                                                                                           0.00% (0/3)         
        -[MPMainController applicationDidFinishLaunching:]                                                                             100.00% (6/6)       
        -[MPMainController openUrlSchemeAppleEvent:withReplyEvent:]                                                                    0.00% (0/45)        
        __59-[MPMainController openUrlSchemeAppleEvent:withReplyEvent:]_block_invoke                                                   0.00% (0/7)         
        -[MPMainController valueForKey:fromQueryItems:]                                                                                0.00% (0/5)         
        -[MPMainController preferences]                                                                                                100.00% (3/3)       
        -[MPMainController preferencesWindowController]                                                                                0.00% (0/18)        
        -[MPMainController showPreferencesWindow:]                                                                                     0.00% (0/2)         

... (2056 more lines truncated)

📊 **Full coverage report available in workflow artifacts**

This addresses the Intel-specific crash on macOS Sequoia by:

1. Adding macos-15-intel runner to CI test matrix
   - Tests now run on Apple Silicon (macos-14, macos-15) AND Intel (macos-15-intel)
   - Intel code path is now tested in CI, not just cross-compiled
   - Free GitHub Actions runner, available until August 2027

2. Adding architecture verification step to CI
   - Logs system architecture, CPU info, and macOS version
   - Helps verify tests run on correct architecture

3. Adding comprehensive diagnostic logging to MPPreferences
   - Logs all initialization steps with timestamps and thread info
   - Specifically instruments cleanupObsoleteAutosaveValues and migration
   - Logs dictionaryRepresentation calls that may hang on Intel Sequoia
   - Output to NSLog visible in Console.app for user diagnosis

These changes enable:
- Detection of Intel-specific bugs in CI before release
- User-assisted diagnosis via Console.app logs
- Identification of exact crash point if issue reproduces

Related to #169
Updated documentation to reflect the addition of macos-15-intel runner
and architecture verification step in CI.

Changes:
- test_coverage_improvement_plan.md: Added Intel testing to CI infrastructure
- infrastructure_evaluation.md: Added macos-15-intel runner and architecture verification

Related to #169
@schuyler schuyler force-pushed the claude/add-intel-ci-and-logging-011y25svcU3Yq4KiRYqP5BV5 branch from 575a7ec to 8293459 Compare November 24, 2025 03:05
@schuyler schuyler merged commit 7dfca67 into main Nov 24, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants