{"id":19512,"date":"2017-11-13T18:30:16","date_gmt":"2017-11-13T23:30:16","guid":{"rendered":"https:\/\/mjtsai.com\/blog\/?p=19512"},"modified":"2017-11-15T16:14:51","modified_gmt":"2017-11-15T21:14:51","slug":"app-nap-automatic-termination-and-zombies-apps","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2017\/11\/13\/app-nap-automatic-termination-and-zombies-apps\/","title":{"rendered":"App Nap, Automatic Termination, and Zombie Apps"},"content":{"rendered":"<p><a href=\"https:\/\/eclecticlight.co\/2017\/11\/06\/did-that-app-quit-or-is-it-just-napping\/\">Howard Oakley<\/a>:<\/p>\n<blockquote cite=\"https:\/\/eclecticlight.co\/2017\/11\/06\/did-that-app-quit-or-is-it-just-napping\/\">\n<p>More recently, Apple&rsquo;s apps have started to behave differently. Support tools like TextEdit and Preview enter this [zombie state] instead of quitting automatically, when they go into App Nap without an open document. You can observe this by starting them up and leaving then to go into the background without any open documents.<\/p>\n<p>With a longer list of apps open and in the background, most of them now go into App Nap, as shown in Activity Monitor.<\/p>\n<p>Bring up the Force Quit dialog using Command-Option-Escape, and you&rsquo;ll see that they are still listed there as running.<\/p>\n<p>Look at their icons in the Dock, though, and the normal black dot has vanished, as if the app has actually quit.<\/p>\n<p>They&rsquo;re also missing from the list of open apps in the App Switcher (Command-Tab).<\/p>\n<p>[&#8230;]<\/p>\n<p>macOS has therefore gone from having two basic states for apps, to four[&#8230;]<\/p>\n<\/blockquote>\n\n<p><a href=\"https:\/\/eclecticlight.co\/2017\/11\/08\/how-to-prevent-zombies\/\">Howard Oakley<\/a>:<\/p>\n<blockquote cite=\"https:\/\/eclecticlight.co\/2017\/11\/08\/how-to-prevent-zombies\/\">\n<p>To prevent all apps from becoming zombies, simply type the following into Terminal:<\/p>\n<pre>defaults write -g NSDisableAutomaticTermination -bool TRUE<\/pre>\n<p>When you next open an app like Preview, if you leave it unattended in the background with no open windows, it will just sit there, and won&rsquo;t quit or become a zombie.<\/p>\n<\/blockquote>\n\n<p><a href=\"https:\/\/eclecticlight.co\/2017\/11\/12\/last-week-on-my-mac-brilliant-but\/\">Howard Oakley<\/a>:<\/p>\n<blockquote cite=\"https:\/\/eclecticlight.co\/2017\/11\/12\/last-week-on-my-mac-brilliant-but\/\">\n<p>This zombie state is possibly the most complete antithesis of all good human design. The app is still there, but the user can&rsquo;t directly use or quit it. The only two ways of regaining control over it are to open a document which by default will be opened by that app, or to act as if opening the app again. As zombies are removed from the Dock, App Switcher, etc., the latter is often very inconvenient.<\/p>\n<p>[&#8230;]<\/p>\n<p>This sort of behaviour is probably most tolerable when it occurs in such one-shot viewer utilities. But when it becomes standard in major productivity apps like Pages, Numbers, and Xcode, you have to ask why macOS is being so deliberately deceptive of the user. As Apple glosses over the matter in a couple of terse lines, and then only in its developer documentation, we&rsquo;ll never know its design intent.<\/p>\n<\/blockquote>\n\n<p>Update (2017-11-15): <a href=\"https:\/\/eclecticlight.co\/2017\/11\/15\/undead-apps-and-opting-out-of-app-nap\/\">Howard Oakley<\/a>:<\/p>\n<blockquote cite=\"https:\/\/eclecticlight.co\/2017\/11\/15\/undead-apps-and-opting-out-of-app-nap\/\">\n<p>In the absence of anything better, I suggest that they are termed <em>undead<\/em> apps, which has no other meaning in this context, and should therefore be unambiguous. It also seems a good description as to what they are. And despite my previous assertion, it appears that they can only exist for any length of time in App Nap. Indeed, as I show here, all apps running under macOS Sierra and High Sierra are eligible for App Nap, irrespective of custom settings in their Info.plist file.<\/p>\n<\/blockquote>","protected":false},"excerpt":{"rendered":"<p>Howard Oakley: More recently, Apple&rsquo;s apps have started to behave differently. Support tools like TextEdit and Preview enter this [zombie state] instead of quitting automatically, when they go into App Nap without an open document. You can observe this by starting them up and leaving then to go into the background without any open documents. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"apple_news_api_created_at":"","apple_news_api_id":"","apple_news_api_modified_at":"","apple_news_api_revision":"","apple_news_api_share_url":"","apple_news_coverimage":0,"apple_news_coverimage_caption":"","apple_news_is_hidden":false,"apple_news_is_paid":false,"apple_news_is_preview":false,"apple_news_is_sponsored":false,"apple_news_maturity_rating":"","apple_news_metadata":"\"\"","apple_news_pullquote":"","apple_news_pullquote_position":"","apple_news_slug":"","apple_news_sections":"\"\"","apple_news_suppress_video_url":false,"apple_news_use_image_component":false,"footnotes":""},"categories":[2],"tags":[649,30,1529],"class_list":["post-19512","post","type-post","status-publish","format-standard","hentry","category-technology","tag-esoteric-preferences","tag-mac","tag-macos-10-13"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/19512","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/comments?post=19512"}],"version-history":[{"count":3,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/19512\/revisions"}],"predecessor-version":[{"id":19523,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/19512\/revisions\/19523"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=19512"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=19512"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=19512"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}