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

PDB Error: failed to parse the complete file #28

Open
MarcoMartignone opened this issue May 27, 2023 · 3 comments
Open

PDB Error: failed to parse the complete file #28

MarcoMartignone opened this issue May 27, 2023 · 3 comments

Comments

@MarcoMartignone
Copy link

Hi @flesniak,

Thanks for all the amazing work on this tools.

I'm encountering an issue while parsing a large Rekordbox library:
INFO: Player 3 Link Info: usb "", 2840 tracks, 11 playlists, 437737/476822MB free

During the parsing process, an error occurs resulting in only a fraction of the library being parsed. The error reads:
WARNING: pdb failed [PDB database not available: PDBProvider: failed to parse "databases/player-3-usb.pdb": failed to parse the complete file (1380352/1810432 bytes parsed)]

If you have any advice or insights that could help resolve this issue, I would be extremely grateful.

For your reference, here is the related code:

if stat.st_size != self.parsed["file_size"]:
raise RuntimeError("failed to parse the complete file ({}/{} bytes parsed)".format(self.parsed["file_size"], stat.st_size))

I'm also including the link to the .pdb file I'm trying to parse as well as the file that was partially parsed:
https://drive.google.com/drive/folders/1jJxlkp0osE4c6lNcvYSwLj3fTy7mcFkz?usp=share_link

Thanks in advance for your help.

Thanks,
Marco

@brunchboy
Copy link

It seems that Crate Digger is able to parse that database, this just may be hitting one of the elements that have been discovered in the past few years but not yet incorporated in Python ProDJ Link (I opened issues about a few of them, but stopped when those just lingered). What are you trying to accomplish, is it something that Beat Link Trigger could help you with? That incorporates new discoveries as soon as we make them.

@MarcoMartignone
Copy link
Author

MarcoMartignone commented May 29, 2023

Hi @brunchboy,

Indeed, I'm aware that both Crate Digger and Beat Link Trigger are effectively parsing the library.

My main objective is to search for a specific Track ID based on a track name on a CDJ's USB media and subsequently load that track remotely. At the moment, I'm working within TouchDesigner and a Python solution would be cleaner. I understand that I could exetend Beat Link Trigger to interface with TouchDesigner using either OSC or UDP, yet a Python-based approach is preferable in my current context.

@brunchboy
Copy link

That makes sense (although I just did an integration with TouchDesigner for a lighting designer in China 😄). Unfortunately, I only deal with Python when I have to, such as a small part of the back end for my window shade automation, so I can’t help you on this side. You may be able to fork the project and make the necessary fixes yourself, though, if Mr. Lesniak no longer has time. My database documentation is language neutral.

One approach that seems like an easy potential win would be to change this project so that it uses Kaitai Struct to parse the data the same way I do: that has a Python implementation, and then you could use the same structure definition as Crate Digger does, thereby always keeping current with new discoveries and fixes.

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

No branches or pull requests

2 participants