Visitar URL original
Remove SLEEP status update from Regexp matches by headius · Pull Request #9948 · jruby/jruby · GitHub
Skip to content

Remove SLEEP status update from Regexp matches - #9948

Merged
headius merged 2 commits into
jruby:masterfrom
headius:regexp_no_sleep
Oct 29, 2026
Merged

headius merged 2 commits into
jruby:masterfrom
headius:regexp_no_sleep

Conversation

@headius

@headius headius commented Oct 29, 2026

Copy link
Copy Markdown
Member

This relates to #9944 which fixed a spurious test fail by avoiding "sleeping" Regexp matches while signal-handling. This PR fixes the root problem by removing the SLEEP status update during Regexp matching.

CRuby does not set SLEEP status when entering an interruptible Regexp match. Specs are provided to ensure that the status is RUN on CRuby and JRuby.

See #9944 for historic details about how this unintended status update persisted through many JRuby versions.

This relates to jruby#9944 which fixed a spurious test fail
by avoiding "sleeping" Regexp matches while signal-handling. This
PR fixes the root problem by removing the SLEEP status update
during Regexp matching.

CRuby does not set SLEEP status when entering an interruptible
Regexp match. Specs are provided to ensure that the status is RUN
on CRuby and JRuby.

See jruby#9944 for historic details about how this unintended
status update persisted through many JRuby versions.
This adds a few simple specs for the behavior of interruptible
Regexp matches, as well as a check that the current thread status
remains "run" rather than "sleep" as some blocking operations use.
@headius headius added this to the JRuby 10.1.3.0 milestone Oct 29, 2026
@headius
headius merged commit 2916dda into jruby:master Oct 29, 2026
143 checks passed
@headius
headius deleted the regexp_no_sleep branch October 29, 2026 10:59
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.

1 participant