Skip to content

Split Java Access Bridge calls to fix NVDA crashes when selecting whole text in specific source files in Android studio#17604

Merged
SaschaCowley merged 7 commits into
nvaccess:masterfrom
thgcode:fix/java-access-bridge-crash
Jan 20, 2025
Merged

Split Java Access Bridge calls to fix NVDA crashes when selecting whole text in specific source files in Android studio#17604
SaschaCowley merged 7 commits into
nvaccess:masterfrom
thgcode:fix/java-access-bridge-crash

Conversation

@thgcode

@thgcode thgcode commented Jan 10, 2025

Copy link
Copy Markdown
Contributor

Link to issue number:

fixes #17418

Summary of the issue:

Nvda crashes when selecting whole text in specific source files in Android Studio and IntelliJ Idea

Description of user facing changes

NVDA should no longer crash.

Description of development approach

Java Access Bridge has a buffer limit of 10240 characters for the text. If the text is too large to fit on this buffer size, NVDA will split the calls to take the buffer size in account.

Testing strategy:

Tested with IntelliJ idea and the file provided on the issue.

Known issues with pull request:

No known issues were identified.

Code Review Checklist:

  • Documentation:
    • Change log entry
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English
  • API is compatible with existing add-ons.
  • Security precautions taken.

@coderabbitai summary

@AppVeyorBot

Copy link
Copy Markdown

See test results for failed build of commit c545bb5896

Summary of the issue:
Nvda crashes when selecting whole text in specific source files in Android Studio and IntelliJ Idea

Description of user facing changes
NVDA should no longer crash.

Description of development approach
Java Access Bridge has a buffer limit of 10240 characters for the text. If the text is too large to fit on this buffer size, NVDA will split the calls to take the buffer size in account.
@thgcode thgcode force-pushed the fix/java-access-bridge-crash branch from 5341d7e to 6973d4d Compare January 10, 2025 01:11
@thgcode thgcode marked this pull request as ready for review January 10, 2025 09:34

@SaschaCowley SaschaCowley left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Just a couple of small requests and questions

Comment thread source/JABHandler.py Outdated
Comment thread source/JABHandler.py Outdated
Comment thread source/JABHandler.py Outdated
Comment thread source/JABHandler.py Outdated
Comment thread user_docs/en/changes.md Outdated
thgcode and others added 2 commits January 13, 2025 19:36
Co-authored-by: Sascha Cowley <16543535+SaschaCowley@users.noreply.github.com>
@seanbudd seanbudd added the conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review. label Jan 13, 2025
@thgcode thgcode requested a review from SaschaCowley January 14, 2025 10:21
Comment thread source/JABHandler.py Outdated
Comment thread source/JABHandler.py Outdated
Comment thread source/JABHandler.py Outdated
Comment thread source/JABHandler.py Outdated
thgcode and others added 4 commits January 15, 2025 07:22
Co-authored-by: Sascha Cowley <16543535+SaschaCowley@users.noreply.github.com>
Co-authored-by: Sascha Cowley <16543535+SaschaCowley@users.noreply.github.com>
@thgcode thgcode requested a review from SaschaCowley January 15, 2025 10:37
@SaschaCowley SaschaCowley merged commit 0be66d5 into nvaccess:master Jan 20, 2025
@github-actions github-actions Bot added this to the 2025.1 milestone Jan 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Nvda crashes when selecting whole text in specific source files in Android studio

4 participants