Skip to content

Fix parsing for .properties files with - in path#975

Merged
dandavison merged 1 commit intodandavison:masterfrom
jdpopkin:fix_hyphen_path
Feb 19, 2022
Merged

Fix parsing for .properties files with - in path#975
dandavison merged 1 commit intodandavison:masterfrom
jdpopkin:fix_hyphen_path

Conversation

@jdpopkin
Copy link
Contributor

This adds a test that repros the problem in #974 and fixes it, at least for this specific filetype. The fix just involves changing the maximum file extension length for one of the regexes. The same problem would still happen to files with longer extensions.

There's probably a small tradeoff between performance and file extension length, and there will probably always be someone out there who wants to use even longer file extensions. But I think .properties is worth supporting - it's a common enough filetype to have its own Wikipedia article.

@dandavison
Copy link
Owner

Thanks @jdpopkin! I agree this should be fixed and your solution LGTM. I'll merge when the tests pass.

@dandavison dandavison merged commit 10ff766 into dandavison:master Feb 19, 2022
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