edkennard / rekordbox-repair

Automatically relocate missing files for tracks in Pioneer's rekordbox DJ software
MIT License
68 stars 7 forks source link

Failed to complete successfully: The filename, directory name, or volume label syntax is incorrect #17

Closed oxillix closed 1 year ago

oxillix commented 1 year ago

I have no idea what I am doing wrong. Did a fresh export trough rekordbox. Do you have an idea?

C:\Users\nicol>rekordbox-repair -i "C:\Users\nicol\Desktop\Rekordbox\rekordbox-library.xml" -o "C:\Users\nicol\Desktop\Rekordbox\rekordbox-library-nodupes.xml" -s "C:\Users\nicol\Desktop\MUZIEK\PYTHON\YT DL\TRACKS" 2022-11-22 21:44:34,495 INFO - Running using Java version 1.8.0_211 2022-11-22 21:44:34,677 INFO - Analysing rekordbox collection... 2022-11-22 21:44:34,678 INFO - Reading rekordbox XML file C:\Users\nicol\Desktop\Rekordbox\rekordbox-library.xml... 2022-11-22 21:44:34,872 INFO - Loading tracks in the collection... 2022-11-22 21:44:35,113 ERROR - Failed to complete successfully: The filename, directory name, or volume label syntax is incorrect java.io.IOException: The filename, directory name, or volume label syntax is incorrect at java.io.WinNTFileSystem.canonicalize0(Native Method) at java.io.WinNTFileSystem.canonicalize(WinNTFileSystem.java:428) at java.io.File.getCanonicalPath(File.java:618) at com.vividlab.rekordbox.data.CollectionTrack.$anonfun$filePath$1(CollectionTrack.scala:31) at scala.Option.map(Option.scala:242) at com.vividlab.rekordbox.data.CollectionTrack.(CollectionTrack.scala:31) at com.vividlab.rekordbox.data.CollectionTrack$.apply(CollectionTrack.scala:38) at com.vividlab.rekordbox.data.CollectionTracks$.$anonfun$fromXml$1(CollectionTrack.scala:46) at scala.collection.StrictOptimizedIterableOps.map(StrictOptimizedIterableOps.scala:100) at scala.collection.StrictOptimizedIterableOps.map$(StrictOptimizedIterableOps.scala:87) at scala.xml.NodeSeq.map(NodeSeq.scala:51) at com.vividlab.rekordbox.data.CollectionTracks$.fromXml(CollectionTrack.scala:46) at com.vividlab.rekordbox.analyse.Analyser$.analyse(Analyser.scala:24) at com.vividlab.rekordbox.Main$.main(Main.scala:15) at com.vividlab.rekordbox.Main.main(Main.scala)

edkennard commented 1 year ago

Hi,

There must be a track in rekordbox pointing to a file on the disk which has an invalid name for some reason, causing the process to fail.

First thing I must check is you're definitely using the latest version, right? Not long ago I made some changes to the tool to make it more tolerant of these kind of problems

oxillix commented 1 year ago

Hi, thanks for your quick reply, and this nice piece of software! :)

I am using version 0.4, rekordbox is on version 6.6.7.

I already have missing files in my collection (link to file is broken bcz of delete), this shouldn't be a problem right?

Any idea what characters are invalid?

edkennard commented 1 year ago

Hi,

You're welcome :)

Deleted files will be no problem. There's definitely something wonky with a file name or a folder name on your Windows disk, given the way it's failing maybe more likely a folder. I've seen people with emojis in folder or file names. There are other characters which might cause trouble.

I think the best next step would be either a) if you could somehow get your rekordbox library XML file to me, so I can have a scan of that and see if I can spot anything wrong (if you prefer this approach I will tell you my email address so you can pass this to me privately) or b) we could do a quick Zoom session and you could share your screen with me and show me what's going on. Timezone wise, I'm in Spain.

In the meantime I'm going to see if there's a way I can improve the error reporting so it tells us what exactly the offending folder is.

edkennard commented 1 year ago

Hi @oxillix ,

I've made a fix to my code and submitted it as a pull request: https://github.com/edkennard/rekordbox-repair/pull/18

I will merge this and publish a new version 0.5 of the tool as soon as I can later today, for now I need to focus on my day job :)

Cheers, Ed

oxillix commented 1 year ago

Hi @edkennard,

I would rather not share my .xml file publicly, but I'm open to have a zoom call. You can contact me with mail/zoom on: dikkennn@proton.me

I checked your latest pull request, but it seems like there is a small bug in it, this is the output:

[error] java.lang.IllegalArgumentException: Input rekordbox XML file doesn't exist: C:\Users\nicol\Desktop\Rekordbox\rekordbox-repair\UsersnicolDesktopRekordboxrekordbox-library.xml
[error]         at com.vividlab.rekordbox.Config$.apply(Config.scala:47)
[error]         at com.vividlab.rekordbox.Main$.main(Main.scala:13)
[error]         at com.vividlab.rekordbox.Main.main(Main.scala)
[error]         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[error]         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
[error]         at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[error]         at java.base/java.lang.reflect.Method.invoke(Method.java:568)
[error]         at sbt.Run.invokeMain(Run.scala:143)
[error]         at sbt.Run.execute$1(Run.scala:93)
[error]         at sbt.Run.$anonfun$runWithLoader$5(Run.scala:120)
[error]         at sbt.Run$.executeSuccess(Run.scala:186)
[error]         at sbt.Run.runWithLoader(Run.scala:120)
[error]         at sbt.Defaults$.$anonfun$bgRunTask$6(Defaults.scala:1983)
[error]         at sbt.Defaults$.$anonfun$termWrapper$2(Defaults.scala:1922)
[error]         at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
[error]         at scala.util.Try$.apply(Try.scala:213)
[error]         at sbt.internal.BackgroundThreadPool$BackgroundRunnable.run(DefaultBackgroundJobService.scala:369)
[error]         at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
[error]         at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
[error]         at java.base/java.lang.Thread.run(Thread.java:833)
[error] (Compile / run) java.lang.IllegalArgumentException: Input rekordbox XML file doesn't exist: C:\Users\nicol\Desktop\Rekordbox\rekordbox-repair\UsersnicolDesktopRekordboxrekordbox-library.xml

I've never worked with scala before, but it seems like this is a quick problem to solve ;)

Thank you in advance!

oxillix commented 1 year ago

This was the input: run -i "C:\Users\nicol\Desktop\Rekordbox\rekordbox-library.xml" -o "C:\Users\nicol\Desktop\Rekordbox\rekordbox-library-nodupes.xml" -s "C:\Users\nicol\Desktop\MUZIEK\PYTHON\YT DL\TRACKS"

edkennard commented 1 year ago

I sent you a mail, just to let you know in case it ended up in the spam folder..