Commit Graph

17 Commits

Author SHA1 Message Date
Linus Groh
4769878618 Merge branch 'master' into introduce-releases 2018-04-17 12:55:03 +02:00
Ritiek Malhotra
b968b5d206 Scrape YouTube by default and optionally use YouTube API to perform searches (#250)
* YouTube scraping

* Cleanup GenerateYouTubeURL class

* Some minor improvements

* Add test to fetch title with and without api key
2018-03-09 20:40:15 +05:30
Linus Groh
177f72b532 Prepare for releases 2018-02-02 15:19:12 +01:00
Ritiek Malhotra
3e6b2d7702 Increase coverage (#218)
* Monkeypatch fetch user and use pytest.tempdir

* Cover spotify_tools.grab_album()

* Cover avconv conversion

* Cover grab_single()

* Reduce code repetition

* Move grab_playlist() to spotify_tools.py

* Move Spotify specific functions to spotify_tools.py

* Refactoring

* Return track list from write_tracks()

* Fix tests

* Cover more cases in generate_youtube_url()

* Test for unavailable audio streams

* Test for filename without spaces

* handle.py 100% coverage

* Improve config tests

* Speed up tests

* Install avconv and libfdk-aac

* Some cleaning

* FFmpeg with libfdk-aac, libopus

* Some refactoring

* Convert tmpdir to string

* Cover YouTube title when downloading from list

* Explicitly cover some internals.py functions
2018-01-26 20:44:37 +05:30
Ritiek Malhotra
9f35471f3a Read configuration from config.yml (#200)
* Read from config.yml

* Mention config.yml

* Require PyYAML >= 3.12
2018-01-13 16:59:44 +05:30
WMP
4cf8a210bf Change for automatical download video with this same duration as spotify song (#111)
* Changes in .gitignore file:
 - added .python-version
This file is used in pyenv to select good python version.

Changes in core/misc.py:
 - added function get_sec to convert HH:mm:ss to seconds

Changes in spotdl.py:
 - in function generate_songname
     change function to receive generate_metadata, this is optymalization, becouse in oldest version metadata from spotify api is downlaoded 2 times
 - in function generate_youtube_url
     song variable use changed function generate_songname
     function now looking for songs in while, and save data to dict. Dictionary is used in manual and auto mode. In dictionary keep is youtube link, title, videotime (in format HH:mm:ss) and videotime converted to seconds.
     For now in automatic downloading is selected video with least difference betwen youtube video time and time from spotify. This is important, becouse in youtube a lot of movies has scenes before/after without musics.

* Fix parameter in generate_songname() and dual calls

* Fix tests

* Skip tests that depend on the location (for the moment)

* Remove unnecessary code
2017-07-17 20:20:29 +05:30
Ritiek
532bd892b0 Update metadata test 2017-06-25 13:49:27 +05:30
Ritiek
e2c11f3e0c Test spotify generated songname 2017-06-25 00:05:00 +05:30
Ritiek
69634475ad Test spotify generated songname 2017-06-25 00:04:21 +05:30
Ritiek
5aa8c66db3 Small encoding changes 2017-06-21 12:58:15 +05:30
Ritiek
0c328079a8 Fix encoding problems in python2 2017-06-21 00:34:24 +05:30
Ritiek
dd4a0c5761 Use urllib2.quote() to fix encoding errors 2017-06-16 20:55:14 +05:30
Ritiek
1aa7639bee Use urllib2.quote() to fix encoding errors 2017-06-16 20:54:48 +05:30
Ritiek Malhotra
1c629051f4 Load albumart from URL directly into memory 2017-06-15 04:05:24 +05:30
Ritiek
f2acf30aa4 Split code 2017-06-15 00:26:53 +05:30
Ritiek Malhotra
7dff63f9aa Add list.txt and last_albumart.jpg 2017-05-03 12:19:41 +05:30
Vincenzo "vikkio88
f740b17cf0 Set of minor fixes (#11)
* minor fix on main script

* added gitignore

* Fixed problem related to sudo misused on the convert command
2016-10-11 20:45:19 +05:30