Skip to content

🐛 fix(segment-filters): fixed repetition segment filters query#4621

Open
mauretto78 wants to merge 1 commit into
developfrom
fix-repetition-filters
Open

🐛 fix(segment-filters): fixed repetition segment filters query#4621
mauretto78 wants to merge 1 commit into
developfrom
fix-repetition-filters

Conversation

@mauretto78

@mauretto78 mauretto78 commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

Summary

Avoid segment extraction errors overlapping

Type

  • fix — bug fix

Changes

File Change
lib/Plugins/Features/SegmentFilter/Model/SegmentFilterDao.php fixed repetition segment filters query

Testing

  • vendor/bin/phpunit --exclude-group=ExternalServices --no-coverage passes

AI Disclosure

  • AI tools were used — name the agent/tool below

GitHub Copilot (Claude)


Copilot AI review requested due to automatic review settings June 11, 2026 11:20

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR adjusts the SQL used by the SegmentFilter feature to correctly qualify the segment_hash column in the repetition filter subquery, aiming to prevent segment-extraction/filtering issues caused by ambiguous or overlapping query behavior.

Changes:

  • Qualifies segment_hash references in the repetition filter’s GROUP BY/HAVING clause (st.segment_hash) to align with the table alias used in the subquery.

Comment on lines +292 to +293
GROUP BY st.segment_hash, CONCAT( id_job, '-', password )
HAVING COUNT( st.segment_hash ) > 1
@github-actions

Copy link
Copy Markdown

🧪 Test-Guard Report

❌ FAIL — Some changed source files lack adequate test coverage.

Coverage Analysis: ❌ FAIL

No changed source files found in coverage report (threshold: 80%)

📋 1 files: 1 ❌ fail
File Verdict Reason
lib/Plugins/Features/SegmentFilter/Model/SegmentFilterDao.php ❌ fail not in coverage report

Test File Matching: ⚠️ WARNING

File matching: 1 warning

📋 1 files: 1 ⚠️ warning
File Verdict Reason
lib/Plugins/Features/SegmentFilter/Model/SegmentFilterDao.php ⚠️ warning Test file exists (tests/unit/Core/DAO/TestSegmentFilterDAO/SegmentFilterDaoTest.php) but was not modified in this PR

Per-File Evaluation: ❌ FAIL

All files resolved by deterministic shortcuts.

📋 1 files: 1 ❌ fail
File Verdict Reason
lib/Plugins/Features/SegmentFilter/Model/SegmentFilterDao.php ❌ fail shortcut → no relevant tests in PR and no/low coverage

Result: ❌ FAIL


Why this FAIL?

  • Coverage Analysis: lib/Plugins/Features/SegmentFilter/Model/SegmentFilterDao.php was not included in the coverage report, indicating a coverage configuration issue → adjust coverage instrumentation or filters to include this file.
  • Test File Matching: The existing test file tests/unit/Core/DAO/TestSegmentFilterDAO/SegmentFilterDaoTest.php was not modified in this PR → no action needed, but adding or updating tests could improve coverage.
  • Per-File Evaluation: No relevant tests were changed or added for SegmentFilterDao.php, and coverage is missing → add or update tests to cover the changes.

To resolve: update or add tests for lib/Plugins/Features/SegmentFilter/Model/SegmentFilterDao.php and ensure coverage configuration includes this file.

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