Skip to content

Fix Skip Already Transcribed for file names with square brackets - #1659

Merged
raivisdejus merged 3 commits into
chidiwilliams:mainfrom
Dev-next-gen:fix/skip-transcribed-glob-escape
Oct 17, 2026
Merged

raivisdejus merged 3 commits into
chidiwilliams:mainfrom
Dev-next-gen:fix/skip-transcribed-glob-escape

Conversation

@Dev-next-gen

Copy link
Copy Markdown
Contributor

With the Skip Already Transcribed plugin enabled, a media file whose name contains glob characters is never skipped. Interview [Part 1].mp3 sits next to the result Buzz wrote for it, Interview [Part 1] (transcribed on 14-Oct-2026 13-02-51).srt, and the file is transcribed again.

_find_result_file_segments builds the pattern f"{stem}*.{fmt.value}" from the raw file name, so Path.glob reads [Part 1] as a character class matching a single character and the result file does not match. Square brackets are common in downloaded media names. The fix passes the stem through glob.escape.

I reproduced it through the real naming and writing path: get_output_file_path with the default template plus write_output produced the .srt above, and check_skip returned None. With the fix it returns the segment. The added test test_sat_skips_on_srt_file_with_brackets_in_name fails before the change and passes after, along with the other sat_ tests.

Found by a defect-hunting pipeline I build and run (Dev-next-gen), using Claude Code with Anthropic's Claude Opus 5.5.

Dev-next-gen and others added 3 commits October 14, 2026 13:03
A media file whose name contains glob characters, for example
"Interview [Part 1].mp3", never matched its own result file because
Path.glob read "[Part 1]" as a character class, so the file was
transcribed again.
@raivisdejus
raivisdejus enabled auto-merge (squash) October 17, 2026 07:33
@codecov

codecov Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.88%. Comparing base (f1b943c) to head (d69ce1f).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1659   +/-   ##
=======================================
  Coverage   83.88%   83.88%           
=======================================
  Files         115      115           
  Lines       13831    13834    +3     
=======================================
+ Hits        11602    11605    +3     
  Misses       2229     2229           
Flag Coverage Δ
Linux 83.15% <100.00%> (+0.02%) ⬆️
macOS 83.38% <100.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@raivisdejus
raivisdejus merged commit 053b388 into chidiwilliams:main Oct 17, 2026
15 of 16 checks passed
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