There might be a mismatch in prefix keys between two WebPreferences instances. Instance (1) is made by lazy initialization of WKWebViewConfiguration's WebPreferences, using prefix of "WebKit" (WKPreferences:init) Instance (2) is made by the inspector WKWebView's WebPageGroup, using prefix of ".WebKit2" (WebPageGroup::WebPageGroup). Both instances appear to read from NSUserDefaults. We manually set DeveloperExtrasEnabled on instance (1) before calling WKWebView:initWithFrame and that has the intended effect, so this instance is probably the one to worry about. When stepping through WebPreferences::platformInitialize(), it seems that the if (!m_identifier) test fails, so only the debug preferences (enumerated by FOR_EACH_WEBKIT_DEBUG_PREFERENCE) are populated from user defaults.
<rdar://problem/19751830>
Created attachment 246233 [details] Patch
Updated instructions at <https://trac.webkit.org/wiki/HackingWebInspector> to reflect new keys. However, we probably need to move the LogsPageMessagesToSystemConsoleEnabled key to the DEBUG group as well.
Comment on attachment 246233 [details] Patch Clearing flags on attachment: 246233 Committed r179828: <http://trac.webkit.org/changeset/179828>
All reviewed patches have been landed. Closing bug.