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

Cache conversions #39

Open
mrmbernardi opened this issue Sep 3, 2022 · 5 comments · May be fixed by #53
Open

Cache conversions #39

mrmbernardi opened this issue Sep 3, 2022 · 5 comments · May be fixed by #53
Assignees
Labels
enhancement New feature or request

Comments

@mrmbernardi
Copy link
Contributor

I'm trying to transfer a playlist of 1792 songs from spotify to youtube. On my first attempt I got 920/1792 converted before encountering this error:

Could not transfer playlist 1792. ExceptionHTTPSConnectionPool(host='music.youtube.com', port=443): Read timed out. (read timeout=30)

I go to retry the command and this time I get to 460 songs before I get a similar read timeout error.

If the program would cache the conversions it's already made, I would be able to keep running this command until it converts all the songs and completes successfully, but without this it's up to chance as it starts from the beginning every time.

@guglielmobartelloni
Copy link

If you want, in my spare time, I can try to implement it. It shouldn't be too difficult

@mrmbernardi
Copy link
Contributor Author

I got my playlist converted successfully, but it would definitely help future users with the same issue if you implemented it.

As an aside, I'm not sure why I was getting the read time outs. I have a solid connection, I'm thinking it may have been load shedding on youtube's end?

@sigma67
Copy link
Owner

sigma67 commented Sep 16, 2022

It's a good idea, but it would require some sort of local database mapping search strings to videoIds. The simplest option would be some sort of text file, ideally not requiring new dependencies. I think caching should be made optional through an opt-in parameter --cache, as search results can and do change over time.

@sigma67
Copy link
Owner

sigma67 commented Dec 12, 2022

@guglielmobartelloni are you still interested in implementing this? Feel free to make suggestions for an implementation

@sigma67 sigma67 added the enhancement New feature or request label Apr 6, 2023
@sigma67 sigma67 self-assigned this Apr 20, 2023
@sigma67
Copy link
Owner

sigma67 commented Apr 20, 2023

Feel free to check out the first draft here: https://github.com/sigma67/spotify_to_ytmusic/tree/39-cache-conversions

I think we will need a CLI to interact with the cache as well:

  • option to ignore cache
  • reset cache
  • remove all entries matching a provided string from cache

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants