GithubHelp home page GithubHelp logo

vimeo-download's People

Contributors

ajkamel avatar alexeygrigorev avatar campbecf avatar debakel avatar embee avatar lionelyoung avatar maxxi165 avatar muescha avatar paschoaletto avatar tayiorbeii avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vimeo-download's Issues

unexpected token `newline'

Hi,

i've installed ffmpeg and requirements.txt but when I put the run the command with the master json url, I get:
-bash: syntax error near unexpected token `newline'

Any ideas about how to resolve this?

-Ray

Update urlparse to urllib.parse for Python3 usage

Had to update the import urlparse to import urllib.parse on line 13 along with:

Line 56: video_base_url = urllib.parse.urljoin(base_url, video['base_url'])
Line 94: audio_base_url = urllib.parse.urljoin(base_url, audio['base_url'])
Line 175: base_url = urllib.parse.urljoin(master_json_url, content['base_url'])

Error installing requirements on Windows 10

When trying to install the requirements on Windows 10 using pip install -r requirements.txt, the following error occurs:

Collecting asn1crypto==0.22.0 (from -r requirements.txt (line 1)) Using cached https://files.pythonhosted.org/packages/97/ba/7e8117d8efcee589f4d96dd2b2eb1d997f96d27d214cf2b7134ad8acf6ab/asn1crypto-0.22.0-py2.py3-none-any.whl Collecting cffi==1.10.0 (from -r requirements.txt (line 2)) Using cached https://files.pythonhosted.org/packages/5b/b9/790f8eafcdab455bcd3bd908161f802c9ce5adbf702a83aa7712fcc345b7/cffi-1.10.0.tar.gz Complete output from command python setup.py egg_info: Traceback (most recent call last): File "c:\python37\lib\site-packages\setuptools\msvc.py", line 489, in _find_latest_available_vc_ver return self.find_available_vc_vers()[-1] IndexError: list index out of range

[Partial Issue] Private Videos & Custom Naming

Hi!

Thank you for this great project. I noticed that some private set videos aren't downloading anymore, not sure why. What should I attach here to help debug it? The video links?

`
add to each https://player.vimeo.com/video/
[to avoid search engines to recognize them and alert the user/owner]

279244536
279246395
279258205
283843909
279377502
282192395
222842940
281246503
281246171
256806718
279379395
219681491
219686088
219690321
287649068
287657535
287650996
219668827
256880544
284064108
287645102
226695025
225543538
226697780
283841806
287643793
226736432
287646304
226745765
283839277
283838720
283839723
283840463
280013330
250454688
284349868
280909400
280915260
283810554
283813049
284041241
284059149
284046146
283818105
283820576
287644561
283824997
283827011
284051484
284049382
284071022
284070857
284060551
284063029
284028810
284033883
287652841
287654983
284022670
287754706
281964137
282501037
284018907
284029724
284019718
283139745
283923521
283924824
283926779
283927472

Most of them work, there are a couple of them that doesn't cause they are set as private or as can only be embedded in specific domains.
`

Other thing, since there is the option to specify a text file to auto download a list of videos, it would be amazing if we could also specify a secondary text file with new naming for each video file, to auto set custom names for each one of them. :)

Thanks

json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

root@5c7bcadea91f:/usr/src/app# python vimeo-download.py --url "https://137skyfiregce-vimeo.akamaized.net/exp=1537799112~acl=%2F200853336%2F%2A~hmac=50b46c653542bd75b87f6da52d9d549be79267263faafc47e07fe2baa8560947/200853336/sep/video/678908315,678908317,678908316,678908303,678908301/master.json?base64_init=1" --output iiiiim.mp4
Creating /usr/src/app/temp...
Creating /usr/src/app/output...
Output filename set to: /usr/src/app/output/iiiiim.mp4.mp4
Traceback (most recent call last):
File "vimeo-download.py", line 166, in
content = resp.json()
File "/usr/local/lib/python3.7/site-packages/requests/models.py", line 896, in json
return complexjson.loads(self.text, **kwargs)
File "/usr/local/lib/python3.7/json/init.py", line 348, in loads
return _default_decoder.decode(s)
File "/usr/local/lib/python3.7/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/local/lib/python3.7/json/decoder.py", line 355, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
root@5c7bcadea91f:/usr/src/app#

Audio segments

Hey everyone,

I was trying to download the following master:
https://122skyfiregce-vimeo.akamaized.net/exp=1513969793~acl=%2F217512921%2F%2A~hmac=d27f90c9b8922f64c901a4bd33b8b7f778e3b2621e0a90baad3318669cf72d4f/217512921/video/753333160,753333156,753333155,753333151/master.json?base64_init=1

The video segments were downloaded successfully, but I got an error in the audio segments part.

Traceback (most recent call last): File "vimeo-download.py", line 170, in <module> download_audio(base_url, content) File "vimeo-download.py", line 89, in download_audio audio = content['audio'][0] TypeError: 'NoneType' object has no attribute '__getitem__'

Other thing, did you notice that if you remove the "base64_" from the url, it returns the first file name without base64 encriptation? Like:
https://122skyfiregce-vimeo.akamaized.net/exp=1513969793~acl=%2F217512921%2F%2A~hmac=d27f90c9b8922f64c901a4bd33b8b7f778e3b2621e0a90baad3318669cf72d4f/217512921/video/753333160,753333156,753333155,753333151/master.json?**init=1**

Thank you :)

ps: If I knew how to debug step-by-step python, I would have figure it out and push it here.

Http Error 410 Code

my code for manage the 410 http error:

get the content

    resp = requests.get(master_json_url)
    if resp.status_code != 200:              
        if resp.status_code == 410:
        	print('HTTP error (410 Gone)')
        	quit(0)
        else:      		
        	match = re.search('<TITLE>(.+)<\/TITLE>', resp.content, re.IGNORECASE)
        	title = match.group(1)
        	print('HTTP error (' + str(resp.status_code) + '): ' + title)
        	quit(0)

Quality Selection?

Hello,

I was able to run this script and get the almost desired output: as I select 1080p quality on the player, the master.json url is the same and I don't see a way to get the 1080p download rather than the 360p.

Am I missing something?

Cheers

Build errors on Debian 9 .. solved it though

I did have some problems in getting the dependencies to work, but I figured it out and wanted to pass along what I did.

I was getting build errors for the 'cryptography' module. Upon finding this link: https://cryptography.io/en/latest/installation/#building-cryptography-on-linux .. I went ahead and tried updating the packages as indicated (apt-get install build-essential libssl-dev libffi-dev python3-dev) but it didn't help. What DID help was doing 'pip install cryptography --no-binary cryptography'

I then went through each line of 'requirements.txt' and issued separate 'pip install ' (with no version number) and they installed ok.

I was then able to run the vimeo-downloader.py as expected and it works fine.

Just wanted to pass that along in case anyone happens across the same issues I had.

Errors While Installing on MacOS Mojave

I've got the following error messages:

ERROR: wifiphisher 1.4 requires pbkdf2, which is not installed.
ERROR: wifiphisher 1.4 requires PyRIC, which is not installed.
ERROR: wifiphisher 1.4 requires roguehostapd, which is not installed.
ERROR: paramiko 2.6.0 has requirement cryptography>=2.5, but you'll have cryptography 1.8.1 which is incompatible.
ERROR: wifiphisher 1.4 has requirement tornado==4.5.3, but you'll have tornado 5.1.1 which is incompatible.

Errors in "merge" audio and video without downloading?

   Hi,
   It seems I found two errors in how the script works with "--skip-download" key

parser.add_argument("-s", "--skip-download", action="store",
help="merges video and audio output of already downloaded streams",
metavar="TIMESTAMP")

   First. When downloading audio and video files are saved in a temporary folder, the name of which ("OUT_PREFIX") is obtained by joining "TIMESTAMP" and "SALT".
# Prefix for this run
TIMESTAMP = datetime.datetime.now().strftime("%Y%m%d-%H%M%S")
SALT = ''.join(random.choice(string.digits) for _ in range(3))
OUT_PREFIX = TIMESTAMP + '-' + SALT
But the argument of "--skip-download" key replaces only the first half.
if args.skip_download:
TIMESTAMP = args.skip_download
print("Overriding timestamp with:", TIMESTAMP)
And as "SALT" is still generated randomly we get incorrect folder address with previously downloaded video.

   And second. When the script works with "--skip-download" key, it first creates "OUT_PREFIX" from "TIMESTAMP" and "SALT", then change "TIMESTAMP", but the value "OUT_PREFIX" remains the same! As a result, we all the more do not get the correct address previously downloaded video.

Error installing on Ubuntu 18.04.03

Hi, the installation of requirements fails with this error:
Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-nraJ0E/cryptography/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-bAf8ol-record/install-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in /tmp/pip-build-nraJ0E/cryptography/

Download an entire course?

How to get this program working on Mac OS Catalina

I'm inexperienced in Python so I don't trust myself to submit a PR, and I have no doubt my lack of experience is clear in this guide. If you're having issues getting this program working, hopefully this helps you out.

  • Not sure if needed: Install Xcode and then the command line tools: xcode-select --install
  • Install Homebrew
  • Install ffmpeg: brew install ffmpeg
  • Install pip: https://www.shellhacks.com/python-install-pip-mac-ubuntu-centos/
  • Install Python 3: https://www.python.org/downloads/mac-osx/
  • Run pip3 install -r requirements.txt to install the requirements. pip3 ensures you're using Python 3 and not Python 2.
  • If that didn't produce any errors, go to the next step. For me I received the following error: Running setup.py install for cffi ... error. To get around this I manually installed every dependency from requirements.txt (without honouring the specific version numbers):
pip3 install cffi
pip3 install cryptography
pip3 install enum34
pip3 install idna
pip3 install ipaddress
pip3 install packaging
pip3 install pycparser
pip3 install pyOpenSSL
pip3 install pyparsing
pip3 install requests
pip3 install six
pip3 install tqdm
pip3 install urllib3
  • Run python3 vimeo-download.py --url "http://...master.json?base64_init=1" (replace the URL as required)
  • If you get the following error: ModuleNotFoundError: No module named 'urlparse' follow this guide and try the above command again. You should now see the video start downloading!
  • If you then need to merge the video/audio tracks, navigate to where the file was saved and run ffmpeg -i v.mp4 -i a.mp3 -c copy merged.mp4

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.