Thanks for your hard work cjcox. It is appreciated..
+1 (or 7 if my wife and 5 cats can vote)
Thanks for your hard work cjcox. It is appreciated..
+1 (or 7 if my wife and 5 cats can vote)
An aside:
Back slashes are the most evil thing in the universe. Windows folks, even Windows knows they are evil which is why they accept forward slashes. Please don’t make me rewrite all of Python just because you must have evil backslashes. I hope I don’t have to go into painful detail… for now, please trust me, backslashes… just SAY NO! or things are going to break…
Oh… and did I mention just how evil back slashes are? They are evil. There is no debate, feel free to post and whine, but they are evil. If you use them in your paths, you are intentionally breaking things. So let’s do the right thing ok? Let’s not use something that is inherently evil.
They are evil.
Evil.
Nuff said.
The database json file sure lends itself to Excel format or even being displayed in HTML/web format where a person could have a fresh “friendly view” of what is on Tablo according to your script (assuming one refreshes the info locally) and they could simply go down either the Excel file or HTML page, click a show and have it convert just like that. Pretty simple - well, with a few hours time!
Argh… (python is giving me fits)
1. Colons are important to Windows, but not allowed anywhere except drive letter, etc.
2. Colons inside of ffmpeg options causes problems and need to be escaped.
3. Python is not going to allow #2 to happen.
4. Getting rid of colons universally breaks #1.
Sigh…
Ah. The fun catch-22s of cross-platform development. Can you use a Unicode escape character ("\u003a") or Ascii escape character ("\x3a")?
@Joltarin, I will experiment with it.
If I can’t find a solution…
1. Don’t use Windows, or at least no paths with drive_letter: in them
(friends shouldn’t let friends use Windows, just saying)
2. Live without flexible ffmpeg option handling (where a colon is not allowed and must be escaped).
… really hating Python and Windows at the moment…
Possible solution for a particular scenario…
change directory to drive letter base…
and replace all colons in remaining path…
Getting late, I’ll look into this more tomorrow.
Evil? LOL- there’s a whole lot of Python stuff running in Windows. Other cross-platform languages use them - JAVA for example.
Backslashes are evil… didn’t I make that clear ? 
Anyhow, I think I have a solution for the majority of cases… I’ll be working on it more tonight.
Escapes are important. Backslash is THE escape character. it just is… and I don’t see that changing…
I would argue you have a “whole lot of Python stuff” that does fairly trivial things running in Windows 
\ <— evil (outside of escaping)
More on my solution tonight (I don’t think 0.4 will get rolled out tonight though).
Excellent script, testing it out now on my NAS. Had to set TMPDIR first as my /tmp is tiny. Can’t wait to see the results in about 10 minutes.
Couldn’t get it to work on the NAS, but got it all running on a windows machine.
Even my version of ffmpeg is old. It’s one of those things that is constantly evolving.
(back to work on 0.4…)
hmmm…wonder why it borked on the run. The error above was when I tried using a manual command put together from the -d output and by removing all the ', and the metadata tags.
Any chance you can upgrade your ffmpeg on the NAS?
Haven’t found a way. It is part of the base firmware image.
Taking small break, created this… something to ponder on… (for those without Plex)…
Time for Something Else…
@cjcox, please add fast forward and rewind buttons, and frame preview, and … 
The --query (-q) takes regular expressions (followed by implicit wildcard). So -q “.” would match everything.
Running the script with noclobber is exactly what you should do for this scenario.
Since you’re doing a large scale run, could I get you to hold on this until tomorrow and I get 0.4 out? It’s quite a change (fixes, etc.)
With that said 0.4 contains some radical changes… perhaps a bit more “beta” than usual.
Cool. I will wait until .4 to do the batch download.