alfredapp / ignore-in-alfred-workflow

Exclude files and folders from Alfred’s search results
BSD 3-Clause "New" or "Revised" License
24 stars 0 forks source link

tag quit unexpectedly #8

Closed ngocphamm closed 11 months ago

ngocphamm commented 11 months ago

Workflow version

2023.4

Alfred version

5.1.2

macOS version

13.6

Debugger output

[10:51:33.388] Logging Started...
[10:51:42.779] Ignore in Alfred[File Action] Processing complete
[10:51:42.784] Ignore in Alfred[File Action] Passing output '/System/Volumes/Data/Applications/1Password for Safari.app' to Automation Task
[10:51:42.786] Ignore in Alfred[Automation Task] Running task 'Add Tags' with arguments (
    "/System/Volumes/Data/Applications/1Password for Safari.app"
)
[10:51:42.814] ERROR: Ignore in Alfred[Automation Task] Task Error: Swift/ErrorType.swift:200: Fatal error: Error raised at top level: Error Domain=NSOSStatusErrorDomain Code=-5000 "afpAccessDenied: Insufficient access privileges for operation " UserInfo={NSURLKeysOfUnsetValuesKey=(
    NSURLTagNamesKey
)}

More details

This works on another mac M1 of mine, same OS version, same Alfred, and workflow version.

It happens when I try to ignore "1Password for Safari". An extension downloaded from Mac App Store. I think that's the problem.

This is the bug report macOS represents me to send to Apple.

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

Process:               tag [47944]
Path:                  /Users/USER/Library/Application Support/Alfred/*/tag
Identifier:            tag
Version:               ???
Code Type:             X86-64 (Native)
Parent Process:        Exited process [47943]
Responsible:           Alfred [1785]
User ID:               501

Date/Time:             2023-09-23 10:41:55.9476 -0400
OS Version:            macOS 13.6 (22G120)
Report Version:        12
Bridge OS Version:     8.0 (21P365)
Anonymous UUID:        5BC96580-4700-B7FD-F338-903DA2A53A78

Sleep/Wake UUID:       F9DFE0CB-A1B7-4876-B545-B2D0AE416B14

Time Awake Since Boot: 21000 seconds
Time Since Wake:       12480 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 [47944]

Thread 0 Crashed::  Dispatch queue: com.apple.main-thread
0   libswiftCore.dylib                  0x7ff818197631 _assertionFailure(_:_:file:line:flags:) + 353
1   libswiftCore.dylib                  0x7ff818210aa7 swift_errorInMain + 583
2   tag                                    0x10df5a2e6 main + 2790
3   dyld                                0x7ff80880b41f start + 1903

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

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

Thread 0 crashed with X86 Thread State (64-bit):
  rax: 0x0000000200000003  rbx: 0x000000000000000b  rcx: 0xfffffffe00000000  rdx: 0x0000000000000003
  rdi: 0x000060000334c008  rsi: 0x00000000000007fb  rbp: 0x00007ff7b1faa200  rsp: 0x00007ff7b1faa160
   r8: 0x0000000000000049   r9: 0x0000000000000048  r10: 0x00000000000001c0  r11: 0x0000600000e414d4
  r12: 0x0000000000000000  r13: 0x00000000000000c7  r14: 0x00007ff8185c0ce4  r15: 0x000060000334c000
  rip: 0x00007ff818197631  rfl: 0x0000000000010246  cr2: 0x0000600003054000

Logical CPU:     10
Error Code:      0x00000000 
Trap Number:     6

Thread 0 instruction stream:
  00 00 48 b8 00 00 00 00-00 00 00 10 49 85 c5 0f  ..H.........I...
  84 83 01 00 00 48 ff c8-4c 89 ff 48 21 c7 48 83  .....H..L..H!.H.
  c7 20 48 b8 ff ff ff ff-ff ff 00 00 49 21 c5 48  . H.........I!.H
  83 ec 08 44 0f b6 c1 4c-89 ee 4c 89 e2 48 8b 4d  ...D...L..L..H.M
  10 4d 89 f1 45 31 e4 8b-45 28 50 ff 75 20 53 e8  .M..E1..E(P.u S.
  4b 0f 00 00 48 83 c4 20-4c 89 ff e8 ef ab 30 00  K...H.. L.....0.
 [0f]0b 48 83 ec 08 48 8d-05 12 9b 42 00 48 8d 3d  ..H...H....B.H.= <==
  9f 96 42 00 48 8d 0d b4-99 42 00 be 0b 00 00 00  ..B.H....B......
  41 b8 39 00 00 00 ba 02-00 00 00 41 b9 02 00 00  A.9........A....
  00 6a 01 68 94 00 00 00-6a 02 6a 18 50 e8 ad 02  .j.h....j.j.P...
  00 00 4c 89 fe 48 c1 ee-38 83 e6 0f 48 b8 ff ff  ..L..H..8...H...
  ff ff ff ff ff 00 4c 21-f8 4c 89 6d c0 48 89 45  ......L!.L.m.H.E

Binary Images:
       0x10df55000 -        0x10df60fff tag (*) <78fe553d-a232-3e91-b83c-e4706ec0817a> /Users/USER/Library/Application Support/Alfred/*/tag
    0x7ff818168000 -     0x7ff8185f1ff4 libswiftCore.dylib (*) <087dadad-d590-35ea-ac4d-7b0e966804eb> /usr/lib/swift/libswiftCore.dylib
    0x7ff808805000 -     0x7ff80889d5ef dyld (*) <3df96f32-b9c9-3566-a6b7-4daebc6d6563> /usr/lib/dyld
    0x7ff808b5f000 -     0x7ff808b6afff libsystem_pthread.dylib (*) <3a3fa85c-f1fe-336c-bf68-924fc947ade3> /usr/lib/system/libsystem_pthread.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: 0
    thread_create: 0
    thread_set_state: 0

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

                                VIRTUAL   REGION 
REGION TYPE                        SIZE    COUNT (non-coalesced) 
===========                     =======  ======= 
Activity Tracing                   256K        1 
CoreServices                       160K        1 
Kernel Alloc Once                    8K        1 
MALLOC                           198.2M       23 
MALLOC guard page                   24K        5 
MALLOC_MEDIUM (reserved)         120.0M        1         reserved VM address space (unallocated)
MALLOC_NANO (reserved)           384.0M        1         reserved VM address space (unallocated)
STACK GUARD                       56.0M        3 
Stack                             9232K        3 
VM_ALLOCATE                          8K        2 
__CTF                               824        1 
__DATA                            15.0M      288 
__DATA_CONST                      10.8M      176 
__DATA_DIRTY                       480K      101 
__FONT_DATA                        2352        1 
__LINKEDIT                       171.0M        3 
__OBJC_RO                         66.3M        1 
__OBJC_RW                         2013K        2 
__TEXT                           213.1M      311 
dyld private memory                260K        2 
mapped file                       38.2M        4 
shared memory                      600K        8 
===========                     =======  ======= 
TOTAL                              1.3G      939 
TOTAL, minus reserved VM space   781.3M      939 

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

{"app_name":"tag","timestamp":"2023-09-23 10:41:56.00 -0400","app_version":"","slice_uuid":"78fe553d-a232-3e91-b83c-e4706ec0817a","build_version":"","platform":1,"share_with_app_devs":0,"is_first_party":1,"bug_type":"309","os_version":"macOS 13.6 (22G120)","roots_installed":0,"incident_id":"60AE4884-40F8-4441-978B-4125371D250E","name":"tag"}
{
  "uptime" : 21000,
  "procRole" : "Unspecified",
  "version" : 2,
  "userID" : 501,
  "deployVersion" : 210,
  "modelCode" : "MacBookPro16,1",
  "coalitionID" : 2509,
  "osVersion" : {
    "train" : "macOS 13.6",
    "build" : "22G120",
    "releaseType" : "User"
  },
  "captureTime" : "2023-09-23 10:41:55.9476 -0400",
  "incident" : "60AE4884-40F8-4441-978B-4125371D250E",
  "pid" : 47944,
  "cpuType" : "X86-64",
  "roots_installed" : 0,
  "bug_type" : "309",
  "procLaunch" : "2023-09-23 10:41:55.9164 -0400",
  "procStartAbsTime" : 21971423733652,
  "procExitAbsTime" : 21971454594189,
  "procName" : "tag",
  "procPath" : "\/Users\/USER\/Library\/Application Support\/Alfred\/*\/tag",
  "parentProc" : "Exited process",
  "parentPid" : 47943,
  "coalitionName" : "com.runningwithcrayons.Alfred",
  "crashReporterKey" : "5BC96580-4700-B7FD-F338-903DA2A53A78",
  "responsiblePid" : 1785,
  "responsibleProc" : "Alfred",
  "codeSigningID" : "tag",
  "codeSigningTeamID" : "WL898W6Y89",
  "codeSigningFlags" : 570503953,
  "codeSigningValidationCategory" : 6,
  "codeSigningTrustLevel" : 0,
  "wakeTime" : 12480,
  "bridgeVersion" : {"build":"21P365","train":"8.0"},
  "sleepWakeUUID" : "F9DFE0CB-A1B7-4876-B545-B2D0AE416B14",
  "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":47944},
  "extMods" : {"caller":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"system":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"targeted":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"warnings":0},
  "faultingThread" : 0,
  "threads" : [{"triggered":true,"id":428256,"instructionState":{"instructionStream":{"bytes":[0,0,72,184,0,0,0,0,0,0,0,16,73,133,197,15,132,131,1,0,0,72,255,200,76,137,255,72,33,199,72,131,199,32,72,184,255,255,255,255,255,255,0,0,73,33,197,72,131,236,8,68,15,182,193,76,137,238,76,137,226,72,139,77,16,77,137,241,69,49,228,139,69,40,80,255,117,32,83,232,75,15,0,0,72,131,196,32,76,137,255,232,239,171,48,0,15,11,72,131,236,8,72,141,5,18,155,66,0,72,141,61,159,150,66,0,72,141,13,180,153,66,0,190,11,0,0,0,65,184,57,0,0,0,186,2,0,0,0,65,185,2,0,0,0,106,1,104,148,0,0,0,106,2,106,24,80,232,173,2,0,0,76,137,254,72,193,238,56,131,230,15,72,184,255,255,255,255,255,255,255,0,76,33,248,76,137,109,192,72,137,69],"offset":96}},"threadState":{"r13":{"value":199},"rax":{"value":8589934595},"rflags":{"value":66118},"cpu":{"value":10},"r14":{"value":140703537302756},"rsi":{"value":2043},"r8":{"value":73},"cr2":{"value":105553166942208},"rdx":{"value":3},"r10":{"value":448},"r9":{"value":72},"r15":{"value":105553170055168},"rbx":{"value":11},"trap":{"value":6},"err":{"value":0},"r11":{"value":105553131214036},"rip":{"value":140703532938801,"matchesCrashFrame":1},"rbp":{"value":140701819642368},"rsp":{"value":140701819642208},"r12":{"value":0},"rcx":{"value":18446744065119617024},"flavor":"x86_THREAD_STATE","rdi":{"value":105553170055176}},"queue":"com.apple.main-thread","frames":[{"imageOffset":194097,"symbol":"_assertionFailure(_:_:file:line:flags:)","symbolLocation":353,"imageIndex":1},{"imageOffset":690855,"symbol":"swift_errorInMain","symbolLocation":583,"imageIndex":1},{"imageOffset":21222,"symbol":"main","symbolLocation":2790,"imageIndex":0},{"imageOffset":25631,"symbol":"start","symbolLocation":1903,"imageIndex":2}]},{"id":428259,"frames":[{"imageOffset":7088,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":3}]},{"id":428260,"frames":[{"imageOffset":7088,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":3}]}],
  "usedImages" : [
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 4529147904,
    "size" : 49152,
    "uuid" : "78fe553d-a232-3e91-b83c-e4706ec0817a",
    "path" : "\/Users\/USER\/Library\/Application Support\/Alfred\/*\/tag",
    "name" : "tag"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703532744704,
    "size" : 4759541,
    "uuid" : "087dadad-d590-35ea-ac4d-7b0e966804eb",
    "path" : "\/usr\/lib\/swift\/libswiftCore.dylib",
    "name" : "libswiftCore.dylib"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703271243776,
    "size" : 624112,
    "uuid" : "3df96f32-b9c9-3566-a6b7-4daebc6d6563",
    "path" : "\/usr\/lib\/dyld",
    "name" : "dyld"
  },
  {
    "source" : "P",
    "arch" : "x86_64",
    "base" : 140703274758144,
    "size" : 49152,
    "uuid" : "3a3fa85c-f1fe-336c-bf68-924fc947ade3",
    "path" : "\/usr\/lib\/system\/libsystem_pthread.dylib",
    "name" : "libsystem_pthread.dylib"
  }
],
  "sharedCache" : {
  "base" : 140703270621184,
  "size" : 21474836480,
  "uuid" : "2434d7b8-6144-3aef-92fd-a483c33f40d2"
},
  "vmSummary" : "ReadOnly portion of Libraries: Total=384.0M resident=0K(0%) swapped_out_or_unallocated=384.0M(100%)\nWritable regions: Total=711.9M written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=711.9M(100%)\n\n                                VIRTUAL   REGION \nREGION TYPE                        SIZE    COUNT (non-coalesced) \n===========                     =======  ======= \nActivity Tracing                   256K        1 \nCoreServices                       160K        1 \nKernel Alloc Once                    8K        1 \nMALLOC                           198.2M       23 \nMALLOC guard page                   24K        5 \nMALLOC_MEDIUM (reserved)         120.0M        1         reserved VM address space (unallocated)\nMALLOC_NANO (reserved)           384.0M        1         reserved VM address space (unallocated)\nSTACK GUARD                       56.0M        3 \nStack                             9232K        3 \nVM_ALLOCATE                          8K        2 \n__CTF                               824        1 \n__DATA                            15.0M      288 \n__DATA_CONST                      10.8M      176 \n__DATA_DIRTY                       480K      101 \n__FONT_DATA                        2352        1 \n__LINKEDIT                       171.0M        3 \n__OBJC_RO                         66.3M        1 \n__OBJC_RW                         2013K        2 \n__TEXT                           213.1M      311 \ndyld private memory                260K        2 \nmapped file                       38.2M        4 \nshared memory                      600K        8 \n===========                     =======  ======= \nTOTAL                              1.3G      939 \nTOTAL, minus reserved VM space   781.3M      939 \n",
  "legacyInfo" : {
  "threadTriggered" : {
    "queue" : "com.apple.main-thread"
  }
},
  "logWritingSignature" : "d125a4174d0a9f1e4f2486a48655a057333678d9",
  "trialInfo" : {
  "rollouts" : [
    {
      "rolloutId" : "62fe74515312cd4599bd3c80",
      "factorPackIds" : {
        "MYRIAD_BOOSTS" : "62fe74805312cd4599bd3c81"
      },
      "deploymentId" : 240000006
    },
    {
      "rolloutId" : "6112d17137f5d11121dcd4e2",
      "factorPackIds" : {

      },
      "deploymentId" : 240000401
    }
  ],
  "experiments" : [
    {
      "treatmentId" : "3a3cf641-8471-4e4e-9ad4-81d0ede970fd",
      "experimentId" : "64a84dae90d82611a0bd7d3d",
      "deploymentId" : 400000010
    },
    {
      "treatmentId" : "6dd670af-0633-45e4-ae5f-122ae4df02be",
      "experimentId" : "64406ba83deb637ac8a04419",
      "deploymentId" : 900000017
    }
  ]
}
}

Model: MacBookPro16,1, BootROM 2020.0.1.0.0 (iBridge: 21.16.365.0.0,0), 8 processors, 8-Core Intel Core i9, 2.3 GHz, 64 GB, SMC 
Graphics: Intel UHD Graphics 630, Intel UHD Graphics 630, Built-In
Display: Color LCD, 3072 x 1920 Retina, Main, MirrorOff, Online
Graphics: AMD Radeon Pro 5500M, AMD Radeon Pro 5500M, PCIe, 4 GB
Memory Module: BANK 0/ChannelA-DIMM0, 32 GB, DDR4, 2667 MHz, Micron, MT40A4G8BAF-062E:B
Memory Module: BANK 2/ChannelB-DIMM0, 32 GB, DDR4, 2667 MHz, Micron, MT40A4G8BAF-062E:B
AirPort: spairport_wireless_card_type_wifi (0x14E4, 0x7BF), wl0: Dec  9 2022 17:02:25 version 9.30.492.0.32.5.87 FWID 01-e7856862
Bluetooth: Version (null), 0 services, 0 devices, 0 incoming serial ports
Network Service: Wi-Fi, AirPort, en0
Network Service: Tailscale Tunnel, VPN (io.tailscale.ipn.macos), utun9
USB Device: USB31Bus
USB Device: T2Bus
USB Device: composite_device
USB Device: Touch Bar Backlight
USB Device: Touch Bar Display
USB Device: Apple Internal Keyboard / Trackpad
USB Device: Headset
USB Device: Ambient Light Sensor
USB Device: FaceTime HD Camera (Built-in)
USB Device: Apple T2 Controller
Thunderbolt Bus: MacBook Pro, Apple Inc., 63.5
Thunderbolt Bus: MacBook Pro, Apple Inc., 63.5
vitorgalvao commented 11 months ago

Apps installed from the Mac App Store have higher permissions. Add the tag manually by right-clicking → Get Info then adding an alfred:ignore tag. The linked issue goes into more detail on why the workflow purposefully does not handle those cases.

ngocphamm commented 11 months ago

@vitorgalvao Do you think there's anyway we can try to interprete the error message and provider a friendlier message in such case?

vitorgalvao commented 11 months ago

That’s not a bad idea. Thing is, this uses an Automation Task which needs to work generically so it can’t have a message too specific to the workflow. I’ll have a thought about this and try a few things.