Debugging osascript execution from within a ruby daemon-Collection of common programming errors

I have a need to frequently run an applescript on my web server. As the server is running rails, and I need access to my models before and after running the script, I thought that a daemon (via the daemons gem) might be appropriate.

In theory this is fairly easy. Below is a simplified example.

#!/usr/bin/env ruby

ENV["RAILS_ENV"] ||= "development"

require File.dirname(__FILE__) + "/../../config/application"
Rails.application.require_environment!

$running = true
Signal.trap("TERM") do 
  $running = false
end

while($running) do

  Rails.logger.info "Daemon running at #{Time.now}.\n"

  # sanity check
  %x{touch /foo.txt}

  # this stops working after a while
  result = %x{/usr/bin/osascript -s o /path/to/the/script.scpt}

  # under normal operation, my applescript spits out a string result
  Rails.logger.info "Result: #{result}.\n"

  sleep 30
end

For testing purposes I’ve replaced the (somewhat long and time consuming) production applescript with a one-liner. Here it is, in all its glory:

"It Worked!"

Because applescript treats the last line of the script as a return statement, this string gets passed into my result variable and ultimately logged in rails.

This works great – for a while. Eventually though (typically after several hours) the osascript line stops returning results. The daemon is still running but the osascript line, for all I can tell, is completely failing without explanation.

I can say with certainty that the daemon itself has not died because

  • The rails log entries appear at correct intervals, and
  • My sanity check of “foo.txt” regularly updates its last modified time stamp.

I thought I’d post an update to this in case anyone out there is having a similar problem. First off, I’ve found a workaround. Its an ugly hack for sure, but it gets the job done and it doesn’t crash every 2 hours. What I’m doing is establishing an ssh connection every time the job is run, which effectively lets the script run on a clean session.

Net::SSH.start('127.0.0.1', 'username', :password => 'password') do |ssh|
  result = ssh.exec!('/usr/bin/osascript -s o /path/to/the/script.scpt') 
end

And secondly, I’ve found a large number of crash reports in my ~/Library/Logs/DiagnosticReports directory. More and more I’m starting to believe that this whole ordeal has to do with some kind of session timeout or expiration.

Process:         osascript [24884]
Path:            /usr/bin/osascript
Identifier:      osascript
Version:         ??? (???)
Code Type:       X86-64 (Native)
Parent Process:  ruby [24868]

Date/Time:       2011-02-03 16:40:28.526 -0500
OS Version:      Mac OS X 10.6.6 (10J567)
Report Version:  6

Exception Type:  EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Crashed Thread:  0  Dispatch queue: com.apple.main-thread

Application Specific Information:
abort() called
LaunchServices: GetOurLSSessionIDInit() returned err #1, securitySessionID == 0x0, vers=10600000 uid=501 euid=501web1.local] [Se
/Users/greg/Applescript/fbbuildutil.scpt

Thread 0 Crashed:  Dispatch queue: com.apple.main-thread
0   libSystem.B.dylib               0x00007fff86fd6616 __kill + 10
1   libSystem.B.dylib               0x00007fff87076cca abort + 83
2   com.apple.LaunchServices        0x00007fff82faec84 GetOurLSSessionIDInit() + 298
3   libSystem.B.dylib               0x00007fff86fa08da pthread_once + 95
4   com.apple.LaunchServices        0x00007fff82faf29b SetupCoreApplicationServicesCommunicationPort() + 1343
5   com.apple.LaunchServices        0x00007fff82faf68d getProcessDispatchTable() + 19
6   com.apple.LaunchServices        0x00007fff82fb17a5 LSClientSideSharedMemory::GetClientSideSharedMemory(LSSessionID, bool) + 187
7   com.apple.LaunchServices        0x00007fff82fb1e87 _LSCopyApplicationInformationItem + 43
8   com.apple.AE                    0x00007fff8722b735 aeGetThisProcess() + 49
9   com.apple.AE                    0x00007fff8722b6df AEEventImpl::initializeData() + 89
10  com.apple.AE                    0x00007fff8722b5c4 AEEventImpl::AEEventImpl(unsigned int, unsigned int, AEDesc const*, short, int) + 76
11  com.apple.AE                    0x00007fff8722f33e AECreateAppleEvent + 88
12  osascript                       0x0000000100001a42 0x100000000 + 6722
13  osascript                       0x0000000100000fa0 0x100000000 + 4000

Thread 1:  Dispatch queue: com.apple.libdispatch-manager
0   libSystem.B.dylib               0x00007fff86fa116a kevent + 10
1   libSystem.B.dylib               0x00007fff86fa303d _dispatch_mgr_invoke + 154
2   libSystem.B.dylib               0x00007fff86fa2d14 _dispatch_queue_invoke + 185
3   libSystem.B.dylib               0x00007fff86fa283e _dispatch_worker_thread2 + 252
4   libSystem.B.dylib               0x00007fff86fa2168 _pthread_wqthread + 353
5   libSystem.B.dylib               0x00007fff86fa2005 start_wqthread + 13

Thread 2:
0   libSystem.B.dylib               0x00007fff86fa1f8a __workq_kernreturn + 10
1   libSystem.B.dylib               0x00007fff86fa239c _pthread_wqthread + 917
2   libSystem.B.dylib               0x00007fff86fa2005 start_wqthread + 13

Thread 0 crashed with X86 Thread State (64-bit):
  rax: 0x0000000000000000  rbx: 0x00000000000001f5  rcx: 0x00007fff5fbfb378  rdx: 0x0000000000000000
  rdi: 0x0000000000006134  rsi: 0x0000000000000006  rbp: 0x00007fff5fbfb390  rsp: 0x00007fff5fbfb378
   r8: 0x000000010011d740   r9: 0x00000001001fc0a4  r10: 0x00007fff86fd2656  r11: 0x0000000000000202
  r12: 0x00007fff5fbfb3c0  r13: 0x00007fff703ce328  r14: 0x00007fff82faeb5a  r15: 0x00007fff70c465c0
  rip: 0x00007fff86fd6616  rfl: 0x0000000000000202  cr2: 0x00000001000f8000

Binary Images:
       0x100000000 -        0x100002ff7 +osascript ??? (???)  /usr/bin/osascript
       0x1000f1000 -        0x1000f1fff  com.apple.applescript.component 2.1.2 (2.1.2)  /System/Library/Components/AppleScript.component/Contents/MacOS/AppleScript
       0x100419000 -        0x1004adfe7  com.apple.applescript 2.1.2 (2.1.2)  /System/Library/PrivateFrameworks/AppleScript.framework/Versions/A/AppleScript
    0x7fff5fc00000 -     0x7fff5fc3bdef  dyld 132.1 (???)  /usr/lib/dyld
    0x7fff8011d000 -     0x7fff8011efff  liblangid.dylib ??? (???)  /usr/lib/liblangid.dylib
    0x7fff8016d000 -     0x7fff8046bfe7  com.apple.HIToolbox 1.6.4 (???)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/HIToolbox.framework/Versions/A/HIToolbox
    0x7fff80472000 -     0x7fff804befff  libauto.dylib ??? (???)  /usr/lib/libauto.dylib
    0x7fff804bf000 -     0x7fff80574fe7  com.apple.ink.framework 1.3.3 (107)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Ink.framework/Versions/A/Ink
    0x7fff8071a000 -     0x7fff80784fe7  libvMisc.dylib 268.0.1 (compatibility 1.0.0)  /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libvMisc.dylib
    0x7fff80791000 -     0x7fff80794ff7  com.apple.securityhi 4.0 (36638)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/SecurityHI.framework/Versions/A/SecurityHI
    0x7fff80795000 -     0x7fff808aefef  libGLProgrammability.dylib ??? (???)  /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLProgrammability.dylib
    0x7fff808b0000 -     0x7fff8092dfef  libstdc++.6.dylib 7.9.0 (compatibility 7.0.0)  /usr/lib/libstdc++.6.dylib
    0x7fff80949000 -     0x7fff80949ff7  com.apple.ApplicationServices 38 (38)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/ApplicationServices
    0x7fff80a2b000 -     0x7fff80ba2fe7  com.apple.CoreFoundation 6.6.4 (550.42)  /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
    0x7fff80ba3000 -     0x7fff813adfe7  libBLAS.dylib 219.0.0 (compatibility 1.0.0)  /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
    0x7fff813ae000 -     0x7fff813b4ff7  com.apple.DiskArbitration 2.3 (2.3)  /System/Library/Frameworks/DiskArbitration.framework/Versions/A/DiskArbitration
    0x7fff813e6000 -     0x7fff813e9ff7  libCoreVMClient.dylib ??? (???)  /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libCoreVMClient.dylib
    0x7fff813ea000 -     0x7fff813fefff  libGL.dylib ??? (???)  /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib
    0x7fff81480000 -     0x7fff814b9fef  libcups.2.dylib 2.8.0 (compatibility 2.0.0)  /usr/lib/libcups.2.dylib
    0x7fff816aa000 -     0x7fff816f4ff7  com.apple.Metadata 10.6.3 (507.15)  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/Metadata.framework/Versions/A/Metadata
    0x7fff8185b000 -     0x7fff81876ff7  com.apple.openscripting 1.3.1 (???)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/OpenScripting.framework/Versions/A/OpenScripting
    0x7fff818b9000 -     0x7fff81901ff7  libvDSP.dylib 268.0.1 (compatibility 1.0.0)  /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libvDSP.dylib
    0x7fff81940000 -     0x7fff8194ffff  com.apple.NetFS 3.2.1 (3.2.1)  /System/Library/Frameworks/NetFS.framework/Versions/A/NetFS
    0x7fff81950000 -     0x7fff81a67fef  libxml2.2.dylib 10.3.0 (compatibility 10.0.0)  /usr/lib/libxml2.2.dylib
    0x7fff81a98000 -     0x7fff81b51fff  libsqlite3.dylib 9.6.0 (compatibility 9.0.0)  /usr/lib/libsqlite3.dylib
    0x7fff81b52000 -     0x7fff81c07fe7  com.apple.ColorSync 4.6.3 (4.6.3)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ColorSync.framework/Versions/A/ColorSync
    0x7fff81c08000 -     0x7fff81c33ff7  libxslt.1.dylib 3.24.0 (compatibility 3.0.0)  /usr/lib/libxslt.1.dylib
    0x7fff81e28000 -     0x7fff81e59fff  libGLImage.dylib ??? (???)  /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLImage.dylib
    0x7fff81e5a000 -     0x7fff81e6cfe7  libsasl2.2.dylib 3.15.0 (compatibility 3.0.0)  /usr/lib/libsasl2.2.dylib
    0x7fff81e6d000 -     0x7fff81f2aff7  com.apple.CoreServices.OSServices 357 (357)  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/OSServices.framework/Versions/A/OSServices
    0x7fff81f2b000 -     0x7fff81f30ff7  com.apple.CommonPanels 1.2.4 (91)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/CommonPanels.framework/Versions/A/CommonPanels
    0x7fff81f47000 -     0x7fff81f6ffff  com.apple.DictionaryServices 1.1.2 (1.1.2)  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/DictionaryServices.framework/Versions/A/DictionaryServices
    0x7fff81fce000 -     0x7fff81fceff7  com.apple.Carbon 150 (152)  /System/Library/Frameworks/Carbon.framework/Versions/A/Carbon
    0x7fff81fe1000 -     0x7fff81fe4fff  com.apple.help 1.3.1 (41)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Help.framework/Versions/A/Help
    0x7fff81fe5000 -     0x7fff81ff9ff7  com.apple.speech.synthesis.framework 3.10.35 (3.10.35)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/SpeechSynthesis.framework/Versions/A/SpeechSynthesis
    0x7fff81ffa000 -     0x7fff8201dfff  com.apple.opencl 12.3 (12.3)  /System/Library/Frameworks/OpenCL.framework/Versions/A/OpenCL
    0x7fff8201e000 -     0x7fff82024ff7  com.apple.CommerceCore 1.0 (6)  /System/Library/PrivateFrameworks/CommerceKit.framework/Versions/A/Frameworks/CommerceCore.framework/Versions/A/CommerceCore
    0x7fff82073000 -     0x7fff82088ff7  com.apple.LangAnalysis 1.6.6 (1.6.6)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/LangAnalysis.framework/Versions/A/LangAnalysis
    0x7fff82107000 -     0x7fff82148fff  com.apple.SystemConfiguration 1.10.5 (1.10.2)  /System/Library/Frameworks/SystemConfiguration.framework/Versions/A/SystemConfiguration
    0x7fff82149000 -     0x7fff823cffff  com.apple.security 6.1.1 (37594)  /System/Library/Frameworks/Security.framework/Versions/A/Security
    0x7fff825d4000 -     0x7fff825d5ff7  com.apple.audio.units.AudioUnit 1.6.5 (1.6.5)  /System/Library/Frameworks/AudioUnit.framework/Versions/A/AudioUnit
    0x7fff825d6000 -     0x7fff825e5fff  com.apple.opengl 1.6.12 (1.6.12)  /System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL
    0x7fff825e6000 -     0x7fff8269cfff  libobjc.A.dylib 227.0.0 (compatibility 1.0.0)  /usr/lib/libobjc.A.dylib
    0x7fff8269d000 -     0x7fff826fdfe7  com.apple.framework.IOKit 2.0 (???)  /System/Library/Frameworks/IOKit.framework/Versions/A/IOKit
    0x7fff8287e000 -     0x7fff828a4fe7  libJPEG.dylib ??? (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libJPEG.dylib
    0x7fff828eb000 -     0x7fff82c1ffff  com.apple.CoreServices.CarbonCore 861.23 (861.23)  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CarbonCore.framework/Versions/A/CarbonCore
    0x7fff82ca9000 -     0x7fff82d28fe7  com.apple.audio.CoreAudio 3.2.6 (3.2.6)  /System/Library/Frameworks/CoreAudio.framework/Versions/A/CoreAudio
    0x7fff82d29000 -     0x7fff82dd8fff  edu.mit.Kerberos 6.5.10 (6.5.10)  /System/Library/Frameworks/Kerberos.framework/Versions/A/Kerberos
    0x7fff82fa2000 -     0x7fff83042fff  com.apple.LaunchServices 362.2 (362.2)  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/LaunchServices
    0x7fff83055000 -     0x7fff83213fff  libicucore.A.dylib 40.0.0 (compatibility 1.0.0)  /usr/lib/libicucore.A.dylib
    0x7fff83214000 -     0x7fff833cbfef  com.apple.ImageIO.framework 3.0.4 (3.0.4)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/ImageIO
    0x7fff833cc000 -     0x7fff833cdff7  libScreenReader.dylib ??? (???)  /usr/lib/libScreenReader.dylib
    0x7fff833ce000 -     0x7fff833ceff7  com.apple.CoreServices 44 (44)  /System/Library/Frameworks/CoreServices.framework/Versions/A/CoreServices
    0x7fff8340c000 -     0x7fff8340dff7  com.apple.TrustEvaluationAgent 1.1 (1)  /System/Library/PrivateFrameworks/TrustEvaluationAgent.framework/Versions/A/TrustEvaluationAgent
    0x7fff8340e000 -     0x7fff83427fff  com.apple.CFOpenDirectory 10.6 (10.6)  /System/Library/Frameworks/OpenDirectory.framework/Versions/A/Frameworks/CFOpenDirectory.framework/Versions/A/CFOpenDirectory
    0x7fff83428000 -     0x7fff834a6fff  com.apple.CoreText 3.5.0 (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreText.framework/Versions/A/CoreText
    0x7fff83730000 -     0x7fff83782ff7  com.apple.HIServices 1.8.2 (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/HIServices.framework/Versions/A/HIServices
    0x7fff8381c000 -     0x7fff83942fff  com.apple.audio.toolbox.AudioToolbox 1.6.5 (1.6.5)  /System/Library/Frameworks/AudioToolbox.framework/Versions/A/AudioToolbox
    0x7fff83943000 -     0x7fff83992ff7  com.apple.DirectoryService.PasswordServerFramework 6.0 (6.0)  /System/Library/PrivateFrameworks/PasswordServer.framework/Versions/A/PasswordServer
    0x7fff83993000 -     0x7fff839a9fef  libbsm.0.dylib ??? (???)  /usr/lib/libbsm.0.dylib
    0x7fff839f7000 -     0x7fff83ac9fe7  com.apple.CFNetwork 454.11.5 (454.11.5)  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CFNetwork.framework/Versions/A/CFNetwork
    0x7fff83bb1000 -     0x7fff83bb1ff7  com.apple.Accelerate 1.6 (Accelerate 1.6)  /System/Library/Frameworks/Accelerate.framework/Versions/A/Accelerate
    0x7fff83bb2000 -     0x7fff83c4cfff  com.apple.ApplicationServices.ATS 4.4 (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ATS.framework/Versions/A/ATS
    0x7fff83c4d000 -     0x7fff83c63fff  com.apple.ImageCapture 6.0.1 (6.0.1)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/ImageCapture.framework/Versions/A/ImageCapture
    0x7fff84091000 -     0x7fff841b2fe7  libcrypto.0.9.8.dylib 0.9.8 (compatibility 0.9.8)  /usr/lib/libcrypto.0.9.8.dylib
    0x7fff841bb000 -     0x7fff841d1fe7  com.apple.MultitouchSupport.framework 207.10 (207.10)  /System/Library/PrivateFrameworks/MultitouchSupport.framework/Versions/A/MultitouchSupport
    0x7fff841e4000 -     0x7fff84269ff7  com.apple.print.framework.PrintCore 6.3 (312.7)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/PrintCore.framework/Versions/A/PrintCore
    0x7fff8426a000 -     0x7fff84607fe7  com.apple.QuartzCore 1.6.3 (227.34)  /System/Library/Frameworks/QuartzCore.framework/Versions/A/QuartzCore
    0x7fff8463e000 -     0x7fff8463eff7  com.apple.vecLib 3.6 (vecLib 3.6)  /System/Library/Frameworks/vecLib.framework/Versions/A/vecLib
    0x7fff84927000 -     0x7fff84932ff7  com.apple.speech.recognition.framework 3.11.1 (3.11.1)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/SpeechRecognition.framework/Versions/A/SpeechRecognition
    0x7fff84d5e000 -     0x7fff84d63fff  libGIF.dylib ??? (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libGIF.dylib
    0x7fff84da8000 -     0x7fff851ebfef  libLAPACK.dylib 219.0.0 (compatibility 1.0.0)  /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libLAPACK.dylib
    0x7fff85efd000 -     0x7fff85f1dff7  com.apple.DirectoryService.Framework 3.6 (621.9)  /System/Library/Frameworks/DirectoryService.framework/Versions/A/DirectoryService
    0x7fff85f1e000 -     0x7fff85f23fff  libGFXShared.dylib ??? (???)  /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGFXShared.dylib
    0x7fff85f24000 -     0x7fff85ffeff7  com.apple.vImage 4.0 (4.0)  /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vImage.framework/Versions/A/vImage
    0x7fff8603a000 -     0x7fff8673706f  com.apple.CoreGraphics 1.545.0 (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/CoreGraphics.framework/Versions/A/CoreGraphics
    0x7fff86738000 -     0x7fff86738ff7  com.apple.Accelerate.vecLib 3.6 (vecLib 3.6)  /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/vecLib
    0x7fff8687c000 -     0x7fff868c3ff7  com.apple.coreui 2 (114)  /System/Library/PrivateFrameworks/CoreUI.framework/Versions/A/CoreUI
    0x7fff86ab9000 -     0x7fff86b45fef  SecurityFoundation ??? (???)  /System/Library/Frameworks/SecurityFoundation.framework/Versions/A/SecurityFoundation
    0x7fff86b46000 -     0x7fff86b63ff7  libPng.dylib ??? (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libPng.dylib
    0x7fff86b89000 -     0x7fff86baafff  libresolv.9.dylib 41.0.0 (compatibility 1.0.0)  /usr/lib/libresolv.9.dylib
    0x7fff86bab000 -     0x7fff86e2eff7  com.apple.Foundation 6.6.4 (751.42)  /System/Library/Frameworks/Foundation.framework/Versions/C/Foundation
    0x7fff86e2f000 -     0x7fff86f6dfff  com.apple.CoreData 102.1 (251)  /System/Library/Frameworks/CoreData.framework/Versions/A/CoreData
    0x7fff86f87000 -     0x7fff87148fff  libSystem.B.dylib 125.2.1 (compatibility 1.0.0)  /usr/lib/libSystem.B.dylib
    0x7fff8718b000 -     0x7fff8718dfff  libRadiance.dylib ??? (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libRadiance.dylib
    0x7fff871de000 -     0x7fff8721ffef  com.apple.QD 3.36 (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/QD.framework/Versions/A/QD
    0x7fff87229000 -     0x7fff87264fff  com.apple.AE 496.4 (496.4)  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/AE.framework/Versions/A/AE
    0x7fff8728f000 -     0x7fff87293ff7  libmathCommon.A.dylib 315.0.0 (compatibility 1.0.0)  /usr/lib/system/libmathCommon.A.dylib
    0x7fff873bd000 -     0x7fff873ceff7  libz.1.dylib 1.2.3 (compatibility 1.0.0)  /usr/lib/libz.1.dylib
    0x7fff873cf000 -     0x7fff87418fef  libGLU.dylib ??? (???)  /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLU.dylib
    0x7fff87419000 -     0x7fff8746eff7  com.apple.framework.familycontrols 2.0.2 (2020)  /System/Library/PrivateFrameworks/FamilyControls.framework/Versions/A/FamilyControls
    0x7fff8746f000 -     0x7fff874fffff  com.apple.SearchKit 1.3.0 (1.3.0)  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/SearchKit.framework/Versions/A/SearchKit
    0x7fff87528000 -     0x7fff875e9fe7  libFontParser.dylib ??? (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ATS.framework/Versions/A/Resources/libFontParser.dylib
    0x7fff8766e000 -     0x7fff876bdfef  libTIFF.dylib ??? (???)  /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/Resources/libTIFF.dylib
    0x7fff876be000 -     0x7fff876c4ff7  IOSurface ??? (???)  /System/Library/Frameworks/IOSurface.framework/Versions/A/IOSurface
    0x7fff87dce000 -     0x7fff87dd5fff  com.apple.OpenDirectory 10.6 (10.6)  /System/Library/Frameworks/OpenDirectory.framework/Versions/A/OpenDirectory
    0x7fff87fba000 -     0x7fff8809ffef  com.apple.DesktopServices 1.5.9 (1.5.9)  /System/Library/PrivateFrameworks/DesktopServicesPriv.framework/Versions/A/DesktopServicesPriv
    0x7fff884b9000 -     0x7fff884c7ff7  libkxld.dylib ??? (???)  /usr/lib/system/libkxld.dylib
    0x7fff884c8000 -     0x7fff88ebefff  com.apple.AppKit 6.6.7 (1038.35)  /System/Library/Frameworks/AppKit.framework/Versions/C/AppKit
    0x7fff890fb000 -     0x7fff89120ff7  com.apple.CoreVideo 1.6.2 (45.6)  /System/Library/Frameworks/CoreVideo.framework/Versions/A/CoreVideo
    0x7fff89121000 -     0x7fff89123fff  com.apple.print.framework.Print 6.1 (237.1)  /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/Print.framework/Versions/A/Print
    0x7fffffe00000 -     0x7fffffe01fff  libSystem.B.dylib ??? (???)  /usr/lib/libSystem.B.dylib