23570 Commits

Author SHA1 Message Date
Simon Morgan
90dfa03af5 [yuvutu] Support for user pages 2016-10-11 10:44:22 +01:00
Yen Chi Hsuan
f165ca70eb
[abc.net.au:iview] Fix for non-series videos (closes #10895) 2016-10-11 12:53:27 +08:00
Yen Chi Hsuan
27b8d2ee95
[hbo] Add display_id and another test (#10892) 2016-10-11 12:41:44 +08:00
Yen Chi Hsuan
71cdcb2331
[hbo] Support episode pages (closes #10892) 2016-10-11 12:30:35 +08:00
John Hawkinson
264cc25648 kill extra blank line 2016-10-10 21:55:07 -04:00
John Hawkinson
f0d1e99556 [test_download]: -m regexp to run matching tests
Run test modules whose name matches the given regexp.
This is quick-and-dirty, there's probably a better way,
but the TestSuite system is really complicated and this is
super-easy.
2016-10-10 21:45:15 -04:00
John Hawkinson
02f4d4e44f Move JWPlayer JSON array handling to IQM2
Out of @yan12125's concern that the presumption that JWPlayer data as
an array representing multiple formats rather than a playlist might be
specific to IQM2, move this code from jwplatform.py to iqm2.py.

JWPlatformBase now reverts to throwing a TypeError if it gets an
array.

Now IQM2 redefines the _extract_jwplayer_data() method as well, but it
continues to leverage JWPlatformBase for _parse_jwplayer_data(), which
is the bulk of the work.
2016-10-10 10:55:42 -04:00
John Hawkinson
cb2e9ec69e Use subsidiary page's media ID, not parent page
Video IDs should be based on the unique ID of the video, not the
meeting ID of the parent page that links to the media
page. Unfortunately we don't learn the media ID until after
downloading the first page.
2016-10-10 02:24:39 -04:00
John Hawkinson
87af84de37 Leverage JWPlatformBase instead of Generic
Per @yan12125's suggestion:
* Redefine _find_jwplayer_data() to use the SetupJWPlayer RE that's IQM2-specific
* Retreive the 2ndary webpage on our own
* Search for the title just like generic does
2016-10-10 02:12:44 -04:00
John Hawkinson
00253f8312 [JWPlatformBase] handle a few more cases
* If our parsed JSON ends up as a list, rather than a dict, then store
  it in ['sources'] as that list, rather than trying to wrap it in an
  array, which leads to type errors. (Such a list indicates multiple
  file formats/sources, rather than a playlist.)

* Allow format labels like 'SD 480' and 'HD 720' in addition to '1080p'
2016-10-10 02:07:34 -04:00
John Hawkinson
c1ce8deed8 re-fill _TESTS (whitespace) 2016-10-10 01:57:56 -04:00
John Hawkinson
f1f0b34a4e Call _hook_progress() instead of faking it
Since now report_progress() handles lack of a file size.
2016-10-09 10:38:00 -04:00
John Hawkinson
5a1e040b8e report_progress() shouldn't fail w/o total_bytes
In the absence of the total_bytes key, just say "Completed" (looks
better than a bare "100%").

Compose the msg_template additively.

In practice, for pipes (where we lack total bytes) we also lack
elapsed time, so we end up with:
  [download] Completed
though if elapsed time were somehow set we'd have:
  [download] Completed in 00:10
2016-10-09 10:36:40 -04:00
John Hawkinson
9d92ac8805 Send traceback to stderr explicitly
Per @yan12125, traceback.print_exc() can send output to the wrong
place under some circumstances (e.g. use of logger), so send it to
stderr. Which requires a compat_str.
2016-10-09 10:18:52 -04:00
John Hawkinson
01845abc92 Remove verbose printing
It should move to YoutubeDL.process_ie_result per @yan12125,
future pull request forthcoming.
2016-10-09 09:18:23 -04:00
John Hawkinson
6589917a0b Remove #'d debugging per @yan12125 2016-10-09 09:15:52 -04:00
arza
cbfecd5122 [ruutu] Update tests 2016-10-09 16:08:02 +03:00
John Hawkinson
cb1cea4b34 Revert "Print traceback when raising UnavailableVideoError"
This reverts commit ca14b60aca99090895c636edc95e0ca9c5469dfa.
Moved to PR #10888.
2016-10-09 08:17:05 -04:00
John Hawkinson
c6c733d4a3 Print traceback when raising UnavailableVideoError
An OSError or IOError generally indicates something a little more
wrong than a "simple" UnavailableVideoError, so print the actual
traceback that leads to the exception. Otherwise meaningful postmortem
debugging a bug report is essentially infeasible.
2016-10-09 08:13:05 -04:00
John Hawkinson
8d8acd193e Use _match_id() instead of re.match()
Oops, when I created this extractor I copied the sample code from the
2014 manpage on my system, thus missing 4bc77c8417ca0340d09dcebb311d06aa7d5ba0ac's
introduction of the _match_id() helper function.
2016-10-09 08:00:15 -04:00
Simon Morgan
1f3cfb8178 [yuvutu] Check for thumbnail in test 2016-10-09 12:56:19 +01:00
Yen Chi Hsuan
176006a120
[allocine] Fix for /video/ videos (closes #10860) 2016-10-09 19:42:42 +08:00
Yen Chi Hsuan
65f4c1de3d
[allocine] Fix extraction (closes #10860)
I change the URL of the third test case, because now the original URL
does not contain a video anymore, and there's no easy to get the real
URL from the /film/ one.
2016-10-09 18:58:15 +08:00
Simon Morgan
54542a3ed0 Merge remote-tracking branch 'upstream/master' into yuvutu 2016-10-09 11:57:29 +01:00
Yen Chi Hsuan
b0082629a9
[nextmedia] Support action news (動新聞) on Apple Daily 2016-10-09 18:42:15 +08:00
Yen Chi Hsuan
8204c73352
[Makefile] Fix for GNU make < 4 (closes #9387)
Shell assignment operator in BSD make != is ported to GNU make in
version 4.0, so 3.x doesn't work. I choose to drop BSD make support as
installing GNU make on *BSD systems is easier than installing newer GNU
make.
2016-10-09 18:24:45 +08:00
John Hawkinson
8b0c5de724 Recommend case-insentitive _VALID_URL matching 2016-10-09 01:31:25 -04:00
John Hawkinson
b9ede2fe9e Revert "Case-insensitive URL match via suitable()"
This reverts commit cd381738a616d0de907c52de7c1f510c73a74f50.

dstftw commented in #10854 that he thinks this is the wrong way to go.
2016-10-09 01:26:02 -04:00
John Hawkinson
cd381738a6 Case-insensitive URL match via suitable()
Cherry-picked from bca0b731c41adeb689dbb119f8ee60fded5fa251 on my iqm2 branch
2016-10-09 01:25:32 -04:00
John Hawkinson
f46aea8404 remove blank line 2016-10-08 23:12:37 -04:00
John Hawkinson
2cc84715bc Set to_generic -> True to suppress fallback msg 2016-10-08 23:11:07 -04:00
John Hawkinson
9a2ed02b65 debugging print -> self.to_screen() 2016-10-08 22:46:09 -04:00
John Hawkinson
f8eeb2b25a Some instances don't have downloadable video
E.g. somervillecityma.iqm2.com only has the JWPlayer video.
Makes a better test case, so add it as the first.
2016-10-08 21:01:43 -04:00
John Hawkinson
0bdb0c707b Condense comments, distribute 2016-10-08 19:38:28 -04:00
John Hawkinson
077bf26371 Use url_result instead of instance of GenericIE() 2016-10-08 19:31:50 -04:00
John Hawkinson
e6a1522743 Tighten up regex comment 2016-10-08 19:23:59 -04:00
John Hawkinson
71fbddb78a Use (?i) for case-insensitivity in URLs 2016-10-08 19:21:33 -04:00
John Hawkinson
e468f91968 Move test cases from comment to _TESTS 2016-10-08 19:17:32 -04:00
Simon Morgan
7e44689bd0 Update README.md 2016-10-08 23:01:04 +01:00
Pierre Mdawar
ae5b06b6be [FFmpegExtractAudioPP] fix info dict return audio filepath and ext instead of the video filepath if file already exists
If the converted audio file already exists, the `FFmpegExtractAudioPP.run` method returns the video filepath instead of the audio filepath and ext.
2016-10-08 23:09:38 +03:00
Déstin Reed
2b51dac1f9
[slutload] Fix test and simplify 2016-10-09 01:17:38 +07:00
Sergey M․
f68901e50a
[reverbnation] Eliminate code duplication in thumbnails extraction 2016-10-09 01:02:35 +07:00
Déstin Reed
3adb9d119e
[reverbnation] Modernize 2016-10-09 01:00:38 +07:00
John Hawkinson
99315aa252 ExternalFD:real_download(): Skip getsize/rename when writing to stdout
In the real_download() method of the ExternalFD class:

Special-case output to stdout, when filename=='-', because otherwise
the call to os.path.getsize() raises
  OSError: [Errno 2] No such file or directory: '-'
which in turn gets masked by a try block and re-raised as
UnavailableVideoError().

And even if getsize had succeeded, we would fail on renaming, and then
we would also fail on reporting progress as report_progress() expects
to have file size information.

So report download completion with self.to_screen() just as
report_progress() would in the noprogress==True case.

You might ask whether it's an abstraction violation for external.py to
have to know and think about '-' as a filename, but unfortunately
we're there already. _call_downloader() thinks about it, and also
real_download() calls common.py's temp_name() which special-cases the
'-' filename to preserve it instead of returnign a temp file. So we
already worry about this case at this abstraction level, as well as
both below and above. Perhaps that should change, but that's for
another day.
2016-10-08 09:51:00 -04:00
John Hawkinson
ca14b60aca Print traceback when raising UnavailableVideoError
An OSError or IOError generally indicates something a little more
wrong than a "simple" UnavailableVideoError, so print the actual
traceback that leads to the exception. Otherwise meaningful postmortem
debugging a bug report is essentially infeasible.
2016-10-08 09:27:24 -04:00
Remita Amine
1dd58e14d8 [lego] improve info extraction and bypass geo restriction(closes #10872) 2016-10-08 08:33:18 +01:00
Simon Morgan
77da0152fe [yuvutu] Move regular expressions to place of usage. 2016-10-07 17:19:00 +01:00
Sergey M․
a054e619cc
release 2016.10.07 2016-10-07 22:27:15 +07:00
Sergey M․
dd4291f729
release 2016.10.07 2016.10.07 2016-10-07 22:25:30 +07:00
Simon Morgan
5d4d88151f [yuvutu] Export thumbnail URL 2016-10-07 16:23:16 +01:00