Skip to content

Refactor usfm fixer module#320

Merged
linearcombination merged 2 commits into
WycliffeAssociates:doc-dev.walink.orgfrom
linearcombination:improve-usfm-fix-module-organization
Jul 2, 2026
Merged

Refactor usfm fixer module#320
linearcombination merged 2 commits into
WycliffeAssociates:doc-dev.walink.orgfrom
linearcombination:improve-usfm-fix-module-organization

Conversation

@linearcombination

Copy link
Copy Markdown
Contributor

Better setup leading to leaner main logic

Better setup leading to leaner main logic

if (
not re.compile(r"""\\v \d+""").search(context_for_standalone_verse)
not compiled_patterns["fix_standalone_verse_numbers"].search(

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.

The new "fix_standalone_verse_numbers" pattern is very different than the old one:

not re.compile(r"""\\v \d+""").search(context_for_standalone_verse)

Is this intentional? It seems like it would have very different behavior.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Thanks, I will take a closer look just in case. AI guided refactor warning. All tests passed, but I will make sure that case is covered. Appreciate you checking.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Ok, I relaxed a few changes to retain the original intent. Ready for re-review

Restore a couple search regex patterns from prior version
@linearcombination linearcombination merged commit 21f7cfa into WycliffeAssociates:doc-dev.walink.org Jul 2, 2026
8 checks passed
@github-project-automation github-project-automation Bot moved this from In progress to Done in DOC Project Management Jul 2, 2026
@linearcombination linearcombination deleted the improve-usfm-fix-module-organization branch July 2, 2026 22:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

2 participants