Git Product home page Git Product logo

macos-wakatime's Introduction

macos-wakatime

Mac system tray app for automatic time tracking and metrics generated from your Xcode activity.

Install

  1. Download the latest release.
  2. Move WakaTime.app into your Applications folder, and run WakaTime.app.
  3. Enter your WakaTime API Key, then press Save.
  4. Use Xcode like normal and your coding activity will be displayed on your WakaTime dashboard

Usage

Keep the app running in your system tray, and your Xcode usage will show on your WakaTime dashboard.

Building from Source

  1. Run xcodegen to generate the project.
  2. Open the project with Xcode.
  3. Click Run (⌘+R).

If you run into Accessibility problems, try running sudo tccutil reset Accessibility.

Uninstall

To uninstall, move WakaTime.app into your mac Trash.

If you don’t use any other WakaTime plugins, run rm -r ~/.wakatime*.

Supported Apps

Before requesting support for a new app, first check the list of supported apps.

SwiftLint

To fix linter warning(s), run swiftlint --fix.

Contributing

Pull requests and issues are welcome! See Contributing for more details. The main thing to know is we require specific branch name prefixes for PRs:

  • ^major/.+ - major
  • ^feature/.+ - minor
  • ^bugfix/.+ - patch
  • ^docs?/.+ - build
  • ^misc/.+ - build

Many thanks to all contributors!

Made with ❤️ by the WakaTime Team.

macos-wakatime's People

Contributors

alanhamlett avatar chesteryue avatar gandarez avatar havhingstor avatar jfcrockett avatar mmavrispaleblue avatar starbugs avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

macos-wakatime's Issues

Prevent Changed Notifications firing too often

The kAXSelectedTextChangedNotification and kAXValueChangedNotification notifications are firing too often, even when cursor position hasn't changed. They basically continuously fire which causes time to be logged even when the user is AFK.

Possible solutions:

  1. Disable kAXSelectedTextChangedNotification and kAXValueChangedNotification but have reduced accuracy and possible missing time.
  2. Find alternative notifications which only fire when the cursor is moved.
  3. Leave kAXSelectedTextChangedNotification and kAXValueChangedNotification enabled, but track the mouse x/y position on the screen and make these notifications return early if the mouse position hasn't changed. This also means returning early if Xcode isn't the focused application, but we already should be doing that.

Not tracking on Mac m1

Supposed behavior: Track XCode

Actual behavior: does not track XCode

Environment: XCode
OS: Mac

  • Platform: arm64

Logs:

image

App crash on opening file with space in path

Hi, love the fact that Wakatime for Xcode is back! ❤️

I am experiencing an issue however where the app will frequently crash on me. After playing around with it for a while (thanks for logging when the active document changed, that helped me find the issue), it appears I can reliably reproduce it by opening a file in Xcode that has a space in it's path, e.g. /path/to/project/Sources/Directory Name/File.swift. In Console I see the log

Document changed: /path/to/project/Sources/Directory

instead of the full path I'm seeing for other files as well. I haven't checked the source yet, but it's seems to be reliably reproducible on my end like that.

Files with a space in their path still aren't registered for the dashboard

It seems like my fix didn't fix every problem, as those files don't appear in the dashboard.

Log:

2023-03-28 19:47:01.160313+0200 WakaTime-Test[9094:3182726] App changed from nil to Xcode
2023-03-28 19:47:01.174944+0200 WakaTime-Test[9094:3182726] Added notification AXFocusedUIElementChanged to observer <AXObserver 0x600003991a90> {pid=7233}
2023-03-28 19:47:01.175076+0200 WakaTime-Test[9094:3182726] Added notification AXSelectedTextChanged to observer <AXObserver 0x600003991a90> {pid=7233}
2023-03-28 19:47:01.175140+0200 WakaTime-Test[9094:3182726] Added observer <AXObserver 0x600003991a90> {pid=7233} to run loop
2023-03-28 19:47:01.175170+0200 WakaTime-Test[9094:3182726] Watching for file changes on Xcode
2023-03-28 19:47:01.493615+0200 WakaTime-Test[9094:3183359] [connection] nw_proxy_resolver_create_parsed_array [C1.1.1 proxy pac] Evaluation error: kCFErrorDomainCFNetwork: 308
2023-03-28 19:47:01.853237+0200 WakaTime-Test[9094:3183345] [connection] nw_proxy_resolver_create_parsed_array [C2.1.1 proxy pac] Evaluation error: kCFErrorDomainCFNetwork: 308
2023-03-28 19:47:02.334804+0200 WakaTime-Test[9094:3183359] [connection] nw_proxy_resolver_create_parsed_array [C3.1.1 proxy pac] Evaluation error: kCFErrorDomainCFNetwork: 308
2023-03-28 19:47:15.158892+0200 WakaTime-Test[9094:3182726] [Window] Warning: Window NSMenuWindowManagerWindow 0x120639450 ordered front from a non-active application and may order beneath the active application's windows.
2023-03-28 19:47:16.701558+0200 WakaTime-Test[9094:3182726] Metal API Validation Enabled
2023-03-28 19:47:16.775151+0200 WakaTime-Test[9094:3182726] [Window] Warning: Window SwiftUI.AppKitWindow 0x120785dd0 ordered front from a non-active application and may order beneath the active application's windows.
2023-03-28 19:47:16.838948+0200 WakaTime-Test[9094:3182726] App changed from Xcode to WakaTime-Test
2023-03-28 19:47:16.839690+0200 WakaTime-Test[9094:3182726] Removed observer <AXObserver 0x600003991a90> {pid=7233} from run loop
2023-03-28 19:47:16.839900+0200 WakaTime-Test[9094:3182726] Removed notification AXFocusedUIElementChanged from observer <AXObserver 0x600003991a90> {pid=7233}
2023-03-28 19:47:16.839986+0200 WakaTime-Test[9094:3182726] Removed notification AXSelectedTextChanged from observer <AXObserver 0x600003991a90> {pid=7233}
2023-03-28 19:47:16.840098+0200 WakaTime-Test[9094:3182726] Removed notification AXValueChanged from observer <AXObserver 0x600003991a90> {pid=7233}
2023-03-28 19:47:16.840141+0200 WakaTime-Test[9094:3182726] Stopped watching Xcode
2023-03-28 19:47:16.905000+0200 WakaTime-Test[9094:3183759] fopen failed for data file: errno = 2 (No such file or directory)
2023-03-28 19:47:16.905054+0200 WakaTime-Test[9094:3183759] Errors found! Invalidating cache...
2023-03-28 19:47:16.931380+0200 WakaTime-Test[9094:3183759] fopen failed for data file: errno = 2 (No such file or directory)
2023-03-28 19:47:16.931421+0200 WakaTime-Test[9094:3183759] Errors found! Invalidating cache...
2023-03-28 19:47:24.651004+0200 WakaTime-Test[9094:3182726] App changed from WakaTime-Test to Xcode
2023-03-28 19:47:24.710623+0200 WakaTime-Test[9094:3182726] Added notification AXFocusedUIElementChanged to observer <AXObserver 0x60000390a030> {pid=7233}
2023-03-28 19:47:24.710856+0200 WakaTime-Test[9094:3182726] Added notification AXSelectedTextChanged to observer <AXObserver 0x60000390a030> {pid=7233}
2023-03-28 19:47:24.710960+0200 WakaTime-Test[9094:3182726] Added observer <AXObserver 0x60000390a030> {pid=7233} to run loop
2023-03-28 19:47:24.711027+0200 WakaTime-Test[9094:3182726] Watching for file changes on Xcode
2023-03-28 19:47:28.155666+0200 WakaTime-Test[9094:3182726] App changed from Xcode to Safari
2023-03-28 19:47:28.156024+0200 WakaTime-Test[9094:3182726] Removed observer <AXObserver 0x60000390a030> {pid=7233} from run loop
2023-03-28 19:47:28.202287+0200 WakaTime-Test[9094:3182726] Removed notification AXFocusedUIElementChanged from observer <AXObserver 0x60000390a030> {pid=7233}
2023-03-28 19:47:28.202867+0200 WakaTime-Test[9094:3182726] Removed notification AXSelectedTextChanged from observer <AXObserver 0x60000390a030> {pid=7233}
2023-03-28 19:47:28.203021+0200 WakaTime-Test[9094:3182726] Removed notification AXValueChanged from observer <AXObserver 0x60000390a030> {pid=7233}
2023-03-28 19:47:28.203102+0200 WakaTime-Test[9094:3182726] Stopped watching Xcode
2023-03-28 19:47:41.531247+0200 WakaTime-Test[9094:3182726] App changed from Safari to Xcode
2023-03-28 19:47:41.584673+0200 WakaTime-Test[9094:3182726] Added notification AXFocusedUIElementChanged to observer <AXObserver 0x6000039e6850> {pid=7233}
2023-03-28 19:47:41.584979+0200 WakaTime-Test[9094:3182726] Added notification AXSelectedTextChanged to observer <AXObserver 0x6000039e6850> {pid=7233}
2023-03-28 19:47:41.585087+0200 WakaTime-Test[9094:3182726] Added observer <AXObserver 0x6000039e6850> {pid=7233} to run loop
2023-03-28 19:47:41.585150+0200 WakaTime-Test[9094:3182726] Watching for file changes on Xcode
2023-03-28 19:48:12.183360+0200 WakaTime-Test[9094:3182726] Created FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/Watcher.swift
2023-03-28 19:48:12.183378+0200 WakaTime-Test[9094:3183783] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/Watcher.swift isWrite: false
2023-03-28 19:48:21.542599+0200 WakaTime-Test[9094:3183783] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: false
2023-03-28 19:48:21.542581+0200 WakaTime-Test[9094:3182726] Deleted FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/Watcher.swift
2023-03-28 19:48:21.542823+0200 WakaTime-Test[9094:3182726] Created FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift
2023-03-28 19:48:33.727046+0200 WakaTime-Test[9094:3186078] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: true
2023-03-28 19:48:33.729339+0200 WakaTime-Test[9094:3186078] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: true
2023-03-28 19:48:33.748532+0200 WakaTime-Test[9094:3186078] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: true
2023-03-28 19:48:36.054004+0200 WakaTime-Test[9094:3186078] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: true
2023-03-28 19:48:36.326089+0200 WakaTime-Test[9094:3186078] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: true
2023-03-28 19:48:36.843419+0200 WakaTime-Test[9094:3186078] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: true
2023-03-28 19:48:37.023178+0200 WakaTime-Test[9094:3186078] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: true
2023-03-28 19:48:37.382644+0200 WakaTime-Test[9094:3186078] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: true
2023-03-28 19:48:47.746652+0200 WakaTime-Test[9094:3186650] Document changed: /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift isWrite: false
2023-03-28 19:48:47.746637+0200 WakaTime-Test[9094:3182726] Deleted FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift
2023-03-28 19:48:47.746916+0200 WakaTime-Test[9094:3182726] Created FileMonitor for /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift
2023-03-28 19:48:54.435388+0200 WakaTime-Test[9094:3182726] Deleted FileMonitor for /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift
2023-03-28 19:48:54.435661+0200 WakaTime-Test[9094:3182726] Created FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift
2023-03-28 19:48:54.436340+0200 WakaTime-Test[9094:3186648] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: false
2023-03-28 19:48:57.645332+0200 WakaTime-Test[9094:3182726] App changed from Xcode to Safari
2023-03-28 19:48:57.645680+0200 WakaTime-Test[9094:3182726] Removed observer <AXObserver 0x6000039e6850> {pid=7233} from run loop
2023-03-28 19:48:57.653902+0200 WakaTime-Test[9094:3182726] Removed notification AXFocusedUIElementChanged from observer <AXObserver 0x6000039e6850> {pid=7233}
2023-03-28 19:48:57.732326+0200 WakaTime-Test[9094:3182726] Removed notification AXSelectedTextChanged from observer <AXObserver 0x6000039e6850> {pid=7233}
2023-03-28 19:48:57.733107+0200 WakaTime-Test[9094:3182726] Removed notification AXValueChanged from observer <AXObserver 0x6000039e6850> {pid=7233}
2023-03-28 19:48:57.733231+0200 WakaTime-Test[9094:3182726] Stopped watching Xcode
2023-03-28 19:49:08.502401+0200 WakaTime-Test[9094:3182726] App changed from Safari to Xcode
2023-03-28 19:49:08.596885+0200 WakaTime-Test[9094:3182726] Added notification AXFocusedUIElementChanged to observer <AXObserver 0x6000039f4050> {pid=7233}
2023-03-28 19:49:08.597133+0200 WakaTime-Test[9094:3182726] Added notification AXSelectedTextChanged to observer <AXObserver 0x6000039f4050> {pid=7233}
2023-03-28 19:49:08.597238+0200 WakaTime-Test[9094:3182726] Added observer <AXObserver 0x6000039f4050> {pid=7233} to run loop
2023-03-28 19:49:08.597301+0200 WakaTime-Test[9094:3182726] Watching for file changes on Xcode
2023-03-28 19:49:09.585554+0200 WakaTime-Test[9094:3182726] Deleted FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift
2023-03-28 19:49:09.585858+0200 WakaTime-Test[9094:3182726] Created FileMonitor for /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift
2023-03-28 19:49:09.586296+0200 WakaTime-Test[9094:3188019] Document changed: /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift isWrite: false
2023-03-28 19:49:39.917553+0200 WakaTime-Test[9094:3188021] Document changed: /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift isWrite: true
2023-03-28 19:49:39.918919+0200 WakaTime-Test[9094:3188021] Document changed: /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift isWrite: true
2023-03-28 19:49:39.925515+0200 WakaTime-Test[9094:3188021] Document changed: /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift isWrite: true
2023-03-28 19:49:40.090728+0200 WakaTime-Test[9094:3188021] Document changed: /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift isWrite: true
2023-03-28 19:49:40.268290+0200 WakaTime-Test[9094:3188021] Document changed: /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift isWrite: true
2023-03-28 19:49:41.798555+0200 WakaTime-Test[9094:3182726] App changed from Xcode to Safari
2023-03-28 19:49:41.798862+0200 WakaTime-Test[9094:3182726] Removed observer <AXObserver 0x6000039f4050> {pid=7233} from run loop
2023-03-28 19:49:41.835693+0200 WakaTime-Test[9094:3182726] Removed notification AXFocusedUIElementChanged from observer <AXObserver 0x6000039f4050> {pid=7233}
2023-03-28 19:49:41.838413+0200 WakaTime-Test[9094:3182726] Removed notification AXSelectedTextChanged from observer <AXObserver 0x6000039f4050> {pid=7233}
2023-03-28 19:49:41.838676+0200 WakaTime-Test[9094:3182726] Removed notification AXValueChanged from observer <AXObserver 0x6000039f4050> {pid=7233}
2023-03-28 19:49:41.838767+0200 WakaTime-Test[9094:3182726] Stopped watching Xcode
2023-03-28 19:49:45.619670+0200 WakaTime-Test[9094:3188021] Received XPC error Connection interrupted for message type 3 kCFNetworkAgentXPCMessageTypePACQuery
2023-03-28 19:49:45.622473+0200 WakaTime-Test[9094:3188021] Received XPC error Connection invalid for message type 3 kCFNetworkAgentXPCMessageTypePACQuery
2023-03-28 19:49:47.017635+0200 WakaTime-Test[9094:3182726] App changed from Safari to Xcode
2023-03-28 19:49:47.025764+0200 WakaTime-Test[9094:3182726] Added notification AXFocusedUIElementChanged to observer <AXObserver 0x6000039f9fe0> {pid=7233}
2023-03-28 19:49:47.025970+0200 WakaTime-Test[9094:3182726] Added notification AXSelectedTextChanged to observer <AXObserver 0x6000039f9fe0> {pid=7233}
2023-03-28 19:49:47.026059+0200 WakaTime-Test[9094:3182726] Added observer <AXObserver 0x6000039f9fe0> {pid=7233} to run loop
2023-03-28 19:49:47.026119+0200 WakaTime-Test[9094:3182726] Watching for file changes on Xcode
2023-03-28 19:49:47.121847+0200 WakaTime-Test[9094:3182726] Deleted FileMonitor for /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift
2023-03-28 19:49:47.122140+0200 WakaTime-Test[9094:3182726] Created FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift
2023-03-28 19:49:47.129359+0200 WakaTime-Test[9094:3189304] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: false
2023-03-28 19:49:47.959790+0200 WakaTime-Test[9094:3182726] Deleted FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift
2023-03-28 19:49:47.960086+0200 WakaTime-Test[9094:3182726] Created FileMonitor for /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift
2023-03-28 19:49:47.960192+0200 WakaTime-Test[9094:3189304] Document changed: /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift isWrite: false
2023-03-28 19:49:48.517178+0200 WakaTime-Test[9094:3182726] Deleted FileMonitor for /Users/paul/Programmieren/Swift/100 Days of SwiftUI/Multiplication/Multiplication/ContentView.swift
2023-03-28 19:49:48.517239+0200 WakaTime-Test[9094:3189277] Document changed: /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift isWrite: false
2023-03-28 19:49:48.517446+0200 WakaTime-Test[9094:3182726] Created FileMonitor for /Users/paul/Programmieren/Swift/macos-wakatime/WakaTime/WakaTime.swift
2023-03-28 19:49:49.866023+0200 WakaTime-Test[9094:3182726] App changed from Xcode to Safari
2023-03-28 19:49:49.868121+0200 WakaTime-Test[9094:3182726] Removed observer <AXObserver 0x6000039f9fe0> {pid=7233} from run loop
2023-03-28 19:49:49.889101+0200 WakaTime-Test[9094:3182726] Removed notification AXFocusedUIElementChanged from observer <AXObserver 0x6000039f9fe0> {pid=7233}
2023-03-28 19:49:49.889471+0200 WakaTime-Test[9094:3182726] Removed notification AXSelectedTextChanged from observer <AXObserver 0x6000039f9fe0> {pid=7233}
2023-03-28 19:49:49.889603+0200 WakaTime-Test[9094:3182726] Removed notification AXValueChanged from observer <AXObserver 0x6000039f9fe0> {pid=7233}
2023-03-28 19:49:49.889750+0200 WakaTime-Test[9094:3182726] Stopped watching Xcode
2023-03-28 19:50:06.174978+0200 WakaTime-Test[9094:3182726] App changed from Safari to Xcode
2023-03-28 19:50:06.246812+0200 WakaTime-Test[9094:3182726] Added notification AXFocusedUIElementChanged to observer <AXObserver 0x600003909bd0> {pid=7233}
2023-03-28 19:50:06.247761+0200 WakaTime-Test[9094:3182726] Added notification AXSelectedTextChanged to observer <AXObserver 0x600003909bd0> {pid=7233}
2023-03-28 19:50:06.247920+0200 WakaTime-Test[9094:3182726] Added observer <AXObserver 0x600003909bd0> {pid=7233} to run loop
2023-03-28 19:50:06.247985+0200 WakaTime-Test[9094:3182726] Watching for file changes on Xcode

Runtime error when api key not set on startup

When no api key is set in ~/.wakatime.cfg, this runtime error occurs. Setting an api key should prevent it, but this is a release blocker bug for v1.0 because most new users won't have an api key set already:

Accessing Environment<OpenWindowAction>'s value outside of being installed on a View. This will always read the default value and will not update.

The execution path that results in the above runtime error is activate -> checkForApiKey -> promptForApiKey. When calling promptForApiKey from a SwiftUI button click, it works fine.

Screenshot 2023-03-16 at 3 34 28 PM

Screenshot 2023-03-16 at 3 34 38 PM

App crash when switching project in Xcode

I'm glad to see wakatime for xcode back.

But I have an issue, the application seems to crash whenever I switch to another xcode window with a different project open in it. I didn't have this issue when compiling/running the application from xcode. But I had this issue when I moved the executable to my Application folder, and now I have the same issue with the release downloaded.

Is there anyone else that have the same issue?

App crashing silently

-------------------------------------
Translated Report (Full Report Below)
-------------------------------------

Process:               WakaTime [16164]
Path:                  /Applications/WakaTime.app/Contents/MacOS/WakaTime
Identifier:            macos-wakatime.WakaTime
Version:               0.0.1 (2)
Code Type:             X86-64 (Native)
Parent Process:        launchd [1]
User ID:               501

Date/Time:             2023-03-28 10:40:36.3015 +0800
OS Version:            macOS 13.2.1 (22D68)
Report Version:        12
Bridge OS Version:     7.2 (20P3045)
Anonymous UUID:        361D84A9-9B45-DF94-7FFB-9AF1BDADA3E6

Sleep/Wake UUID:       CB683E33-25F3-4AFA-BC98-10E9E876EBD1

Time Awake Since Boot: 410000 seconds
Time Since Wake:       2354 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_INSTRUCTION (SIGILL)
Exception Codes:       0x0000000000000001, 0x0000000000000000

Termination Reason:    Namespace SIGNAL, Code 4 Illegal instruction: 4
Terminating Process:   exc handler [16164]

Thread 0 Crashed::  Dispatch queue: com.apple.main-thread
0   libswiftDispatch.dylib        	    0x7ff817c32e8c static OS_dispatch_source.makeProcessSource(identifier:eventMask:queue:) + 28
1   WakaTime                      	       0x10d2b096d FileMonitor.init(filePath:queue:) + 1549
2   WakaTime                      	       0x10d2aeac5 FileMonitor.__allocating_init(filePath:queue:) + 69
3   WakaTime                      	       0x10d2ae918 Watcher.documentPath.didset + 936
4   WakaTime                      	       0x10d2aed2f Watcher.documentPath.setter + 271
5   WakaTime                      	       0x10d2ac94f observerCallback(_:_:_:_:) + 991
6   WakaTime                      	       0x10d2ac547 @objc observerCallback(_:_:_:_:) + 71
7   HIServices                    	    0x7ff8098aff73 _XXMIGPostNotification + 884
8   HIServices                    	    0x7ff8098d77d4 _XPostNotification + 362
9   HIServices                    	    0x7ff8098935a9 mshMIGPerform + 182
10  CoreFoundation                	    0x7ff80406a0b1 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 41
11  CoreFoundation                	    0x7ff804069fee __CFRunLoopDoSource1 + 540
12  CoreFoundation                	    0x7ff804068c6b __CFRunLoopRun + 2705
13  CoreFoundation                	    0x7ff804067b60 CFRunLoopRunSpecific + 560
14  HIToolbox                     	    0x7ff80d9b5766 RunCurrentEventLoopInMode + 292
15  HIToolbox                     	    0x7ff80d9b5576 ReceiveNextEventCommon + 679
16  HIToolbox                     	    0x7ff80d9b52b3 _BlockUntilNextEventMatchingListInModeWithFilter + 70
17  AppKit                        	    0x7ff8071b82f3 _DPSNextEvent + 909
18  AppKit                        	    0x7ff8071b7174 -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 1219
19  AppKit                        	    0x7ff8071a97b7 -[NSApplication run] + 586
20  AppKit                        	    0x7ff80717d7f7 NSApplicationMain + 817
21  SwiftUI                       	    0x7ff90bb25835 0x7ff90ba92000 + 604213
22  SwiftUI                       	    0x7ff90cb714f4 0x7ff90ba92000 + 17691892
23  SwiftUI                       	    0x7ff90c43128f 0x7ff90ba92000 + 10089103
24  WakaTime                      	       0x10d2a5083 static WakaTime.$main() + 35
25  WakaTime                      	       0x10d2a5769 main + 9
26  dyld                          	    0x7ff803c5b310 start + 2432

Thread 1:: com.apple.NSEventThread
0   libsystem_kernel.dylib        	    0x7ff803f4f5c2 mach_msg2_trap + 10
1   libsystem_kernel.dylib        	    0x7ff803f5d604 mach_msg2_internal + 82
2   libsystem_kernel.dylib        	    0x7ff803f56635 mach_msg_overwrite + 723
3   libsystem_kernel.dylib        	    0x7ff803f4f8a8 mach_msg + 19
4   CoreFoundation                	    0x7ff804069cbe __CFRunLoopServiceMachPort + 145
5   CoreFoundation                	    0x7ff80406872a __CFRunLoopRun + 1360
6   CoreFoundation                	    0x7ff804067b60 CFRunLoopRunSpecific + 560
7   AppKit                        	    0x7ff807319179 _NSEventThread + 132
8   libsystem_pthread.dylib       	    0x7ff803f8e259 _pthread_start + 125
9   libsystem_pthread.dylib       	    0x7ff803f89c7b thread_start + 15

Thread 2:: com.apple.NSURLConnectionLoader
0   libsystem_kernel.dylib        	    0x7ff803f4f5c2 mach_msg2_trap + 10
1   libsystem_kernel.dylib        	    0x7ff803f5d604 mach_msg2_internal + 82
2   libsystem_kernel.dylib        	    0x7ff803f56635 mach_msg_overwrite + 723
3   libsystem_kernel.dylib        	    0x7ff803f4f8a8 mach_msg + 19
4   CoreFoundation                	    0x7ff804069cbe __CFRunLoopServiceMachPort + 145
5   CoreFoundation                	    0x7ff80406872a __CFRunLoopRun + 1360
6   CoreFoundation                	    0x7ff804067b60 CFRunLoopRunSpecific + 560
7   CFNetwork                     	    0x7ff808a8619c 0x7ff808842000 + 2376092
8   Foundation                    	    0x7ff804ebd3bc __NSThread__start__ + 1009
9   libsystem_pthread.dylib       	    0x7ff803f8e259 _pthread_start + 125
10  libsystem_pthread.dylib       	    0x7ff803f89c7b thread_start + 15

Thread 3:
0   libsystem_pthread.dylib       	    0x7ff803f89c58 start_wqthread + 0

Thread 4::  Dispatch queue: com.WakaTime.Watcher.callbackQueue
0   libsystem_kernel.dylib        	    0x7ff803f4fd46 access + 10
1   Foundation                    	    0x7ff804e9c57e _NSFileAccessibleForMode + 71
2   Foundation                    	    0x7ff804f392be -[NSConcreteTask launchWithDictionary:error:] + 486
3   WakaTime                      	       0x10d29d263 WakaTime.handleEvent(file:isWrite:) + 2707
4   WakaTime                      	       0x10d29c7be implicit closure #2 in implicit closure #1 in WakaTime.init() + 62
5   WakaTime                      	       0x10d2af37d closure #1 in Watcher.handleEvent(path:isWrite:) + 685
6   WakaTime                      	       0x10d2af3c8 thunk for @escaping @callee_guaranteed () -> () + 40
7   libdispatch.dylib             	    0x7ff803e0d7fb _dispatch_call_block_and_release + 12
8   libdispatch.dylib             	    0x7ff803e0ea44 _dispatch_client_callout + 8
9   libdispatch.dylib             	    0x7ff803e14ac4 _dispatch_lane_serial_drain + 694
10  libdispatch.dylib             	    0x7ff803e155b4 _dispatch_lane_invoke + 366
11  libdispatch.dylib             	    0x7ff803e1fad7 _dispatch_workloop_worker_thread + 762
12  libsystem_pthread.dylib       	    0x7ff803f8ace3 _pthread_wqthread + 326
13  libsystem_pthread.dylib       	    0x7ff803f89c67 start_wqthread + 15

Thread 5:
0   libsystem_pthread.dylib       	    0x7ff803f89c58 start_wqthread + 0


Thread 0 crashed with X86 Thread State (64-bit):
  rax: 0x00006000030ac880  rbx: 0x00006000010b4750  rcx: 0x00007ff843be3020  rdx: 0x00006000030ac880
  rdi: 0x00000000ffffffff  rsi: 0x00007ff7b2c717a0  rbp: 0x00007ff7b2c71760  rsp: 0x00007ff7b2c71760
   r8: 0x0000600003097d00   r9: 0x00007ff812710204  r10: 0x00007ff8478ce578  r11: 0x00007ff803e0e206
  r12: 0x000000010f323000  r13: 0x00007fea330b97d8  r14: 0x00006000030ac900  r15: 0x0000000000014000
  rip: 0x00007ff817c32e8c  rfl: 0x0000000000010286  cr2: 0x00007fea3501eb80
  
Logical CPU:     6
Error Code:      0x00000000 
Trap Number:     6

Thread 0 instruction stream:
  00 00 00 00 55 48 89 e5-48 89 f9 48 8b 3d 9a a3  ....UH..H..H.=..
  93 2f 31 f6 31 d2 5d e9-d1 05 00 00 0f 1f 84 00  ./1.1.].........
  00 00 00 00 55 48 89 e5-48 8b 0d bd a3 93 2f 5d  ....UH..H...../]
  e9 0f 00 00 00 66 2e 0f-1f 84 00 00 00 00 00 0f  .....f..........
  1f 44 00 00 55 48 89 e5-85 ff 78 14 48 89 d0 48  .D..UH....x.H..H
  8b 16 89 fe 48 89 cf 48-89 c1 5d e9 8d 05 00 00  ....H..H..].....
 [0f]0b 66 90 55 48 89 e5-48 8b 15 85 a3 93 2f 5d  ..f.UH..H...../]	<==
  e9 0f 00 00 00 66 2e 0f-1f 84 00 00 00 00 00 0f  .....f..........
  1f 44 00 00 85 ff 78 0f-48 89 f1 89 fe 48 89 d7  .D....x.H....H..
  31 d2 e9 56 05 00 00 55-48 89 e5 0f 0b 0f 1f 80  1..V...UH.......
  00 00 00 00 55 48 89 e5-48 8b 3d 4d d1 fb 2e e8  ....UH..H.=M....
  b4 86 00 00 4c 89 ef 48-89 c6 31 d2 31 c9 45 31  ....L..H..1.1.E1

Binary Images:
    0x7ff817c2b000 -     0x7ff817c3ffff libswiftDispatch.dylib (*) <e6650041-9d55-3025-838e-1b758e1bac91> /usr/lib/swift/libswiftDispatch.dylib
       0x10d28b000 -        0x10d2b6fff macos-wakatime.WakaTime (0.0.1) <e977340e-d3f6-3d9e-b360-d9c29dee1f83> /Applications/WakaTime.app/Contents/MacOS/WakaTime
    0x7ff809889000 -     0x7ff8098e4ff0 com.apple.HIServices (1.22) <49f2a033-08ac-3343-b13e-61e2de64da8b> /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/HIServices.framework/Versions/A/HIServices
    0x7ff803fea000 -     0x7ff804483fef com.apple.CoreFoundation (6.9) <c2615780-0140-315c-a455-7e03bb22d3d6> /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
    0x7ff80d986000 -     0x7ff80dc7dffd com.apple.HIToolbox (2.1.1) <7bf47984-29cb-319e-a6da-0884d158f96a> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/HIToolbox.framework/Versions/A/HIToolbox
    0x7ff80717a000 -     0x7ff808182ff2 com.apple.AppKit (6.9) <540cedfd-5a35-3f35-8953-dcb7c4834eb5> /System/Library/Frameworks/AppKit.framework/Versions/C/AppKit
    0x7ff90ba92000 -     0x7ff90d0f1ff5 com.apple.SwiftUI (4.3.3.1.400) <0655992a-4677-3013-b872-b1dc09a2721b> /System/Library/Frameworks/SwiftUI.framework/Versions/A/SwiftUI
    0x7ff803c55000 -     0x7ff803ce9caf dyld (*) <bba77709-6cad-3592-ab03-09d0f7b8610e> /usr/lib/dyld
    0x7ff803f4e000 -     0x7ff803f87ff7 libsystem_kernel.dylib (*) <87ff381c-4d30-3087-bab7-a5a53d232c00> /usr/lib/system/libsystem_kernel.dylib
    0x7ff803f88000 -     0x7ff803f93ff7 libsystem_pthread.dylib (*) <3bd433d4-15bd-3add-a612-95e4d3b20719> /usr/lib/system/libsystem_pthread.dylib
    0x7ff808842000 -     0x7ff808be7ff7 com.apple.CFNetwork (1404.0.5) <4b897c45-5c75-37b9-a394-66ffb18ffc35> /System/Library/Frameworks/CFNetwork.framework/Versions/A/CFNetwork
    0x7ff804e65000 -     0x7ff805876ff6 com.apple.Foundation (6.9) <a58576df-7109-3a13-a338-617f135ce8a8> /System/Library/Frameworks/Foundation.framework/Versions/C/Foundation
    0x7ff803e0c000 -     0x7ff803e52ff3 libdispatch.dylib (*) <d59ee79a-169a-3799-8ea1-c8ad56bb11c9> /usr/lib/system/libdispatch.dylib

External Modification Summary:
  Calls made by other processes targeting this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
  Calls made by this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
  Calls made by all processes on this machine:
    task_for_pid: 429
    thread_create: 0
    thread_set_state: 33924

VM Region Summary:
ReadOnly portion of Libraries: Total=634.5M resident=0K(0%) swapped_out_or_unallocated=634.5M(100%)
Writable regions: Total=628.1M written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=628.1M(100%)

                                VIRTUAL   REGION 
REGION TYPE                        SIZE    COUNT (non-coalesced) 
===========                     =======  ======= 
Accelerate framework               256K        2 
Activity Tracing                   256K        1 
CG image                           276K       14 
ColorSync                          252K       29 
CoreAnimation                      644K       17 
CoreGraphics                        16K        3 
CoreUI image data                 2056K       15 
Foundation                          44K        2 
Kernel Alloc Once                    8K        1 
MALLOC                           229.2M       75 
MALLOC guard page                   48K       11 
MALLOC_NANO (reserved)           384.0M        1         reserved VM address space (unallocated)
SQLite page cache                  256K        2 
STACK GUARD                       56.0M        6 
Stack                             10.5M        6 
VM_ALLOCATE                       1540K       12 
__CTF                               756        1 
__DATA                            24.8M      468 
__DATA_CONST                      26.3M      291 
__DATA_DIRTY                      1226K      158 
__FONT_DATA                        2352        1 
__LINKEDIT                       182.3M        6 
__OBJC_RO                         65.5M        1 
__OBJC_RW                         1989K        2 
__TEXT                           452.2M      492 
dyld private memory                256K        1 
libnetwork                        1664K       24 
mapped file                      215.0M       55 
shared memory                      780K       16 
===========                     =======  ======= 
TOTAL                              1.6G     1713 
TOTAL, minus reserved VM space     1.2G     1713 



-----------
Full Report
-----------

{"app_name":"WakaTime","timestamp":"2023-03-28 10:40:42.00 +0800","app_version":"0.0.1","slice_uuid":"e977340e-d3f6-3d9e-b360-d9c29dee1f83","build_version":"2","platform":1,"bundleID":"macos-wakatime.WakaTime","share_with_app_devs":1,"is_first_party":0,"bug_type":"309","os_version":"macOS 13.2.1 (22D68)","roots_installed":0,"name":"WakaTime","incident_id":"464018F9-17F5-4697-9F6C-2D006D9144A4"}
{
  "uptime" : 410000,
  "procRole" : "Default",
  "version" : 2,
  "userID" : 501,
  "deployVersion" : 210,
  "modelCode" : "MacBookPro16,2",
  "coalitionID" : 49394,
  "osVersion" : {
    "train" : "macOS 13.2.1",
    "build" : "22D68",
    "releaseType" : "User"
  },
  "captureTime" : "2023-03-28 10:40:36.3015 +0800",
  "incident" : "464018F9-17F5-4697-9F6C-2D006D9144A4",
  "pid" : 16164,
  "cpuType" : "X86-64",
  "roots_installed" : 0,
  "bug_type" : "309",
  "procLaunch" : "2023-03-28 10:38:04.9298 +0800",
  "procStartAbsTime" : 417360286171369,
  "procExitAbsTime" : 417511643863850,
  "procName" : "WakaTime",
  "procPath" : "\/Applications\/WakaTime.app\/Contents\/MacOS\/WakaTime",
  "bundleInfo" : {"CFBundleShortVersionString":"0.0.1","CFBundleVersion":"2","CFBundleIdentifier":"macos-wakatime.WakaTime"},
  "storeInfo" : {"deviceIdentifierForVendor":"882B65DA-3743-5CD7-9004-855E3CE81613","thirdParty":true},
  "parentProc" : "launchd",
  "parentPid" : 1,
  "coalitionName" : "macos-wakatime.WakaTime",
  "crashReporterKey" : "361D84A9-9B45-DF94-7FFB-9AF1BDADA3E6",
  "throttleTimeout" : 2147483647,
  "wakeTime" : 2354,
  "bridgeVersion" : {"build":"20P3045","train":"7.2"},
  "sleepWakeUUID" : "CB683E33-25F3-4AFA-BC98-10E9E876EBD1",
  "sip" : "enabled",
  "exception" : {"codes":"0x0000000000000001, 0x0000000000000000","rawCodes":[1,0],"type":"EXC_BAD_INSTRUCTION","signal":"SIGILL"},
  "termination" : {"flags":0,"code":4,"namespace":"SIGNAL","indicator":"Illegal instruction: 4","byProc":"exc handler","byPid":16164},
  "extMods" : {"caller":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"system":{"thread_create":0,"thread_set_state":33924,"task_for_pid":429},"targeted":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"warnings":0},
  "faultingThread" : 0,
  "threads" : [{"triggered":true,"id":9492891,"instructionState":{"instructionStream":{"bytes":[0,0,0,0,85,72,137,229,72,137,249,72,139,61,154,163,147,47,49,246,49,210,93,233,209,5,0,0,15,31,132,0,0,0,0,0,85,72,137,229,72,139,13,189,163,147,47,93,233,15,0,0,0,102,46,15,31,132,0,0,0,0,0,15,31,68,0,0,85,72,137,229,133,255,120,20,72,137,208,72,139,22,137,254,72,137,207,72,137,193,93,233,141,5,0,0,15,11,102,144,85,72,137,229,72,139,21,133,163,147,47,93,233,15,0,0,0,102,46,15,31,132,0,0,0,0,0,15,31,68,0,0,133,255,120,15,72,137,241,137,254,72,137,215,49,210,233,86,5,0,0,85,72,137,229,15,11,15,31,128,0,0,0,0,85,72,137,229,72,139,61,77,209,251,46,232,180,134,0,0,76,137,239,72,137,198,49,210,49,201,69,49],"offset":96}},"threadState":{"r13":{"value":140643855472600},"rax":{"value":105553167304832},"rflags":{"value":66182},"cpu":{"value":6},"r14":{"value":105553167304960},"rsi":{"value":140701833041824},"r8":{"value":105553167219968},"cr2":{"value":140643888393088},"rdx":{"value":105553167304832},"r10":{"value":140704329033080,"symbolLocation":0,"symbol":"OBJC_CLASS_$_OS_dispatch_queue_serial"},"r9":{"value":140703438012932,"symbolLocation":388,"symbol":"std::__1::pair<swift::HashMapElementWrapper<(anonymous namespace)::ObjCClassCacheEntry>*, unsigned int> swift::ConcurrentReadableHashMap<swift::HashMapElementWrapper<(anonymous namespace)::ObjCClassCacheEntry>, swift::StaticMutex>::find<swift::TargetClassMetadata<swift::InProcess, swift::TargetAnyClassMetadataObjCInterop<swift::InProcess> > const*>(swift::TargetClassMetadata<swift::InProcess, swift::TargetAnyClassMetadataObjCInterop<swift::InProcess> > const* const&, swift::ConcurrentReadableHashMap<swift::HashMapElementWrapper<(anonymous namespace)::ObjCClassCacheEntry>, swift::StaticMutex>::IndexStorage, unsigned long, swift::HashMapElementWrapper<(anonymous namespace)::ObjCClassCacheEntry>*)"},"r15":{"value":81920},"rbx":{"value":105553133782864},"trap":{"value":6},"err":{"value":0},"r11":{"value":140703193686534,"symbolLocation":0,"symbol":"-[OS_object retain]"},"rip":{"value":140703527284364,"matchesCrashFrame":1},"rbp":{"value":140701833041760},"rsp":{"value":140701833041760},"r12":{"value":4549914624},"rcx":{"value":140704265154592,"symbolLocation":0,"symbol":"_dispatch_source_type_vnode"},"flavor":"x86_THREAD_STATE","rdi":{"value":4294967295}},"queue":"com.apple.main-thread","frames":[{"imageOffset":32396,"symbol":"static OS_dispatch_source.makeProcessSource(identifier:eventMask:queue:)","symbolLocation":28,"imageIndex":0},{"imageOffset":153965,"symbol":"FileMonitor.init(filePath:queue:)","symbolLocation":1549,"imageIndex":1},{"imageOffset":146117,"symbol":"FileMonitor.__allocating_init(filePath:queue:)","symbolLocation":69,"imageIndex":1},{"imageOffset":145688,"symbol":"Watcher.documentPath.didset","symbolLocation":936,"imageIndex":1},{"imageOffset":146735,"symbol":"Watcher.documentPath.setter","symbolLocation":271,"imageIndex":1},{"imageOffset":137551,"symbol":"observerCallback(_:_:_:_:)","symbolLocation":991,"imageIndex":1},{"imageOffset":136519,"symbol":"@objc observerCallback(_:_:_:_:)","symbolLocation":71,"imageIndex":1},{"imageOffset":159603,"symbol":"_XXMIGPostNotification","symbolLocation":884,"imageIndex":2},{"imageOffset":321492,"symbol":"_XPostNotification","symbolLocation":362,"imageIndex":2},{"imageOffset":42409,"symbol":"mshMIGPerform","symbolLocation":182,"imageIndex":2},{"imageOffset":524465,"symbol":"__CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__","symbolLocation":41,"imageIndex":3},{"imageOffset":524270,"symbol":"__CFRunLoopDoSource1","symbolLocation":540,"imageIndex":3},{"imageOffset":519275,"symbol":"__CFRunLoopRun","symbolLocation":2705,"imageIndex":3},{"imageOffset":514912,"symbol":"CFRunLoopRunSpecific","symbolLocation":560,"imageIndex":3},{"imageOffset":194406,"symbol":"RunCurrentEventLoopInMode","symbolLocation":292,"imageIndex":4},{"imageOffset":193910,"symbol":"ReceiveNextEventCommon","symbolLocation":679,"imageIndex":4},{"imageOffset":193203,"symbol":"_BlockUntilNextEventMatchingListInModeWithFilter","symbolLocation":70,"imageIndex":4},{"imageOffset":254707,"symbol":"_DPSNextEvent","symbolLocation":909,"imageIndex":5},{"imageOffset":250228,"symbol":"-[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:]","symbolLocation":1219,"imageIndex":5},{"imageOffset":194487,"symbol":"-[NSApplication run]","symbolLocation":586,"imageIndex":5},{"imageOffset":14327,"symbol":"NSApplicationMain","symbolLocation":817,"imageIndex":5},{"imageOffset":604213,"imageIndex":6},{"imageOffset":17691892,"imageIndex":6},{"imageOffset":10089103,"imageIndex":6},{"imageOffset":106627,"symbol":"static WakaTime.$main()","symbolLocation":35,"imageIndex":1},{"imageOffset":108393,"symbol":"main","symbolLocation":9,"imageIndex":1},{"imageOffset":25360,"symbol":"start","symbolLocation":2432,"imageIndex":7}]},{"id":9492923,"name":"com.apple.NSEventThread","frames":[{"imageOffset":5570,"symbol":"mach_msg2_trap","symbolLocation":10,"imageIndex":8},{"imageOffset":62980,"symbol":"mach_msg2_internal","symbolLocation":82,"imageIndex":8},{"imageOffset":34357,"symbol":"mach_msg_overwrite","symbolLocation":723,"imageIndex":8},{"imageOffset":6312,"symbol":"mach_msg","symbolLocation":19,"imageIndex":8},{"imageOffset":523454,"symbol":"__CFRunLoopServiceMachPort","symbolLocation":145,"imageIndex":3},{"imageOffset":517930,"symbol":"__CFRunLoopRun","symbolLocation":1360,"imageIndex":3},{"imageOffset":514912,"symbol":"CFRunLoopRunSpecific","symbolLocation":560,"imageIndex":3},{"imageOffset":1700217,"symbol":"_NSEventThread","symbolLocation":132,"imageIndex":5},{"imageOffset":25177,"symbol":"_pthread_start","symbolLocation":125,"imageIndex":9},{"imageOffset":7291,"symbol":"thread_start","symbolLocation":15,"imageIndex":9}]},{"id":9492962,"name":"com.apple.NSURLConnectionLoader","frames":[{"imageOffset":5570,"symbol":"mach_msg2_trap","symbolLocation":10,"imageIndex":8},{"imageOffset":62980,"symbol":"mach_msg2_internal","symbolLocation":82,"imageIndex":8},{"imageOffset":34357,"symbol":"mach_msg_overwrite","symbolLocation":723,"imageIndex":8},{"imageOffset":6312,"symbol":"mach_msg","symbolLocation":19,"imageIndex":8},{"imageOffset":523454,"symbol":"__CFRunLoopServiceMachPort","symbolLocation":145,"imageIndex":3},{"imageOffset":517930,"symbol":"__CFRunLoopRun","symbolLocation":1360,"imageIndex":3},{"imageOffset":514912,"symbol":"CFRunLoopRunSpecific","symbolLocation":560,"imageIndex":3},{"imageOffset":2376092,"imageIndex":10},{"imageOffset":361404,"symbol":"__NSThread__start__","symbolLocation":1009,"imageIndex":11},{"imageOffset":25177,"symbol":"_pthread_start","symbolLocation":125,"imageIndex":9},{"imageOffset":7291,"symbol":"thread_start","symbolLocation":15,"imageIndex":9}]},{"id":9495566,"frames":[{"imageOffset":7256,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]},{"id":9497879,"queue":"com.WakaTime.Watcher.callbackQueue","frames":[{"imageOffset":7494,"symbol":"access","symbolLocation":10,"imageIndex":8},{"imageOffset":226686,"symbol":"_NSFileAccessibleForMode","symbolLocation":71,"imageIndex":11},{"imageOffset":869054,"symbol":"-[NSConcreteTask launchWithDictionary:error:]","symbolLocation":486,"imageIndex":11},{"imageOffset":74339,"symbol":"WakaTime.handleEvent(file:isWrite:)","symbolLocation":2707,"imageIndex":1},{"imageOffset":71614,"symbol":"implicit closure #2 in implicit closure #1 in WakaTime.init()","symbolLocation":62,"imageIndex":1},{"imageOffset":148349,"symbol":"closure #1 in Watcher.handleEvent(path:isWrite:)","symbolLocation":685,"imageIndex":1},{"imageOffset":148424,"symbol":"thunk for @escaping @callee_guaranteed () -> ()","symbolLocation":40,"imageIndex":1},{"imageOffset":6139,"symbol":"_dispatch_call_block_and_release","symbolLocation":12,"imageIndex":12},{"imageOffset":10820,"symbol":"_dispatch_client_callout","symbolLocation":8,"imageIndex":12},{"imageOffset":35524,"symbol":"_dispatch_lane_serial_drain","symbolLocation":694,"imageIndex":12},{"imageOffset":38324,"symbol":"_dispatch_lane_invoke","symbolLocation":366,"imageIndex":12},{"imageOffset":80599,"symbol":"_dispatch_workloop_worker_thread","symbolLocation":762,"imageIndex":12},{"imageOffset":11491,"symbol":"_pthread_wqthread","symbolLocation":326,"imageIndex":9},{"imageOffset":7271,"symbol":"start_wqthread","symbolLocation":15,"imageIndex":9}]},{"id":9497881,"frames":[{"imageOffset":7256,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]}],
  "usedImages" : [
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703527251968,
    "size" : 86016,
    "uuid" : "e6650041-9d55-3025-838e-1b758e1bac91",
    "path" : "\/usr\/lib\/swift\/libswiftDispatch.dylib",
    "name" : "libswiftDispatch.dylib"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 4515737600,
    "CFBundleShortVersionString" : "0.0.1",
    "CFBundleIdentifier" : "macos-wakatime.WakaTime",
    "size" : 180224,
    "uuid" : "e977340e-d3f6-3d9e-b360-d9c29dee1f83",
    "path" : "\/Applications\/WakaTime.app\/Contents\/MacOS\/WakaTime",
    "name" : "WakaTime",
    "CFBundleVersion" : "2"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703288561664,
    "CFBundleShortVersionString" : "1.22",
    "CFBundleIdentifier" : "com.apple.HIServices",
    "size" : 376817,
    "uuid" : "49f2a033-08ac-3343-b13e-61e2de64da8b",
    "path" : "\/System\/Library\/Frameworks\/ApplicationServices.framework\/Versions\/A\/Frameworks\/HIServices.framework\/Versions\/A\/HIServices",
    "name" : "HIServices"
  },
  {
    "source" : "P",
    "arch" : "x86_64h",
    "base" : 140703195635712,
    "CFBundleShortVersionString" : "6.9",
    "CFBundleIdentifier" : "com.apple.CoreFoundation",
    "size" : 4825072,
    "uuid" : "c2615780-0140-315c-a455-7e03bb22d3d6",
    "path" : "\/System\/Library\/Frameworks\/CoreFoundation.framework\/Versions\/A\/CoreFoundation",
    "name" : "CoreFoundation",
    "CFBundleVersion" : "1953.300"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703356706816,
    "CFBundleShortVersionString" : "2.1.1",
    "CFBundleIdentifier" : "com.apple.HIToolbox",
    "size" : 3112958,
    "uuid" : "7bf47984-29cb-319e-a6da-0884d158f96a",
    "path" : "\/System\/Library\/Frameworks\/Carbon.framework\/Versions\/A\/Frameworks\/HIToolbox.framework\/Versions\/A\/HIToolbox",
    "name" : "HIToolbox"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703247605760,
    "CFBundleShortVersionString" : "6.9",
    "CFBundleIdentifier" : "com.apple.AppKit",
    "size" : 16814067,
    "uuid" : "540cedfd-5a35-3f35-8953-dcb7c4834eb5",
    "path" : "\/System\/Library\/Frameworks\/AppKit.framework\/Versions\/C\/AppKit",
    "name" : "AppKit",
    "CFBundleVersion" : "2299.40.118"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140707619217408,
    "CFBundleShortVersionString" : "4.3.3.1.400",
    "CFBundleIdentifier" : "com.apple.SwiftUI",
    "size" : 23461878,
    "uuid" : "0655992a-4677-3013-b872-b1dc09a2721b",
    "path" : "\/System\/Library\/Frameworks\/SwiftUI.framework\/Versions\/A\/SwiftUI",
    "name" : "SwiftUI",
    "CFBundleVersion" : "4.3.3.1.400"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703191879680,
    "size" : 609456,
    "uuid" : "bba77709-6cad-3592-ab03-09d0f7b8610e",
    "path" : "\/usr\/lib\/dyld",
    "name" : "dyld"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703194996736,
    "size" : 237560,
    "uuid" : "87ff381c-4d30-3087-bab7-a5a53d232c00",
    "path" : "\/usr\/lib\/system\/libsystem_kernel.dylib",
    "name" : "libsystem_kernel.dylib"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703195234304,
    "size" : 49144,
    "uuid" : "3bd433d4-15bd-3add-a612-95e4d3b20719",
    "path" : "\/usr\/lib\/system\/libsystem_pthread.dylib",
    "name" : "libsystem_pthread.dylib"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703271493632,
    "CFBundleShortVersionString" : "1404.0.5",
    "CFBundleIdentifier" : "com.apple.CFNetwork",
    "size" : 3825656,
    "uuid" : "4b897c45-5c75-37b9-a394-66ffb18ffc35",
    "path" : "\/System\/Library\/Frameworks\/CFNetwork.framework\/Versions\/A\/CFNetwork",
    "name" : "CFNetwork",
    "CFBundleVersion" : "1404.0.5"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703210819584,
    "CFBundleShortVersionString" : "6.9",
    "CFBundleIdentifier" : "com.apple.Foundation",
    "size" : 10559479,
    "uuid" : "a58576df-7109-3a13-a338-617f135ce8a8",
    "path" : "\/System\/Library\/Frameworks\/Foundation.framework\/Versions\/C\/Foundation",
    "name" : "Foundation",
    "CFBundleVersion" : "1953.300"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703193677824,
    "size" : 290804,
    "uuid" : "d59ee79a-169a-3799-8ea1-c8ad56bb11c9",
    "path" : "\/usr\/lib\/system\/libdispatch.dylib",
    "name" : "libdispatch.dylib"
  }
],
  "sharedCache" : {
  "base" : 140703191273472,
  "size" : 21474836480,
  "uuid" : "57815a20-af2c-3b56-9006-23abde7962b0"
},
  "vmSummary" : "ReadOnly portion of Libraries: Total=634.5M resident=0K(0%) swapped_out_or_unallocated=634.5M(100%)\nWritable regions: Total=628.1M written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=628.1M(100%)\n\n                                VIRTUAL   REGION \nREGION TYPE                        SIZE    COUNT (non-coalesced) \n===========                     =======  ======= \nAccelerate framework               256K        2 \nActivity Tracing                   256K        1 \nCG image                           276K       14 \nColorSync                          252K       29 \nCoreAnimation                      644K       17 \nCoreGraphics                        16K        3 \nCoreUI image data                 2056K       15 \nFoundation                          44K        2 \nKernel Alloc Once                    8K        1 \nMALLOC                           229.2M       75 \nMALLOC guard page                   48K       11 \nMALLOC_NANO (reserved)           384.0M        1         reserved VM address space (unallocated)\nSQLite page cache                  256K        2 \nSTACK GUARD                       56.0M        6 \nStack                             10.5M        6 \nVM_ALLOCATE                       1540K       12 \n__CTF                               756        1 \n__DATA                            24.8M      468 \n__DATA_CONST                      26.3M      291 \n__DATA_DIRTY                      1226K      158 \n__FONT_DATA                        2352        1 \n__LINKEDIT                       182.3M        6 \n__OBJC_RO                         65.5M        1 \n__OBJC_RW                         1989K        2 \n__TEXT                           452.2M      492 \ndyld private memory                256K        1 \nlibnetwork                        1664K       24 \nmapped file                      215.0M       55 \nshared memory                      780K       16 \n===========                     =======  ======= \nTOTAL                              1.6G     1713 \nTOTAL, minus reserved VM space     1.2G     1713 \n",
  "legacyInfo" : {
  "threadTriggered" : {
    "queue" : "com.apple.main-thread"
  }
},
  "trialInfo" : {
  "rollouts" : [
    {
      "rolloutId" : "6112d17137f5d11121dcd4e2",
      "factorPackIds" : {

      },
      "deploymentId" : 240000250
    },
    {
      "rolloutId" : "6347054113acce15305b7b82",
      "factorPackIds" : {
        "SIRI_MEMORY_SYNC_CONFIG" : "634705e78e8be655c1316a6e"
      },
      "deploymentId" : 240000005
    }
  ],
  "experiments" : [

  ]
}
}

wakatime crashing logs latest 3 times.zip

[Suggestion] Notify user when a new app is added, and prompt them to enable it

In the current implementation of this app, the app does not notify the user of newly supported apps (in my experience) and auto-enables the app. I recently saw all of my browser activity reported to WakaTime, which I didn't want. In my opinion, this probably shouldn't be auto-enabled -- not everyone wants to track all of their browsing activity here.

Postman is not tracked?

i remember that Postman is tracked in version 3.3.0 but you get Others results instead. now when I update into 3.5.3 postman is not tracked while figma and xcode are fine.

Crashing on v2.0.1

Log from the Console.app:
If I get it correct, this method causes the crash.

I'm concerned about this force cast:

let activeWindow = element.getValue(for: kAXFocusedWindowAttribute) as! AXUIElement
-------------------------------------
Translated Report (Full Report Below)
-------------------------------------

Process:               WakaTime [88068]
Path:                  /Applications/WakaTime.app/Contents/MacOS/WakaTime
Identifier:            macos-wakatime.WakaTime
Version:               2.0.1 (2.0.1)
Code Type:             ARM-64 (Native)
Parent Process:        launchd [1]
User ID:               501

Date/Time:             2023-06-19 08:58:26.4714 +0300
OS Version:            macOS 13.4 (22F66)
Report Version:        12
Anonymous UUID:        FAB9A1F3-F1A3-6F8A-B2F4-7442A5B90BC1

Sleep/Wake UUID:       8D6C0010-7ED4-42A0-8FA5-EDCA6C804D64

Time Awake Since Boot: 270000 seconds
Time Since Wake:       38 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BREAKPOINT (SIGTRAP)
Exception Codes:       0x0000000000000001, 0x0000000100d8d5c0

Termination Reason:    Namespace SIGNAL, Code 5 Trace/BPT trap: 5
Terminating Process:   exc handler [88068]

Thread 0 Crashed::  Dispatch queue: com.apple.main-thread
0   WakaTime                      	       0x100d8d5c0 Watcher.watch(app:) + 1460
1   WakaTime                      	       0x100d8cbe8 Watcher.handleAppChanged(_:) + 552
2   WakaTime                      	       0x100d8c828 Watcher.appChanged(_:) + 284
3   WakaTime                      	       0x100d8c8d8 @objc Watcher.appChanged(_:) + 128
4   CoreFoundation                	       0x1a7e9b180 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 148
5   CoreFoundation                	       0x1a7f36eec ___CFXRegistrationPost_block_invoke + 88
6   CoreFoundation                	       0x1a7f36e34 _CFXRegistrationPost + 440
7   CoreFoundation                	       0x1a7e6c4cc _CFXNotificationPost + 704
8   Foundation                    	       0x1a8dca8f4 -[NSNotificationCenter postNotificationName:object:userInfo:] + 88
9   AppKit                        	       0x1ab2665e8 applicationStatusSubsystemCallback + 676
10  LaunchServices                	       0x1a8327e30 ___LSScheduleNotificationFunction_block_invoke_2 + 52
11  CoreFoundation                	       0x1a7ea61d4 __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 28
12  CoreFoundation                	       0x1a7ea60e8 __CFRunLoopDoBlocks + 364
13  CoreFoundation                	       0x1a7ea558c __CFRunLoopRun + 2432
14  CoreFoundation                	       0x1a7ea44b8 CFRunLoopRunSpecific + 612
15  HIToolbox                     	       0x1b16eec40 RunCurrentEventLoopInMode + 292
16  HIToolbox                     	       0x1b16eea7c ReceiveNextEventCommon + 648
17  HIToolbox                     	       0x1b16ee7d4 _BlockUntilNextEventMatchingListInModeWithFilter + 76
18  AppKit                        	       0x1ab0c5d44 _DPSNextEvent + 636
19  AppKit                        	       0x1ab0c4ee0 -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 716
20  AppKit                        	       0x1ab0b9344 -[NSApplication run] + 464
21  WakaTime                      	       0x100d7d6c8 main + 120
22  dyld                          	       0x1a7a6ff28 start + 2236

Thread 1:
0   libsystem_pthread.dylib       	       0x1a7dc2d8c start_wqthread + 0

Thread 2:
0   libsystem_pthread.dylib       	       0x1a7dc2d8c start_wqthread + 0

Thread 3:
0   libsystem_pthread.dylib       	       0x1a7dc2d8c start_wqthread + 0

Thread 4:: com.apple.NSEventThread
0   libsystem_kernel.dylib        	       0x1a7d87f14 mach_msg2_trap + 8
1   libsystem_kernel.dylib        	       0x1a7d9a240 mach_msg2_internal + 80
2   libsystem_kernel.dylib        	       0x1a7d90b78 mach_msg_overwrite + 604
3   libsystem_kernel.dylib        	       0x1a7d88290 mach_msg + 24
4   CoreFoundation                	       0x1a7ea67e4 __CFRunLoopServiceMachPort + 160
5   CoreFoundation                	       0x1a7ea50c4 __CFRunLoopRun + 1208
6   CoreFoundation                	       0x1a7ea44b8 CFRunLoopRunSpecific + 612
7   AppKit                        	       0x1ab1f0334 _NSEventThread + 172
8   libsystem_pthread.dylib       	       0x1a7dc7fa8 _pthread_start + 148
9   libsystem_pthread.dylib       	       0x1a7dc2da0 thread_start + 8

Thread 5:
0   libsystem_pthread.dylib       	       0x1a7dc2d8c start_wqthread + 0

Thread 6:
0   libsystem_pthread.dylib       	       0x1a7dc2d8c start_wqthread + 0

Thread 7:
0   libsystem_pthread.dylib       	       0x1a7dc2d8c start_wqthread + 0

Thread 8:
0   libsystem_pthread.dylib       	       0x1a7dc2d8c start_wqthread + 0

Thread 9:
0   libsystem_pthread.dylib       	       0x1a7dc2d8c start_wqthread + 0


Thread 0 crashed with ARM Thread State (64-bit):
    x0: 0x0000000000000000   x1: 0x0000000000000000   x2: 0x0000000000000000   x3: 0x0000600003b84f40
    x4: 0x000d1f6100000a03   x5: 0x0000070700000001   x6: 0x0000000000001048   x7: 0x00000000000005dc
    x8: 0x0000000000000100   x9: 0x00000000000000ff  x10: 0x0000000000000f00  x11: 0x00000000000007fb
   x12: 0x00000000da006814  x13: 0x00000000000007fd  x14: 0x00000000da20703d  x15: 0x00000000da006814
   x16: 0x00000001b6eb9b7c  x17: 0x000000005a200000  x18: 0x0000000000000000  x19: 0x0000600000096400
   x20: 0x0000000000000000  x21: 0x00000000ffff9d84  x22: 0x0000000203d78010  x23: 0x000000016f0855e0
   x24: 0x0000000203c95c58  x25: 0x000000016f0855c0  x26: 0x0000600000d8ce60  x27: 0x00006000020e6f10
   x28: 0x000000016f0855f0   fp: 0x000000016f0856e0   lr: 0x0000000100d8d5c0
    sp: 0x000000016f0855c0   pc: 0x0000000100d8d5c0 cpsr: 0x80001000
   far: 0x00000001095e0000  esr: 0xf2000001 (Breakpoint) brk 1

Binary Images:
       0x100d78000 -        0x100d97fff macos-wakatime.WakaTime (2.0.1) <491019e8-b56d-3813-8bb1-def204d7d343> /Applications/WakaTime.app/Contents/MacOS/WakaTime
       0x100ef4000 -        0x100f37fff org.sparkle-project.Sparkle (2.4.1) <85cd37f1-a154-35f6-8ee1-b0133b257fe1> /Applications/WakaTime.app/Contents/Frameworks/Sparkle.framework/Versions/B/Sparkle
       0x100ec8000 -        0x100ed3fff libobjc-trampolines.dylib (*) <570c31f7-94c6-3b86-ae44-1694db0a4bcd> /usr/lib/libobjc-trampolines.dylib
       0x1a7e27000 -        0x1a8300fff com.apple.CoreFoundation (6.9) <203e4401-8c2e-3157-a24b-92f52551d43e> /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
       0x1a8dc1000 -        0x1a9786fff com.apple.Foundation (6.9) <d5337cc6-a075-3ca0-b5bf-b49da8878337> /System/Library/Frameworks/Foundation.framework/Versions/C/Foundation
       0x1ab08d000 -        0x1abf9bfff com.apple.AppKit (6.9) <041c7d21-21cc-3eea-ae53-d39f5ca6a24e> /System/Library/Frameworks/AppKit.framework/Versions/C/AppKit
       0x1a8301000 -        0x1a857dfff com.apple.LaunchServices (1141.1) <556590f5-8fed-36a6-830b-ea49bd95b1fe> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/LaunchServices
       0x1b16be000 -        0x1b19f1fff com.apple.HIToolbox (2.1.1) <d800278b-4e6c-3032-b56f-027a938a51d6> /System/Library/Frameworks/Carbon.framework/Versions/A/Frameworks/HIToolbox.framework/Versions/A/HIToolbox
       0x1a7a6a000 -        0x1a7af8553 dyld (*) <bd993f39-c902-37d6-8bd8-6d827c7f121e> /usr/lib/dyld
       0x1a7dc1000 -        0x1a7dcdfff libsystem_pthread.dylib (*) <46d35233-a051-3f4f-bba4-ba56dddc4d1a> /usr/lib/system/libsystem_pthread.dylib
       0x1a7d87000 -        0x1a7dc0fe7 libsystem_kernel.dylib (*) <42f503e2-9273-360a-a086-c1b19bbd3962> /usr/lib/system/libsystem_kernel.dylib

External Modification Summary:
  Calls made by other processes targeting this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
  Calls made by this process:
    task_for_pid: 0
    thread_create: 0
    thread_set_state: 0
  Calls made by all processes on this machine:
    task_for_pid: 67
    thread_create: 4
    thread_set_state: 10156

VM Region Summary:
ReadOnly portion of Libraries: Total=1.2G resident=0K(0%) swapped_out_or_unallocated=1.2G(100%)
Writable regions: Total=1.5G written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=1.5G(100%)

                                VIRTUAL   REGION 
REGION TYPE                        SIZE    COUNT (non-coalesced) 
===========                     =======  ======= 
Accelerate framework               128K        1 
Activity Tracing                   256K        1 
CG image                           112K        6 
ColorSync                          496K       25 
CoreAnimation                      688K       28 
CoreGraphics                        48K        3 
CoreServices                       256K        1 
CoreUI image data                 1648K       13 
Foundation                          16K        1 
Kernel Alloc Once                   32K        1 
MALLOC                           277.5M       58 
MALLOC guard page                  288K       14 
MALLOC_MEDIUM (reserved)         840.0M        7         reserved VM address space (unallocated)
MALLOC_NANO (reserved)           384.0M        1         reserved VM address space (unallocated)
SQLite page cache                  128K        1 
STACK GUARD                       56.2M       10 
Stack                             12.8M       10 
VM_ALLOCATE                        112K        7 
__AUTH                             855K      209 
__AUTH_CONST                      17.6M      392 
__CTF                               824        1 
__DATA                            6761K      381 
__DATA_CONST                      17.8M      396 
__DATA_DIRTY                       987K      136 
__FONT_DATA                        2352        1 
__LINKEDIT                       802.1M        4 
__OBJC_RO                         66.3M        1 
__OBJC_RW                         2011K        1 
__TEXT                           376.9M      415 
dyld private memory                272K        2 
libnetwork                         128K        8 
mapped file                       80.0M       28 
shared memory                      864K       13 
===========                     =======  ======= 
TOTAL                              2.9G     2176 
TOTAL, minus reserved VM space     1.7G     2176 



-----------
Full Report
-----------

{"app_name":"WakaTime","timestamp":"2023-06-19 08:58:28.00 +0300","app_version":"2.0.1","slice_uuid":"491019e8-b56d-3813-8bb1-def204d7d343","build_version":"2.0.1","platform":1,"bundleID":"macos-wakatime.WakaTime","share_with_app_devs":1,"is_first_party":0,"bug_type":"309","os_version":"macOS 13.4 (22F66)","roots_installed":0,"name":"WakaTime","incident_id":"4960D212-6950-4B61-9980-484FA568822D"}
{
  "uptime" : 270000,
  "procRole" : "Default",
  "version" : 2,
  "userID" : 501,
  "deployVersion" : 210,
  "modelCode" : "MacBookPro18,2",
  "coalitionID" : 47905,
  "osVersion" : {
    "train" : "macOS 13.4",
    "build" : "22F66",
    "releaseType" : "User"
  },
  "captureTime" : "2023-06-19 08:58:26.4714 +0300",
  "incident" : "4960D212-6950-4B61-9980-484FA568822D",
  "pid" : 88068,
  "translated" : false,
  "cpuType" : "ARM-64",
  "roots_installed" : 0,
  "bug_type" : "309",
  "procLaunch" : "2023-06-19 08:58:24.8585 +0300",
  "procStartAbsTime" : 6678466870264,
  "procExitAbsTime" : 6678505456626,
  "procName" : "WakaTime",
  "procPath" : "\/Applications\/WakaTime.app\/Contents\/MacOS\/WakaTime",
  "bundleInfo" : {"CFBundleShortVersionString":"2.0.1","CFBundleVersion":"2.0.1","CFBundleIdentifier":"macos-wakatime.WakaTime"},
  "storeInfo" : {"deviceIdentifierForVendor":"AF2A67F1-F4DC-5792-B1BC-0B7769AD3D7C","thirdParty":true},
  "parentProc" : "launchd",
  "parentPid" : 1,
  "coalitionName" : "macos-wakatime.WakaTime",
  "crashReporterKey" : "FAB9A1F3-F1A3-6F8A-B2F4-7442A5B90BC1",
  "codeSigningID" : "macos-wakatime.WakaTime",
  "codeSigningTeamID" : "538RQNWSWT",
  "codeSigningFlags" : 570503953,
  "codeSigningValidationCategory" : 6,
  "codeSigningTrustLevel" : 0,
  "wakeTime" : 38,
  "sleepWakeUUID" : "8D6C0010-7ED4-42A0-8FA5-EDCA6C804D64",
  "sip" : "enabled",
  "exception" : {"codes":"0x0000000000000001, 0x0000000100d8d5c0","rawCodes":[1,4309177792],"type":"EXC_BREAKPOINT","signal":"SIGTRAP"},
  "termination" : {"flags":0,"code":5,"namespace":"SIGNAL","indicator":"Trace\/BPT trap: 5","byProc":"exc handler","byPid":88068},
  "os_fault" : {"process":"WakaTime"},
  "extMods" : {"caller":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"system":{"thread_create":4,"thread_set_state":10156,"task_for_pid":67},"targeted":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"warnings":0},
  "faultingThread" : 0,
  "threads" : [{"triggered":true,"id":7696157,"threadState":{"x":[{"value":0},{"value":0},{"value":0},{"value":105553178677056},{"value":3693676169529859},{"value":7726646165505},{"value":4168},{"value":1500},{"value":256},{"value":255},{"value":3840},{"value":2043},{"value":3657459732},{"value":2045},{"value":3659558973},{"value":3657459732},{"value":7363861372,"symbolLocation":0,"symbol":"swift_unknownObjectRelease"},{"value":1512046592},{"value":0},{"value":105553116881920},{"value":0},{"value":4294942084},{"value":8654389264,"symbolLocation":0,"symbol":"type metadata for URL"},{"value":6157784544},{"value":8653462616},{"value":6157784512},{"value":105553130475104},{"value":105553150766864},{"value":6157784560}],"flavor":"ARM_THREAD_STATE64","lr":{"value":4309177792},"cpsr":{"value":2147487744},"fp":{"value":6157784800},"sp":{"value":6157784512},"esr":{"value":4060086273,"description":"(Breakpoint) brk 1"},"pc":{"value":4309177792,"matchesCrashFrame":1},"far":{"value":4452122624}},"queue":"com.apple.main-thread","frames":[{"imageOffset":87488,"symbol":"Watcher.watch(app:)","symbolLocation":1460,"imageIndex":0},{"imageOffset":84968,"symbol":"Watcher.handleAppChanged(_:)","symbolLocation":552,"imageIndex":0},{"imageOffset":84008,"symbol":"Watcher.appChanged(_:)","symbolLocation":284,"imageIndex":0},{"imageOffset":84184,"symbol":"@objc Watcher.appChanged(_:)","symbolLocation":128,"imageIndex":0},{"imageOffset":475520,"symbol":"__CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__","symbolLocation":148,"imageIndex":3},{"imageOffset":1113836,"symbol":"___CFXRegistrationPost_block_invoke","symbolLocation":88,"imageIndex":3},{"imageOffset":1113652,"symbol":"_CFXRegistrationPost","symbolLocation":440,"imageIndex":3},{"imageOffset":283852,"symbol":"_CFXNotificationPost","symbolLocation":704,"imageIndex":3},{"imageOffset":39156,"symbol":"-[NSNotificationCenter postNotificationName:object:userInfo:]","symbolLocation":88,"imageIndex":4},{"imageOffset":1938920,"symbol":"applicationStatusSubsystemCallback","symbolLocation":676,"imageIndex":5},{"imageOffset":159280,"symbol":"___LSScheduleNotificationFunction_block_invoke_2","symbolLocation":52,"imageIndex":6},{"imageOffset":520660,"symbol":"__CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__","symbolLocation":28,"imageIndex":3},{"imageOffset":520424,"symbol":"__CFRunLoopDoBlocks","symbolLocation":364,"imageIndex":3},{"imageOffset":517516,"symbol":"__CFRunLoopRun","symbolLocation":2432,"imageIndex":3},{"imageOffset":513208,"symbol":"CFRunLoopRunSpecific","symbolLocation":612,"imageIndex":3},{"imageOffset":199744,"symbol":"RunCurrentEventLoopInMode","symbolLocation":292,"imageIndex":7},{"imageOffset":199292,"symbol":"ReceiveNextEventCommon","symbolLocation":648,"imageIndex":7},{"imageOffset":198612,"symbol":"_BlockUntilNextEventMatchingListInModeWithFilter","symbolLocation":76,"imageIndex":7},{"imageOffset":232772,"symbol":"_DPSNextEvent","symbolLocation":636,"imageIndex":5},{"imageOffset":229088,"symbol":"-[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:]","symbolLocation":716,"imageIndex":5},{"imageOffset":181060,"symbol":"-[NSApplication run]","symbolLocation":464,"imageIndex":5},{"imageOffset":22216,"symbol":"main","symbolLocation":120,"imageIndex":0},{"imageOffset":24360,"symbol":"start","symbolLocation":2236,"imageIndex":8}]},{"id":7696227,"frames":[{"imageOffset":7564,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]},{"id":7696228,"frames":[{"imageOffset":7564,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]},{"id":7696231,"frames":[{"imageOffset":7564,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]},{"id":7696264,"name":"com.apple.NSEventThread","frames":[{"imageOffset":3860,"symbol":"mach_msg2_trap","symbolLocation":8,"imageIndex":10},{"imageOffset":78400,"symbol":"mach_msg2_internal","symbolLocation":80,"imageIndex":10},{"imageOffset":39800,"symbol":"mach_msg_overwrite","symbolLocation":604,"imageIndex":10},{"imageOffset":4752,"symbol":"mach_msg","symbolLocation":24,"imageIndex":10},{"imageOffset":522212,"symbol":"__CFRunLoopServiceMachPort","symbolLocation":160,"imageIndex":3},{"imageOffset":516292,"symbol":"__CFRunLoopRun","symbolLocation":1208,"imageIndex":3},{"imageOffset":513208,"symbol":"CFRunLoopRunSpecific","symbolLocation":612,"imageIndex":3},{"imageOffset":1454900,"symbol":"_NSEventThread","symbolLocation":172,"imageIndex":5},{"imageOffset":28584,"symbol":"_pthread_start","symbolLocation":148,"imageIndex":9},{"imageOffset":7584,"symbol":"thread_start","symbolLocation":8,"imageIndex":9}]},{"id":7696265,"frames":[{"imageOffset":7564,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]},{"id":7696266,"frames":[{"imageOffset":7564,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]},{"id":7696267,"frames":[{"imageOffset":7564,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]},{"id":7696268,"frames":[{"imageOffset":7564,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]},{"id":7696269,"frames":[{"imageOffset":7564,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":9}]}],
  "usedImages" : [
  {
    "source" : "P",
    "arch" : "arm64",
    "base" : 4309090304,
    "CFBundleShortVersionString" : "2.0.1",
    "CFBundleIdentifier" : "macos-wakatime.WakaTime",
    "size" : 131072,
    "uuid" : "491019e8-b56d-3813-8bb1-def204d7d343",
    "path" : "\/Applications\/WakaTime.app\/Contents\/MacOS\/WakaTime",
    "name" : "WakaTime",
    "CFBundleVersion" : "2.0.1"
  },
  {
    "source" : "P",
    "arch" : "arm64",
    "base" : 4310646784,
    "CFBundleShortVersionString" : "2.4.1",
    "CFBundleIdentifier" : "org.sparkle-project.Sparkle",
    "size" : 278528,
    "uuid" : "85cd37f1-a154-35f6-8ee1-b0133b257fe1",
    "path" : "\/Applications\/WakaTime.app\/Contents\/Frameworks\/Sparkle.framework\/Versions\/B\/Sparkle",
    "name" : "Sparkle",
    "CFBundleVersion" : "2027"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 4310466560,
    "size" : 49152,
    "uuid" : "570c31f7-94c6-3b86-ae44-1694db0a4bcd",
    "path" : "\/usr\/lib\/libobjc-trampolines.dylib",
    "name" : "libobjc-trampolines.dylib"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 7111602176,
    "CFBundleShortVersionString" : "6.9",
    "CFBundleIdentifier" : "com.apple.CoreFoundation",
    "size" : 5087232,
    "uuid" : "203e4401-8c2e-3157-a24b-92f52551d43e",
    "path" : "\/System\/Library\/Frameworks\/CoreFoundation.framework\/Versions\/A\/CoreFoundation",
    "name" : "CoreFoundation",
    "CFBundleVersion" : "1977"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 7127961600,
    "CFBundleShortVersionString" : "6.9",
    "CFBundleIdentifier" : "com.apple.Foundation",
    "size" : 10248192,
    "uuid" : "d5337cc6-a075-3ca0-b5bf-b49da8878337",
    "path" : "\/System\/Library\/Frameworks\/Foundation.framework\/Versions\/C\/Foundation",
    "name" : "Foundation",
    "CFBundleVersion" : "1977"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 7164448768,
    "CFBundleShortVersionString" : "6.9",
    "CFBundleIdentifier" : "com.apple.AppKit",
    "size" : 15790080,
    "uuid" : "041c7d21-21cc-3eea-ae53-d39f5ca6a24e",
    "path" : "\/System\/Library\/Frameworks\/AppKit.framework\/Versions\/C\/AppKit",
    "name" : "AppKit",
    "CFBundleVersion" : "2299.60.124"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 7116689408,
    "CFBundleShortVersionString" : "1141.1",
    "CFBundleIdentifier" : "com.apple.LaunchServices",
    "size" : 2609152,
    "uuid" : "556590f5-8fed-36a6-830b-ea49bd95b1fe",
    "path" : "\/System\/Library\/Frameworks\/CoreServices.framework\/Versions\/A\/Frameworks\/LaunchServices.framework\/Versions\/A\/LaunchServices",
    "name" : "LaunchServices",
    "CFBundleVersion" : "1141.1"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 7271604224,
    "CFBundleShortVersionString" : "2.1.1",
    "CFBundleIdentifier" : "com.apple.HIToolbox",
    "size" : 3358720,
    "uuid" : "d800278b-4e6c-3032-b56f-027a938a51d6",
    "path" : "\/System\/Library\/Frameworks\/Carbon.framework\/Versions\/A\/Frameworks\/HIToolbox.framework\/Versions\/A\/HIToolbox",
    "name" : "HIToolbox"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 7107682304,
    "size" : 582996,
    "uuid" : "bd993f39-c902-37d6-8bd8-6d827c7f121e",
    "path" : "\/usr\/lib\/dyld",
    "name" : "dyld"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 7111184384,
    "size" : 53248,
    "uuid" : "46d35233-a051-3f4f-bba4-ba56dddc4d1a",
    "path" : "\/usr\/lib\/system\/libsystem_pthread.dylib",
    "name" : "libsystem_pthread.dylib"
  },
  {
    "source" : "P",
    "arch" : "arm64e",
    "base" : 7110946816,
    "size" : 237544,
    "uuid" : "42f503e2-9273-360a-a086-c1b19bbd3962",
    "path" : "\/usr\/lib\/system\/libsystem_kernel.dylib",
    "name" : "libsystem_kernel.dylib"
  }
],
  "sharedCache" : {
  "base" : 7107018752,
  "size" : 3551805440,
  "uuid" : "7d9faa84-5c6b-3ef4-9379-faba64346673"
},
  "vmSummary" : "ReadOnly portion of Libraries: Total=1.2G resident=0K(0%) swapped_out_or_unallocated=1.2G(100%)\nWritable regions: Total=1.5G written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=1.5G(100%)\n\n                                VIRTUAL   REGION \nREGION TYPE                        SIZE    COUNT (non-coalesced) \n===========                     =======  ======= \nAccelerate framework               128K        1 \nActivity Tracing                   256K        1 \nCG image                           112K        6 \nColorSync                          496K       25 \nCoreAnimation                      688K       28 \nCoreGraphics                        48K        3 \nCoreServices                       256K        1 \nCoreUI image data                 1648K       13 \nFoundation                          16K        1 \nKernel Alloc Once                   32K        1 \nMALLOC                           277.5M       58 \nMALLOC guard page                  288K       14 \nMALLOC_MEDIUM (reserved)         840.0M        7         reserved VM address space (unallocated)\nMALLOC_NANO (reserved)           384.0M        1         reserved VM address space (unallocated)\nSQLite page cache                  128K        1 \nSTACK GUARD                       56.2M       10 \nStack                             12.8M       10 \nVM_ALLOCATE                        112K        7 \n__AUTH                             855K      209 \n__AUTH_CONST                      17.6M      392 \n__CTF                               824        1 \n__DATA                            6761K      381 \n__DATA_CONST                      17.8M      396 \n__DATA_DIRTY                       987K      136 \n__FONT_DATA                        2352        1 \n__LINKEDIT                       802.1M        4 \n__OBJC_RO                         66.3M        1 \n__OBJC_RW                         2011K        1 \n__TEXT                           376.9M      415 \ndyld private memory                272K        2 \nlibnetwork                         128K        8 \nmapped file                       80.0M       28 \nshared memory                      864K       13 \n===========                     =======  ======= \nTOTAL                              2.9G     2176 \nTOTAL, minus reserved VM space     1.7G     2176 \n",
  "legacyInfo" : {
  "threadTriggered" : {
    "queue" : "com.apple.main-thread"
  }
},
  "logWritingSignature" : "cc6941b62c136f20b2f90c2a5f8efcf4c7cd7428",
  "trialInfo" : {
  "rollouts" : [
    {
      "rolloutId" : "62c74108bcb0435c2153f963",
      "factorPackIds" : {
        "SIRI_TEXT_TO_SPEECH" : "64810e3fd0f2cd4ea9c0d6b9"
      },
      "deploymentId" : 240000226
    },
    {
      "rolloutId" : "5f72dc58705eff005a46b3a9",
      "factorPackIds" : {

      },
      "deploymentId" : 240000015
    }
  ],
  "experiments" : [
    {
      "treatmentId" : "c28e4ee6-1b08-4f90-8e05-2809e78310a3",
      "experimentId" : "6317d2003d24842ff850182a",
      "deploymentId" : 400000013
    },
    {
      "treatmentId" : "6dd670af-0633-45e4-ae5f-122ae4df02be",
      "experimentId" : "64406ba83deb637ac8a04419",
      "deploymentId" : 900000005
    }
  ]
}
}


Crashing in background

Sometimes the app crashes in the background, and I only realize it a couple of hours after the crash by realizing the missing icon in the system tray.
See me not realizing the crash for two days :);
CleanShot 2023-06-02 at 22 12 31@2x

I want to supply some helpful info regarding this, but I need to figure out how we log things and get a reasonable trace to fix this issue.

Any help?

Add iterm or terminal app? (suggesstion)

i see terminal tracking out there in Wakatime, but it seems a lot of problems such as vs code are not tracked when I use terminal, dont give much better coding stats and so on.

how about adding iTerm and terminal tracking in wakatime macOS?

Support tracking more apps beyond Xcode

  • default on for all apps
  • ability to toggle tracking off per app in settings menu
  • start with Figma Desktop or Postman just to get it working for one app, can add more later

Ability to filter browsing activity by url

We should allow including or excluding websites based on regex patterns. This means a toggle between Include Only and Exclude, with a textarea or input list of configurable regex patterns. The patterns would run on the whole url so they could match just the domain, path parts, or both.

We should set some sane defaults for known dev sites, similar to wakatime/browser-wakatime#249.

Use timer to detect long Xcode builds when user afk

If a build takes too long devs might go for a coffee. Currently without user events we don't track any heartbeats, even if a build is still running. Let's look into using a timer that unregisters itself after no longer building.

Features todo

  • first GH release with signed and notarized apps for amd and arm #2
  • Only download wakatime-cli when new release available #5 #11
  • support old OS X (No SwiftUI) #13
  • fix kAXSelectedTextChangedNotification and kAXValueChangedNotification firing too often, even when cursor has not changed row/col #14
  • support tracking more apps beyond Xcode, default on, with ability to toggle tracking off per app in the settings menu #15
  • use a Swift linter in GH Actions, and docs on how to run linter locally before submitting a PR #16

Figma and Postman not tracked

so i have two laptops which is personal and work. by installing wakatime i can track the xcode but both figma and postman are not tracked in my machine. so is this my machine problem or wakatime havent ready yet to track those app times? from what i see in leaderboard there is no postman or figma (maybe postman is json but its not even moving at all)

Detect/handle Accessibility permission not granted

macOS: 13.2.1 (22D68)

Add notification AXFocusedUIElementChanged failed: -25211

Screenshot 2023-03-15 at 01 01 53

checked System Settings -> Privacy & Security -> Accessibility -> WakaTime switch is On

Screenshot 2023-03-15 at 01 07 17

By a few times run / build / install / uninstall, are there some clean job need to be done?

Support new app: Safari Technology Preview

BundleId of the app

com.apple.SafariTechnologyPreview

Example window titles

Same as Safari, far as I know.
I am often testing on the tech preview, and would like to be sure it is tracked too.

Can't add/remove apps to be tracked

I can only select the following 4 apps to be tracked/or not tracked:

Scherm­afbeelding 2024-01-02 om 15 48 16

Is that normal behaviour?

I would love to select more apps that it would track and also exclude certain items like maybe webpages?

Indicate when WakaTime cannot watch Xcode due to missing accessibility permission

I created a first draft of what an indicator in the menu bar item could look like:

WakaTime missing permission indicator

It would look similar with a light menu bar with a slightly different contrast of the red dot. The dark version has a bit of a darker red to improve the contrast on a dark menu bar.

The menu bar would show a message similar to the one in the screenshot (texts are just quickly drafted for now). Below the message, it would show a clickable menu item which would re-trigger the request for accessibility permissions and open the System Settings as it's done during the initial app launch currently.

Here's a few issues that I stumbled upon when designing/researching this approach:

  1. Using color in the menu bar icons on macOS is rare since the translucent menu bars were introduced. Most apps stick to monochrome icons and macOS now automatically tints the menu bar according to the system's dark mode setting if not prevented. Most apps that I have tested indicate their status by making their menu icon semi-transparent. Notable examples are: Dropbox, Google Drive and the built-in Wifi indicator which also displays a diagonal strike-through on top. These would be alternatives to the design above.
  2. A red indicator upon first app launch, where the user didn't have the chance to grant or deny permission actively yet, might signal that something is wrong even though it isn't. It would be better to show the indicator only once we're sure that the initial permission request has been ignored/denied. An issue might be to define a point in time when we can be reasonably sure that this is the case. Which is a good segue to point 3...
  3. This would really work great if combined with a properly designed onboarding window that leads the user through the process and reports feedback as they grant permission. I found a good (in my opinion) example for that, which would be the Bartender app, screenshot of their onboarding window below.
Screenshot 2023-07-20 at 12 45 26 Screenshot 2023-07-20 at 12 45 34

We could do it in a very similar fashion and either do the menu bar indicator (red dot or semi-transparent icon) as well or just do the onboarding window without the indicator.

If we chose to use the menu bar indicator + the onboarding window, once the onboarding window is closed, the indicator could become active if the user still didn't grant access to the permissions needed for the WakaTime app to fulfill its main purpose.

Fallback to filesystem and mouse events to track any app

To start sending heartbeats for apps that don't support Accessibility events, we'll start watching keypress and filesystem events. The combination of keypress and filesystem events will be called Fallback events (our own term).

Using Fallback events, we can start tracking any mac app not just known ones. To do that, we need:

  • Detect all installed apps from /Applications/ and list those apps with their icon and name in the Monitored Apps settings menu so they can be enabled for tracking. Only known apps (Xcode, Figma, Postman) will be enabled for tracking by default.
  • Xcode will use Accessibility APIs while all other apps will start by using Fallback events and switch to Accessibility events if we see them triggered for that app. When we get an Accessibility event for an app, turn off tracking Fallback events for that app until WakaTime.app is re-launched.
  • When using Fallback events for an app, keep track of the last edited file for that app and use keypress events to trigger sending heartbeats for that file. Only keep track of files which we've detected a WakaTime project, to avoid tracking system and temp files that the app might have open.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.