mansipp opened a new pull request, #18238:
URL: https://github.com/apache/hudi/pull/18238

   ### Describe the issue this Pull Request addresses
   
   Closes https://issues.apache.org/jira/browse/HUDI-8304
   
   Developers often leave TODO comments in code with JIRA issue IDs (e.g., `// 
TODO HUDI-8304 implement this later`). When the PR for that issue is merged, 
these TODOs should be removed but are frequently forgotten, leaving stale 
references in the codebase. This PR adds automated validation to prevent this.
   
   ### Summary and Changelog
   
   **Summary:**
   Add GitHub Actions workflow that extracts the JIRA issue ID from PR titles 
and searches the codebase to ensure no TODO/FIXME/XXX comments reference that 
issue. This prevents merging PRs with unresolved TODO items.
   
   **Changelog:**
   * Add new workflow `.github/workflows/pr_todo_validation.yml`
   * Extract JIRA ID from PR title format `[HUDI-XXXX]` using regex
   * Search codebase for TODO/FIXME/XXX comments containing the JIRA ID
   * Fail PR check if any matching TODOs are found
   * Support common file types: `.java`, `.scala`, `.py`, `.js`, `.ts`
   * Exclude build directories (`.git`, `target`, `build`, `node_modules`) to 
avoid false positives
   * Skip validation for PRs without JIRA ID in title (e.g., `[MINOR]` PRs)
   
   **Workflow behavior:**
   - Triggers on PR events: opened, edited, reopened, synchronize
   - Targets `master` and `branch-0.x` branches
   - Uses concurrency control to cancel outdated runs
   - Provides clear error messages when TODOs are detected
   
   ### Impact
   
   **Public API Changes:**
   None.
   
   **User-Facing Changes:**
   Contributors will receive automated feedback if their PR contains TODO 
comments referencing the issue being fixed. This improves code quality by 
ensuring work is complete before merge.
   
   **Performance Impact:**
   None. Workflow runs in parallel with other CI checks and completes in 
seconds.
   
   ### Risk Level
   
   **Risk Level: none**
   
   This is a new CI validation workflow that only affects PR checks. It does 
not modify any production code or deployment processes.
   
   ### Documentation Update
   
   No documentation changes needed. The workflow is self-documenting with clear 
step names and inline comments.
   
   ### Contributor's checklist
   
   - [x] Read through [contributor's 
guide](https://hudi.apache.org/contribute/how-to-contribute)
   - [x] Enough context is provided in the sections above
   - [x] Adequate tests were added if applicable
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to