Cleanup: restore the interrupt flag in AiFailureAnalyzer

オープン 初心者向け
#258 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@Rishankgupta08 がすでに取り組んでいます。

2026年11月14日 から。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
82/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
java
領域
testing

調査の方向性

src/main/java/com/seleniumboot/ai/AiFailureAnalyzer.java を開き、指定された117行目と219行目の2箇所から始めてください。InterruptedException を握りつぶしている catch ブロックを見つけ、それぞれで既存の処理の前に Thread.currentThread().interrupt() を呼び出します。複数の例外をまとめて catch している場合は、InterruptedException 専用の catch を分けてください。両方の箇所で割り込みフラグが復元され、それ以外の動作は変わらず、mvn test が成功し、変更がこのパッケージ内に収まっていれば完了です。

索引モデルが issue の本文から書いたものです。

説明

good first issue

Part of the cleanup cycle from #251. SonarCloud rule java:S2142 flags these spots.

These places catch InterruptedException (often inside catch (Exception e)) and carry on without restoring the thread's interrupt flag. Anything further up that checks Thread.interrupted() (a parallel runner shutting down, a timeout) never sees the interrupt.

Where (line numbers as of master 2a07bba):

  • src/main/java/com/seleniumboot/ai/AiFailureAnalyzer.java: lines 117, 219

Fix: restore the flag and keep the existing behaviour. For a combined catch, split it out:

} catch (InterruptedException e) {
    Thread.currentThread().interrupt();
    // then the same handling the old catch did (log / wrap / return)
} catch (Exception e) {
    ...
}

Done when: the listed spots restore the interrupt flag, the behaviour is otherwise unchanged, and mvn test passes. Keep this PR to this package. SonarCloud reruns on the PR.

主要言語
Java
スター
12
フォーク
6
平均マージ
10時間
マージ済み PR(30日)
76

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

seleniumboot/selenium-boot のほかの issue

seleniumboot/selenium-boot の issue をすべて見る

似ている issue

Java の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。