Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent autofill prompt crash for edge case where a context menu is also visible on screen #3417

Merged
merged 3 commits into from
Oct 14, 2024

Conversation

amddg44
Copy link
Contributor

@amddg44 amddg44 commented Oct 7, 2024

Task/Issue URL: https://app.asana.com/0/414709148257752/1208361080593409/f
Tech Design URL:
CC:

Description:
Fixes a potential crash that is triggered when dismissing the password generation prompt fails where a context menu is also present, requiring a subsequent attempt which results in crashing on: NSInternalInconsistencyException: replyHandler passed to userContentController:didReceiveScriptMessage:replyHandler: should not be called twice

Steps to test this PR:

  1. Go to https://amddg44.github.io/registration-form/ (I’ve spun up this webpage to make it easier to trigger the original edge case report)
  2. Tap into the Username field, then the Password field so that the password generation prompt appears
  3. The webpage will programmatically focus on the Title field every 10 seconds, so wait until the “Select your title” context menu appears over the password generation prompt
  4. Select either option from the password generation prompt and confirm the prompt dismisses correctly (along with the context menu), with no second attempt needed (and therefore no crash)

<!—
Before submitting a PR, please ensure you have tested the combinations you expect the reviewer to test, then delete configurations you know do not need explicit testing.

Using a simulator where a physical device is unavailable is acceptable.
—>

Definition of Done (Internal Only):

Copy Testing:

  • Use of correct apostrophes in new copy, ie rather than

Orientation Testing:

  • Portrait
  • Landscape

Device Testing:

  • iPhone SE (1st Gen)
  • iPhone 8
  • iPhone X
  • iPhone 14 Pro
  • iPad

OS Testing:

  • iOS 15
  • iOS 16
  • iOS 17

Theme Testing:

  • Light theme
  • Dark theme

Internal references:

Software Engineering Expectations
Technical Design Template

@amddg44 amddg44 requested a review from graeme October 7, 2024 20:31
@amddg44 amddg44 merged commit 09e542c into main Oct 14, 2024
31 checks passed
@amddg44 amddg44 deleted the anya/prompt-menu-crash branch October 14, 2024 09:51
samsymons added a commit that referenced this pull request Oct 14, 2024
* main:
  Release 7.141.0-0 (#3435)
  Add error handling to contrainer removal (#3424)
  Prevent autofill prompt crash for edge case where a context menu is also visible on screen (#3417)
samsymons added a commit that referenced this pull request Oct 21, 2024
# By Daniel Bernal (4) and others
# Via Daniel Bernal (1) and others
* main:
  Pixel retrying (#3358)
  Remove `voiceSearchHelper` from `AppDependencyProvider` (#3452)
  Update AutoClearSettingsViewController to use DI for app settings (#3448)
  Bump BSK (#3441)
  Remove `SubscriptionFeatureAvailability` from `AppDependencyProvider` (#3447)
  Release 7.141.0-2 (#3451)
  Do not notify the FE on experiment activation (#3450)
  point to bsk branch (#3444)
  bump bsk for content blocker rules fix (#3445)
  speculative fix for set bars visibility crashes (#3442)
  Release 7.141.0-1 (#3443)
  Fix browsing menu bottom offset when bar location set to bottom (#3440)
  Properly handle responses that should trigger download action (#3407)
  Add Events Firing for Phishing Detection Settings: Point to BSK (#3423)
  DuckPlayer: Temporary Fix for Watch In Youtube (#3437)
  Add 'Open in New Tab' support for DuckPlayer (#3431)
  update BSK dependency (#3434)
  Release 7.141.0-0 (#3435)
  Add error handling to contrainer removal (#3424)
  Prevent autofill prompt crash for edge case where a context menu is also visible on screen (#3417)

# Conflicts:
#	DuckDuckGo.xcodeproj/project.pbxproj
#	DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved
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