Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timestamp rule matches filenames too broadly, leading to exceptions caused by unparsable timestamps #24

Open
kocmana opened this issue Jan 20, 2022 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@kocmana
Copy link
Owner

kocmana commented Jan 20, 2022

Arguments:

-i "IMG_<<TS|yyyyMMdd_HHmmss>>.jpg" -o "<<TS|yyyyMMdd_HHmmss>>.jpg" -p ".\testfiles" -cp

File names matched:

.\testfiles\IMG_20210726_152901.jpg
.\testfiles\IMG_20210726_152902.jpg
.\testfiles\IMG_20210726_152902__01.jpg
.\testfiles\IMG_20210726_152909.jpg
.\testfiles\IMG_20210726_154326.jpg
.\testfiles\IMG_20210726_154330.jpg
.\testfiles\IMG_211946.jpg
.\testfiles\IMG_211948.jpg
.\testfiles\IMG_211951.jpg
.\testfiles\IMG_211954.jpg

Resulting Exception:

21:19:45:923 a.k.f.s.FileRenameTask [ForkJoinPool.commonPool-worker-1] ERROR - Could not finish task with arguments: CommandLineArguments[path=.\testfiles, recursive=false, inputTemplate=IMG_<<TS|yyyyMMdd_HHmmss>>.jpg, outputTemplate=<<TS|yyyyMMdd_HHmmss>>.jpg, dryRun=false, createCopy=true, collisionResolutionStrategy=FAIL]: Text '211946' could not be parsed at index 6
@kocmana kocmana self-assigned this Jan 20, 2022
@kocmana kocmana added the bug Something isn't working label Jan 20, 2022
@kocmana kocmana added this to the Initial Release milestone Jan 20, 2022
@kocmana
Copy link
Owner Author

kocmana commented Apr 12, 2022

https://stackoverflow.com/questions/6928267/converting-simpledateformat-date-format-to-regular-expression leaves little hope for an elegant solution, together with limited exposure of DTF generation internals - settling for a MVP solution for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant