Closed geebeetoo closed 2 months ago
No worries, this is actually the best place to discuss the project. Headless is supposed to allow you to do the entire process without a chromium window popping up and stealing your focus. Though in practice it doesn't always work (and it's notoriously hard to find out why). I just ran a quick test and headless
was able to drive the whole experience, but the downloads didn't go anywhere. Still need to dig into why.
I just pushed a fix for passing negative values for --transpose
, it was interpreting this as another argument because of the hyphen.
For (2), I'm assuming that the script encountered an error and exited with a non-zero status code, which will (typically) halt scripts. Can you run it with --debug
to see more detail?
Thanks for getting back to me. I will try running with --debug I was able to use --transpose=-1 thanks to ChatGPT ;-)
Oh by the way, --count-in it will turn it on if it is not already on, but if it is already on and we do not use --count-in, it does not turn it off. It would be nice to have it toggle.
I am having trouble getting songs downloaded - it downloads only a few instruments and then completely stops with error message (see below). Also I tried headless and it did not save the songs to my desktop. I had same crash without the command --headless but it did save whatever instruments it downloaded. For example here my command: kv_downloader download --headless --count-in --transpose=-1 --debug "https://www.karaoke-version.com/custombackingtrack/queensryche/silent-lucidity.html"
ERROR MESSAGE:
2024-09-12T15:01:56.286051Z INFO kv_downloader::tasks::download_song: - waiting for download modal...
2024-09-12T15:01:56.286090Z DEBUG headless_chrome::browser::tab: Waiting for element with selector: ".begin-download"
thread 'main' panicked at src/tasks/download_song.rs:106:18:
Timed out waiting for download modal.: The event waited for never came
note: run with RUST_BACKTRACE=1
environment variable to display a backtrace
2024-09-12T15:02:26.442356Z INFO headless_chrome::browser: Dropping browser
And the download-path is not working. It gets the path I gave it, but it hangs once it tries to establish session.
Thanks, got this fixed. Making a new release (0.3.1) now. I was also able to download files properly with headless mode by specifying a download path.
Thanks, Ben. In the end I decided to try your previous version (puppeteer) and I found it worked better for my needs. I just tweaked some durations for sleep added some args to stop some popups to give the browser time to do whatever. My goal was to run a bash file that can run for 25 songs in sequence of course. I know about the concern for the TOS for KV but reading through it I concluded it is not an issue. So, puppeteer version seemed to be more robust in running for more than 3 songs. I have about 400 songs to download. Puppeteer can do about 23-25 songs before Chromium sends a popup with choice to Quit or Continue Download. This interrupts the automation, but at least I get 20 songs without attending to it. Thanks to you I don't have to do it manually.
My apologies for reaching out this way. I did not know any other way to ask my questions. Your product is amazing, and thank you for that! (I'm not very familiar with Github and how to contact contributors)
I just downloaded (cloned) this yesterday. I got it to work but I have just 2 questions:
1) Based on the documentation in the READ ME regarding "options":
-d - Change the download location
-h or --headless - Use headless mode, which hides the UI.
-p - Change the pitch of the downloaded tracks (-1 to go down half step, 1 to go up half step, etc)
--count-in - Include the intro precount on all tracks
--debug - Enable debug logging (in case something goes wrong this helps give more detail)
I thought I could control headless mode, and hide the UI but I could not get it to work. Perhaps I am misunderstanding what it is meant to do. Also having trouble doing the transpose or pitch change with option eg. "-1", I tried everything and it doesn't recognize it. Actually the trouble with transpose for me is trying to go down 1 or 2, to go up is fine all you do is
kv_downloader download --transpose "1" "https://www.karaoke-version.com/custombackingtrack/maroon-5/sunday-morning.html"
if I try the following for going down in pitch, it fails as it doesn't recognize it. kvdownloader download --transpose **"-1"_** "https://www.karaoke-version.com/custombackingtrack/maroon-5/sunday-morning.html"
Also, not sure if --headless works. When I include that option I don't see a difference, I still get the headless browser op up and I can see the automation.
If anyone could copy an example of the full command text with the count in, the headless, and the path, and the transpose/pitch (that was tested first) - I would appreciate it
2) Perhaps this is out of scope but I wanted to bring it to your attention: I used a bash file to automated the download of 3 files ( hoping to use it for 40 songs eventually) and it only downloads 2 songs and never goes beyond 2. I tried about 6 times with different songs.Any idea?