Bug 250484 - REGRESSION(258307@main) ASSERTION FAILED: scale == [webView->_scrollView zoomScale]
Summary: REGRESSION(258307@main) ASSERTION FAILED: scale == [webView->_scrollView zoom...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Tim Horton
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-01-11 15:22 PST by Robert Jenner
Modified: 2023-01-12 11:50 PST (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Jenner 2023-01-11 15:22:20 PST
The following 7 API-tests are crashing/hitting an assertion on iOS Debug:

TestWebKitAPI.AnimatedResize.ChangeFrameAndMinimumEffectiveDeviceWidthDuringAnimatedResize
TestWebKitAPI.AnimatedResize.OverrideLayoutSizeChangesDuringAnimatedResizeSucceed
TestWebKitAPI.AnimatedResize.ResizeWithContentHiddenCompletes
TestWebKitAPI.AnimatedResize.ResizeWithContentHiddenWithSubsequentNoOpResizeCompletes
TestWebKitAPI.AnimatedResize.AnimatedResizeBlocksDoAfterNextPresentationUpdate
TestWebKitAPI.AnimatedResize.AnimatedResizeBlocksViewportFitChanges
TestWebKitAPI.RestoreScrollPositionTests.RestoreScrollPositionDuringResize


HISTORY:
https://results.webkit.org/?suite=api-tests&suite=api-tests&suite=api-tests&suite=api-tests&suite=api-tests&suite=api-tests&suite=api-tests&test=TestWebKitAPI.AnimatedResize.ChangeFrameAndMinimumEffectiveDeviceWidthDuringAnimatedResize&test=TestWebKitAPI.AnimatedResize.OverrideLayoutSizeChangesDuringAnimatedResizeSucceed&test=TestWebKitAPI.AnimatedResize.ResizeWithContentHiddenCompletes&test=TestWebKitAPI.AnimatedResize.ResizeWithContentHiddenWithSubsequentNoOpResizeCompletes&test=TestWebKitAPI.AnimatedResize.AnimatedResizeBlocksDoAfterNextPresentationUpdate&test=TestWebKitAPI.AnimatedResize.AnimatedResizeBlocksViewportFitChanges&test=TestWebKitAPI.RestoreScrollPositionTests.RestoreScrollPositionDuringResize


Assertion/Crash TEXT:
        ASSERTION FAILED: scale == [webView->_scrollView zoomScale]
        /Volumes/Data/worker/Apple-iOS-16-Simulator-Debug-Build/build/Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm(567) : CGFloat contentZoomScale(WKWebView *)
        1   0x1152380d9 WTFCrash
        2   0x1349681cb WTFCrashWithInfo(int, char const*, char const*, int)
        3   0x135e31601 contentZoomScale(WKWebView*)
        4   0x135e47821 -[WKWebView(WKPrivateIOS) _beginAnimatedResizeWithUpdates:]
        5   0x103f334ac AnimatedResize_ChangeFrameAndMinimumEffectiveDeviceWidthDuringAnimatedResize_Test::TestBody()
        6   0x10493668b void testing::internal::HandleSehExceptionsInMethodIfSupported<testing::Test, void>(testing::Test*, void (testing::Test::*)(), char const*)
        7   0x10490d19a void testing::internal::HandleExceptionsInMethodIfSupported<testing::Test, void>(testing::Test*, void (testing::Test::*)(), char const*)
        8   0x10490d0e3 testing::Test::Run()
        9   0x10490e121 testing::TestInfo::Run()
        10  0x10490f1a4 testing::TestSuite::Run()
        11  0x10491d89c testing::internal::UnitTestImpl::RunAllTests()
        12  0x10493aa3b bool testing::internal::HandleSehExceptionsInMethodIfSupported<testing::internal::UnitTestImpl, bool>(testing::internal::UnitTestImpl*, bool (testing::internal::UnitTestImpl::*)(), char const*)
        13  0x10491d27a bool testing::internal::HandleExceptionsInMethodIfSupported<testing::internal::Uni
tTestImpl, bool>(testing::internal::UnitTestImpl*, bool (testing::internal::UnitTestImpl::*)(), char const*)
        14  0x10491d165 testing::UnitTest::Run()
        15  0x103f296d1 RUN_ALL_TESTS()
        16  0x103f29666 TestWebKitAPI::TestsController::run(int, char**)
        17  0x1048e12dc main
        18  0x1076902bf (null)
        19  0x11518352e (null)
        Child process terminated with signal 11: Segmentation fault

https://build.webkit.org/#/builders/663/builds/568/steps/18/logs/stdio



I was able to reproduce all of these assertions/crashes by running the test as follows:

run-api-tests <insert_test_name_here> 


I was able to reproduce the crash as far back as 258307@main, but all tests passed when ran at 258306@main. So it appears that 258307@main is our culprit.
Comment 1 Radar WebKit Bug Importer 2023-01-11 15:23:15 PST
<rdar://problem/104142370>
Comment 2 Tim Horton 2023-01-11 17:27:57 PST
Pull request: https://github.com/WebKit/WebKit/pull/8554
Comment 3 EWS 2023-01-12 11:50:47 PST
Committed 258842@main (80bba9e9dc19): <https://commits.webkit.org/258842@main>

Reviewed commits have been landed. Closing PR #8554 and removing active labels.