Skip to content

Comments

fix: Resolve SDK crash caused by UIPrintPanelViewController incorrectly casting to UISplitViewController#6771

Merged
itaybre merged 4 commits intov8.xfrom
philprime/uiprintpanel-sdk-crash
Nov 13, 2025
Merged

fix: Resolve SDK crash caused by UIPrintPanelViewController incorrectly casting to UISplitViewController#6771
itaybre merged 4 commits intov8.xfrom
philprime/uiprintpanel-sdk-crash

Conversation

@philprime
Copy link
Member

📜 Description

The internal class of UIPrintPanelViewController seems to override the isKindOfClass: method, therefore wrongfully casting to a UISplitViewController on iOS 26+.

This PR checks if the instance actually responds to viewControllers to resolve the error.

💡 Motivation and Context

See #6725 for full investigation information

Closes #6725

@codecov
Copy link

codecov bot commented Nov 13, 2025

Codecov Report

❌ Patch coverage is 0% with 10 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.050%. Comparing base (40ef20e) to head (01c2b4e).
⚠️ Report is 1 commits behind head on v8.x.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
...ces/Swift/Helper/SentryApplicationExtensions.swift 0.000% 10 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@              Coverage Diff              @@
##              v8.x     #6771       +/-   ##
=============================================
- Coverage   86.118%   86.050%   -0.068%     
=============================================
  Files          441       441               
  Lines        27591     27600        +9     
  Branches     11958     11959        +1     
=============================================
- Hits         23761     23750       -11     
- Misses        3786      3806       +20     
  Partials        44        44               
Files with missing lines Coverage Δ
...ces/Swift/Helper/SentryApplicationExtensions.swift 18.181% <0.000%> (-1.819%) ⬇️

... and 4 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 40ef20e...01c2b4e. Read the comment docs.

Copy link
Contributor

@itaybre itaybre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@itaybre itaybre enabled auto-merge (squash) November 13, 2025 19:46
@github-actions
Copy link
Contributor

Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1226.69 ms 1240.42 ms 13.73 ms
Size 24.14 KiB 1001.33 KiB 977.18 KiB

Baseline results on branch: v8.x

Startup times

Revision Plain With Sentry Diff
c21a31f 1237.04 ms 1256.65 ms 19.61 ms
653de7c 1205.02 ms 1222.20 ms 17.18 ms
3af1ae9 1225.60 ms 1252.65 ms 27.05 ms
41834f1 1235.15 ms 1256.31 ms 21.17 ms
5e3fb04 1239.84 ms 1267.39 ms 27.55 ms
b66be9b 1218.22 ms 1244.19 ms 25.96 ms
5fce94f 1226.31 ms 1246.82 ms 20.50 ms
c21a31f 1216.02 ms 1236.34 ms 20.32 ms
237dfb1 1214.90 ms 1258.63 ms 43.73 ms
f76f6bf 1207.70 ms 1233.27 ms 25.57 ms

App size

Revision Plain With Sentry Diff
c21a31f 23.75 KiB 1000.77 KiB 977.02 KiB
653de7c 23.75 KiB 992.25 KiB 968.50 KiB
3af1ae9 23.74 KiB 981.29 KiB 957.55 KiB
41834f1 23.75 KiB 991.88 KiB 968.13 KiB
5e3fb04 23.74 KiB 981.30 KiB 957.56 KiB
b66be9b 23.75 KiB 996.03 KiB 972.28 KiB
5fce94f 23.75 KiB 991.62 KiB 967.87 KiB
c21a31f 23.75 KiB 1000.80 KiB 977.05 KiB
237dfb1 23.75 KiB 1000.79 KiB 977.04 KiB
f76f6bf 23.74 KiB 981.30 KiB 957.56 KiB

@itaybre itaybre merged commit 33c9619 into v8.x Nov 13, 2025
245 of 262 checks passed
@itaybre itaybre deleted the philprime/uiprintpanel-sdk-crash branch November 13, 2025 20:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants