Bug 203549

Summary: REGRESSION (r251413): Nightly build crashes on launch due to -[WKPreferences _setShouldAllowDesignSystemUIFonts:]: unrecognized selector
Product: WebKit Reporter: mitz
Component: WebKit2Assignee: Myles C. Maxfield <mmaxfield>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, dino, jonlee, mitz, mmaxfield, simon.fraser, thorton, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Local Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=203129
Attachments:
Description Flags
Patch none

Description mitz 2019-10-28 20:56:24 PDT
r251413, the change made for bug 203129, removed a method used by the current version of Safari (version 13.0.2 (13608.2.40.1.3)), causing nightly builds to crash on launch:

2019-10-28 20:50:07.640 SafariForWebKitDevelopment[67089:31260958] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[WKPreferences _setShouldAllowDesignSystemUIFonts:]: unrecognized selector sent to instance 0x7fb3b7649220'
*** First throw call stack:
(
	0   CoreFoundation                      0x00007fff4dc76e0b __exceptionPreprocess + 171
	1   libobjc.A.dylib                     0x00007fff753b0c76 objc_exception_throw + 48
	2   CoreFoundation                      0x00007fff4dd0f964 -[NSObject(NSObject) doesNotRecognizeSelector:] + 132
	3   CoreFoundation                      0x00007fff4dbec6f0 ___forwarding___ + 1456
	4   CoreFoundation                      0x00007fff4dbec0b8 _CF_forwarding_prep_0 + 120
	5   Safari                              0x000000010c10ea15 -[WebKitPreferencesManager _initializeReaderPageGroupPreferencesManager] + 69
	6   Safari                              0x000000010c10c424 -[WebKitPreferencesManager _initWithPreferencesType:] + 291
	7   Safari                              0x000000010c10bb0a __61+[WebKitPreferencesManager readerPageGroupPreferencesManager]_block_invoke + 46
	8   libdispatch.dylib                   0x00007fff75f90db8 _dispatch_client_callout + 8
	9   libdispatch.dylib                   0x00007fff75f90d6b dispatch_once_f + 41
	10  Safari                              0x000000010c10bad9 +[WebKitPreferencesManager readerPageGroupPreferencesManager] + 45
	11  Safari                              0x000000010c26cae4 ___ZN6Safari16ReaderController15readerPageGroupEv_block_invoke + 48
Comment 1 mitz 2019-10-28 21:08:43 PDT
<rdar://problem/56696055>
Comment 2 Myles C. Maxfield 2019-10-29 09:43:28 PDT
*** Bug 203570 has been marked as a duplicate of this bug. ***
Comment 3 Myles C. Maxfield 2019-10-29 09:44:11 PDT
Created attachment 382189 [details]
Patch
Comment 4 mitz 2019-10-29 09:49:46 PDT
Comment on attachment 382189 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=382189&action=review

> Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h:129
> +@property (nonatomic, setter=_setShouldAllowDesignSystemUIFonts:) BOOL _shouldAllowDesignSystemUIFonts WK_API_AVAILABLE(macos(WK_MAC_TBA), ios(WK_IOS_TBA));

This declaration isn’t necessary.
Comment 5 WebKit Commit Bot 2019-10-29 13:58:53 PDT
Comment on attachment 382189 [details]
Patch

Clearing flags on attachment: 382189

Committed r251732: <https://trac.webkit.org/changeset/251732>
Comment 6 WebKit Commit Bot 2019-10-29 13:58:55 PDT
All reviewed patches have been landed.  Closing bug.