Preview.app всегда вылетает

19361
Val Kalinic

Со вчерашнего дня мой 10.9 Preview.app всегда вылетает при открытии любого файла.
Когда я открываю его, он спрашивает, можно ли открыть старые окна; Если я выберу «да», то это вылетит Если я решу не делать выбор и выбрать файл, он также вылетает. Как это происходит, когда я дважды щелкаю любой PDF или изображение.

Что я могу сделать?

Вот журнал:

Process: Preview [1960] Path: /Applications/Preview.app/Contents/MacOS/Preview Identifier: com.apple.Preview Version: 8.0 (859) Build Info: Preview-859000000000000~1 Code Type: X86-64 (Native) Parent Process: ??? [1] Responsible: Preview [1960] User ID: 501  Date/Time: 2014-11-02 19:56:52.700 +0100 OS Version: Mac OS X 10.10 (14A388a) Report Version: 11 Anonymous UUID: AB39FEBF-7960-770F-2DE8-1D5525096B1A   Time Awake Since Boot: 6900 seconds  Crashed Thread: 0 Dispatch queue: com.apple.main-thread  Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x0000000000000000, 0x0000000000000000  Application Specific Information: *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSPlaceholderSet initWithObjects:count:]: attempt to insert nil object from objects[0]' terminating with uncaught exception of type NSException abort() called  Application Specific Backtrace 1: 0 CoreFoundation 0x00007fff8def064c __exceptionPreprocess + 172 1 libobjc.A.dylib 0x00007fff89e2b6de objc_exception_throw + 43 2 CoreFoundation 0x00007fff8dda782f -[__NSPlaceholderSet initWithObjects:count:] + 399 3 CoreFoundation 0x00007fff8de23e5f +[NSSet setWithObject:] + 47 4 AnnotationKit 0x000000010170934c -[AKAttributeController _updateStateOnSenderFromSelf:] + 304 5 AnnotationKit 0x00000001017084f3 -[AKAttributeController _updateStateOnSender:] + 135 6 AnnotationKit 0x0000000101704eb6 -[AKAttributeController validateAttributeSender:] + 213 7 AnnotationKit 0x0000000101709add -[AKActionController validateSender:] + 206 8 AnnotationKit 0x00000001016cb837 -[AKTextAttributesViewController validateUserInterfaceItems] + 116 9 AnnotationKit 0x00000001017479be -[AKToolbarViewController_Mac revalidateItems] + 411 10 AnnotationKit 0x0000000101707467 -[AKAttributeController _syncAttributesFromSelectedAnnotationsToUI] + 82 11 AnnotationKit 0x0000000101704f69 -[AKAttributeController setModelControllerToObserveForSelections:] + 143 12 AnnotationKit 0x00000001016d9c98 -[AKController observeValueForKeyPath:ofObject:change:context:] + 887 13 Foundation 0x00007fff8b871c73 NSKeyValueNotifyObserver + 382 14 Foundation 0x00007fff8b870e48 NSKeyValueDidChange + 463 15 Foundation 0x00007fff8b8759ad -[NSObject(NSKeyValueObserverNotification) didChangeValueForKey:] + 118 16 Preview 0x0000000101457f2a Preview + 110378 17 Preview 0x0000000101451e57 Preview + 85591 18 Preview 0x0000000101448f99 Preview + 49049 19 AppKit 0x00007fff8c12d637 -[NSWindowController _windowDidLoad] + 586 20 AppKit 0x00007fff8c1147f2 -[NSWindowController window] + 110 21 Preview 0x0000000101446fb6 Preview + 40886 22 AppKit 0x00007fff8c115971 -[NSWindowController showWindow:] + 36 23 Preview 0x000000010144843a Preview + 46138 24 Foundation 0x00007fff8b899fac -[NSObject(NSThreadPerformAdditions) performSelector:onThread:withObject:waitUntilDone:modes:] + 954 25 Foundation 0x00007fff8b899ab0 -[NSObject(NSThreadPerformAdditions) performSelectorOnMainThread:withObject:waitUntilDone:] + 131 26 Preview 0x0000000101448363 Preview + 45923 27 Preview 0x0000000101447160 Preview + 41312 28 Preview 0x000000010153b3fd Preview + 1041405 29 libdispatch.dylib 0x00007fff85840323 _dispatch_call_block_and_release + 12 30 libdispatch.dylib 0x00007fff8583bc13 _dispatch_client_callout + 8 31 libdispatch.dylib 0x00007fff85847cbf _dispatch_main_queue_callback_4CF + 861 32 CoreFoundation 0x00007fff8de43c59 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9 33 CoreFoundation 0x00007fff8de002ef __CFRunLoopRun + 2159 34 CoreFoundation 0x00007fff8ddff838 CFRunLoopRunSpecific + 296 35 HIToolbox 0x00007fff900e543f RunCurrentEventLoopInMode + 235 36 HIToolbox 0x00007fff900e51ba ReceiveNextEventCommon + 431 37 HIToolbox 0x00007fff900e4ffb _BlockUntilNextEventMatchingListInModeWithFilter + 71 38 AppKit 0x00007fff8beeb821 _DPSNextEvent + 964 39 AppKit 0x00007fff8beeafd0 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 194 40 AppKit 0x00007fff8bedef73 -[NSApplication run] + 594 41 AppKit 0x00007fff8beca424 NSApplicationMain + 1832 42 libdyld.dylib 0x00007fff846455c9 start + 1 43 ??? 0x0000000000000001 0x0 + 1  Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 libsystem_kernel.dylib 0x00007fff90e6e282 __pthread_kill + 10 1 libsystem_c.dylib 0x00007fff868ceb73 abort + 129 2 libc++abi.dylib 0x00007fff8f285a21 abort_message + 257 3 libc++abi.dylib 0x00007fff8f2ad9d1 default_terminate_handler() + 267 4 libobjc.A.dylib 0x00007fff89e2f6c6 _objc_terminate() + 103 5 libc++abi.dylib 0x00007fff8f2ab0a1 std::__terminate(void (*)()) + 8 6 libc++abi.dylib 0x00007fff8f2ab113 std::terminate() + 51 7 libobjc.A.dylib 0x00007fff89e2f4ef objc_terminate + 9 8 libdispatch.dylib 0x00007fff8583bc27 _dispatch_client_callout + 28 9 libdispatch.dylib 0x00007fff85847cbf _dispatch_main_queue_callback_4CF + 861 10 com.apple.CoreFoundation 0x00007fff8de43c59 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9 11 com.apple.CoreFoundation 0x00007fff8de002ef __CFRunLoopRun + 2159 12 com.apple.CoreFoundation 0x00007fff8ddff838 CFRunLoopRunSpecific + 296 13 com.apple.HIToolbox 0x00007fff900e543f RunCurrentEventLoopInMode + 235 14 com.apple.HIToolbox 0x00007fff900e51ba ReceiveNextEventCommon + 431 15 com.apple.HIToolbox 0x00007fff900e4ffb _BlockUntilNextEventMatchingListInModeWithFilter + 71 16 com.apple.AppKit 0x00007fff8beeb821 _DPSNextEvent + 964 17 com.apple.AppKit 0x00007fff8beeafd0 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 194 18 com.apple.AppKit 0x00007fff8bedef73 -[NSApplication run] + 594 19 com.apple.AppKit 0x00007fff8beca424 NSApplicationMain + 1832 20 libdyld.dylib 0x00007fff846455c9 start + 1  Thread 1:: Dispatch queue: com.apple.libdispatch-manager 0 libsystem_kernel.dylib 0x00007fff90e6f22e kevent64 + 10 1 libdispatch.dylib 0x00007fff8583ea6a _dispatch_mgr_thread + 52  Thread 2: 0 libsystem_kernel.dylib 0x00007fff90e6e946 __workq_kernreturn + 10 1 libsystem_pthread.dylib 0x00007fff87cae4a1 start_wqthread + 13  Thread 3: 0 libsystem_kernel.dylib 0x00007fff90e6e946 __workq_kernreturn + 10 1 libsystem_pthread.dylib 0x00007fff87cae4a1 start_wqthread + 13  Thread 4: 0 libsystem_kernel.dylib 0x00007fff90e6e946 __workq_kernreturn + 10 1 libsystem_pthread.dylib 0x00007fff87cae4a1 start_wqthread + 13  Thread 5: 0 libsystem_kernel.dylib 0x00007fff90e6e946 __workq_kernreturn + 10 1 libsystem_pthread.dylib 0x00007fff87cae4a1 start_wqthread + 13  Thread 6:: Dispatch queue: AK_buildFontFamilyMenuOperationQueue :: NSOperation 0x6000006427f0 (QOS: USER_INITIATED) 0 libsystem_kernel.dylib 0x00007fff90e6952e mach_msg_trap + 10 1 libsystem_kernel.dylib 0x00007fff90e6869f mach_msg + 55 2 libFontRegistry.dylib 0x00007fff911f84cc XTSendCopyPropertiesForFontsMatchingRequestSandboxed + 160 3 libFontRegistry.dylib 0x00007fff912065bb TGlobalFontRegistrySandboxedImp::CopyPropertiesForFontsMatchingRequest(__CFDictionary const*, __CFSet const*, TFontQueryOptions const&) const + 247 4 libFontRegistry.dylib 0x00007fff911e8c8c XTCopyFontsWithProperties + 161 5 com.apple.CoreText 0x00007fff8cca15a1 TDescriptorSource::CopyDescriptorsForRequest(__CFDictionary const*, __CFSet const*, CFComparisonResult (*)(void const*, void const*, void*), void*, unsigned long, TCFRef<__CFArray const*>*) const + 867 6 com.apple.CoreText 0x00007fff8cc4ecda TDescriptorSource::CopyDescriptorForRequest(__CFDictionary const*, __CFSet const*, CFComparisonResult (*)(void const*, void const*, void*), void*, unsigned long) const + 138 7 com.apple.CoreText 0x00007fff8cc23488 TDescriptor::CreateMatchingDescriptorInternal(__CFSet const*, bool) const + 600 8 com.apple.CoreText 0x00007fff8cc2311c TDescriptor::InitBaseFont(bool) + 38 9 com.apple.CoreText 0x00007fff8cc831e2 CTFontDescriptorsCopyAttributesInternal(__CFArray const*, __CFSet const*, unsigned int, bool) + 466 10 com.apple.CoreText 0x00007fff8cc82ff2 CTFontDescriptorsCopyAttribute + 70 11 com.apple.CoreText 0x00007fff8cc954de TCollection::CopyFontAttribute(__CFString const*, unsigned int) const + 40 12 com.apple.AnnotationKit 0x00000001016cdcb4 __54-[AKTextAttributesViewController _buildFontFamilyMenu]_block_invoke + 135 13 com.apple.Foundation 0x00007fff8b9a52e8 __NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__ + 7 14 com.apple.Foundation 0x00007fff8b891905 -[NSBlockOperation main] + 97 15 com.apple.Foundation 0x00007fff8b87059c -[__NSOperationInternal _start:] + 653 16 com.apple.Foundation 0x00007fff8b8701a3 __NSOQSchedule_f + 184 17 libdispatch.dylib 0x00007fff8583bc13 _dispatch_client_callout + 8 18 libdispatch.dylib 0x00007fff8583f365 _dispatch_queue_drain + 1100 19 libdispatch.dylib 0x00007fff85840ecc _dispatch_queue_invoke + 202 20 libdispatch.dylib 0x00007fff8583e6b7 _dispatch_root_queue_drain + 463 21 libdispatch.dylib 0x00007fff8584cfe4 _dispatch_worker_thread3 + 91 22 libsystem_pthread.dylib 0x00007fff87cb06cb _pthread_wqthread + 729 23 libsystem_pthread.dylib 0x00007fff87cae4a1 start_wqthread + 13  Thread 7 and so on 

Как подсказал @agtoever, я открыл Preview из Terminal и получил длинный журнал сбоя. Я думаю, что важная часть:

Preview[2676:410618] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSPlaceholderSet initWithObjects:count:]: attempt to insert nil object from objects[0]' 
3
Вы пытались удалить файлы ~ / Library / Preferences / com.apple.preview *? radex 9 лет назад 2
Похоже, что системная процедура выдает исключение и убивает приложение предварительного просмотра для этого. Иногда приложение предоставляет больше контекста об исключении, которое выдается при запуске приложения из терминала. Пожалуйста, откройте терминал и выполните предварительный просмотр оттуда (вероятно: `/ Applications / Preview.app / Contents / MacOS / Preview`) и добавьте любой соответствующий вывод к вашему вопросу. agtoever 9 лет назад 2
Вы также можете попытаться удалить `~ / Library / Containers / com.apple.Preview /`. user495470 9 лет назад 4

6 ответов на вопрос

8
Matt

I just had a similar problem and as mentioned in one of the comments deleting ~/Library/Containers/com.apple.Preview/ worked for me.

Это действительно комментарий, а не ** ответ ** на оригинальный вопрос. Чтобы критиковать или запрашивать разъяснения у автора, оставьте комментарий под его сообщением - вы всегда можете прокомментировать свои собственные сообщения, и как только у вас будет достаточно [репутации] (http://superuser.com/help/whats-reputation), вы будете быть в состоянии [комментировать любой пост] (http://superuser.com/help/privileges/comment). DavidPostill 9 лет назад 0
Я попробовал каждый ответ в этом вопросе, и только ваше решение решило его для меня. carlosdc 9 лет назад 0
Работал на меня тоже - спасибо. После установки бета-версии OSx El Capitan 10.11 я больше не мог открывать Preview - выполнение `rm -rf ~ / Library / Containers / com.apple.Preview / *` исправило это для меня. joensson 8 лет назад 0
3
ianolito

I was also having this crash with the same stack trace. It was caused by a font that I had removed from my system, which was also the last font I had used in Preview's annotation tool.

The workaround was to install the font again, open Preview, change the font in the annotation tool to a different one and then remove the font. Filed rdar://problem/20094667

2
agtoever

Судя по тому, что вы указали в вопросе и комментариях, приложение Preview было повреждено. Это иногда случается в очень редких случаях. Я думаю, что у вас есть два варианта с этого момента:

  1. Авантюрный маршрут: извлеките и переустановите Preview с установочной загрузки
  2. Возможно, впечатляющий маршрут: переустановите OSX

Я рекомендую сначала попробовать первый маршрут, а если не получится, попробуйте второй.

1. Авантюрный маршрут: извлеките и переустановите Preview с установочной загрузки

  • Загрузите и установите Pacifist, инструмент для извлечения программного обеспечения из установочных файлов OSX.
  • Получите установочный DVD-диск OSX или (если у вас его нет) загрузите OSX из App Store .
  • Используйте Pacifist для просмотра загруженного установочного образа OSX. Перейдите к: «Содержимое Essentials.pkg»> «Приложения»> «Preview.app» и щелкните, чтобы (пере) установить его.

2. Возможно, впечатляющий маршрут: переустановите OSX

  • Получите установочный DVD-диск OSX или (если у вас его нет) загрузите OSX из App Store .
  • Запустите установку (я не совсем уверен, работает ли это, если Yosemite уже установлен; я думаю, что все в порядке. Было бы хорошо, если бы кто-то мог подтвердить это!)
  • Когда ваш Mac перезагрузится во время установки, выберите опцию «Переустановить OSX».

Обратите внимание, что при использовании опции 2 ваши данные и настройки должны быть сохранены, но не зависят от них. Всегда делайте резервную копию ваших файлов и настроек перед обновлением вашей ОС.

1
Jay Bee

I was having this issue for a couple days and I started to really worry about by computer. After trying countless things to relieve the problem of text edit and preview crashing, I finally solved the issue with one simple fix.

What solved the problem was a simple SMC reset of my computer (Macbook Pro)

What I understand is that this temporarily takes power away from everything inside the computer so that when the computer turns back on all things have been restored to proper settings.

Follow the link below on instructions on how to do this, making sure you follow the instructions that apply to your model of computer.

Hope this helps!

http://support.apple.com/en-us/HT201295

1
bismark

Other similar threads around the web tipped me off that it may be related to fonts being missing or corrupted.

In my particular case, I had previously installed and subsequently removed Microsoft Office and it's associated fonts.

I reinstalled just Office's fonts and Preview started working again, even after once again removing the Office fonts.

1
Oliver Schmitt

I had the same problem, after remove the font set of Microsoft Office from my mac. The problem might be caused by conflicting font files, inhibiting Preview from starting up.

I fixed the problem by removing the folder in the Terminal with rm -rf ~/Library/Containers/com.apple.Preview/* and the fixing the fonts with the Font Book App, preinstalled on OSX. In the Font Book App, went through all grey (disabled) font entries and selected from the context menu "validate font" and "enable font". The Preview started up without problems.

See also here how to fix fonts on OSX: http://www.macissues.com/2014/04/18/how-to-troubleshoot-font-problems-in-os-x/