Commit Graph

87 Commits

Author SHA1 Message Date
MarkusHackspacher 82f41f4c21 sorting imports
with isort -y -rc
see #393
2018-07-24 11:08:10 +02:00
MarkusHackspacher 9c2faec85a fix E241 multiple spaces after ':' 2018-05-27 20:29:39 +02:00
Eric Le Lay c502e67397 fix parse_youtube_url(None) exception
urlsplit returns empty byte(s) instead of empty str(s)
2018-05-24 21:54:38 +02:00
Eric Le Lay 368a20e5df
Merge pull request #437 from XIncognito10/add_youtube_parsing
Implements #384: Youtube Feeds without API
2018-04-29 11:48:08 +02:00
Xincognito10 5cc67c2289 Fixed Exception statement in youtube.py 2018-04-22 08:21:24 -05:00
Xincognito10 31c479b872 Overhauled get_real_cover to use new api-less youtube feeds
* Final tests complete
2018-04-16 05:14:02 -05:00
Xincognito10 7de1ff1719 * Cleaned up import statements
* Fixed get_real_cover to work with the new api-less youtube fetching
    * get_real_cover now uses the channel id fetched from the feed
    * The regex has been replaced with a dedicated html parser
2018-04-16 05:10:14 -05:00
Xincognito10 a245518dbc Implemented api-less youtube feed parsing (final commit)
* Phased out the resolve_v3_url which has been replaced by
parse_youtube_url

* Updated parse_youtube_url to use logging system
2018-04-10 03:04:50 -05:00
Xincognito10 c6b6ae7eda Implemented api-less youtube feed parsing (final commit)
* Phased out the resolve_v3_url which has been replaced by
parse_youtube_url

* Updated parse_youtube_url to use logging system
2018-04-10 03:00:28 -05:00
Xincognito10 14315c6c72 Implemented api-less youtube feeds
users, playlists and channels are supported
2018-04-08 16:08:05 -05:00
MarkusHackspacher 710d8735d4 fix E221 multiple spaces before operator 2018-03-18 00:47:54 +01:00
MarkusHackspacher 5f7af2d099 fix E262 inline comment should start with '# ' 2018-02-17 10:14:48 +01:00
MarkusHackspacher 0c18a43d13 fix E302 and E303, only blank line change 2018-02-11 00:22:00 +01:00
MarkusHackspacher 9dca8e0506 fix E306 expected 1 blank line before a nested definition 2018-02-06 18:33:52 +01:00
Thomas Perl 98ec45a712 Update copyright years (2018) 2018-01-28 19:39:53 +01:00
Eric Le Lay c937184987 youtube get_real_download_url: fix exception with bytes
req.read() returns bytes instead of string
2018-01-01 15:58:42 +01:00
Eric Le Lay b7733877dd youtube: predefined rss feed if possible (fix #371)
not all youtube channels have an RSS link, so bypass autodiscovery
by directly getting the feed url
2018-01-01 15:57:25 +01:00
Thomas Perl 7b46a0ee72 Update copyright years (2017) 2017-12-16 13:54:59 +01:00
Thomas Perl 0122e8cc00 Merge branch 'master' into gtk3 2016-12-18 13:12:04 +01:00
Eric Le Lay fd0f9c2403 remove pre-python 2.6 compat code 2016-11-26 16:05:17 +01:00
Eric Le Lay 592146cd76 urlopen().read() must be converted to string
when it's searched by re, etc.
FIXME: still work to do to validate some uses are ok
2016-11-26 15:28:15 +01:00
Thomas Perl 5a7c30b359 Port to Python 3 2016-11-21 23:13:46 +01:00
Hiltronix b76aab04d4 YouTube Show Image Sometimes Low-Res
The link being parsed for the YouTube cover art image is sometimes only 100x100px, it appears to be inconsistent from show to show, sometimes 100x100, and sometimes 900x900px.  There is a link in the channel page source that appears to always have a 900x900px image.

This change looks for the "new" link first, to grab the higher quality image.  If not found it falls back to the original link.

Here are two examples of YouTube channels showing the links to the two different sized images:

The Ben Heck Show
https://www.youtube.com/user/thebenheckshow

Element 14
https://www.youtube.com/user/element14
2016-11-20 11:55:53 -06:00
Thomas Perl 28075c09dd Remove QML UI 2016-02-03 19:54:33 +01:00
Thomas Perl 36eefc8a30 Update copyright years (2016) 2016-01-15 15:22:52 +01:00
Danilo Shiga f44590e43f Adding another pattern for youtube feed url list 2015-11-28 12:34:33 -02:00
Thomas Perl c71391552a youtube: Fix cover art downloading (bug 2014) 2015-07-01 22:59:09 +02:00
Thomas Perl aa72634950 Update copyright years (2015) 2015-05-24 19:33:39 +02:00
Thomas Perl ed1ea2d68e QML UI: Add YouTube API key text entry + migrate button 2015-05-20 21:50:10 +02:00
Thomas Perl 4e74b0bf99 YouTube: Auto-resolve URLs also in CLI and QML 2015-05-20 21:19:20 +02:00
Thomas Perl fd1002060c YouTube: Support V3 API via user-supplied key (bug 1999)
This adds auto-discovery of the channel ID and new-style feed for old-style
(username-based) feed URLs when the V3 API key is available, and also adds an
extra menu item for migrating subscriptions.
2015-05-20 21:10:57 +02:00
Thomas Perl 376209ae8a YouTube: Match _ in channel URLs
Thanks to somini for the bug report.
2015-01-18 11:30:28 +01:00
Thomas Perl c022d9e453 Gtk UI: New podcast directory UI 2014-10-22 21:23:06 +02:00
Thomas Perl 312cd86344 YouTube: Add support for channels, rewrite URL matching
Better support for new-style channels, also fix downloading of
cover art for all possible YouTube feed URLs.
2014-09-04 11:21:00 +02:00
Thomas Perl 91a042b1f6 Sailfish: Remove obsolete, Qt4-based Sailfish QML UI
The current Sailfish UI is maintained as part of gPodder 4 in
gpodder-core, gpodder-ui-qml and gpodder-sailfish. The code
removed here was part of the old, Qt4-based Sailfish Alpha
SDK-based port that was still using PySide and Python 2.
2014-06-28 13:48:13 +02:00
Thomas Perl ad6523b74e Merge pull request #115 from pieska/youtube-no-more-extra-signature
signature is in the url itself now, not as an extra parameter any longer
2014-03-01 11:14:23 +01:00
Andreas Piesk a628d07356 signature is in the url itself now, not as an extra parameter any longer 2014-02-28 21:23:08 +01:00
Thomas Perl 553e35f219 Update copyright years (2014) 2014-02-27 21:55:13 +01:00
Andreas Piesk fb5c62e5c9 fix regexp tp prevent failure if map is at the very end 2013-10-26 16:57:30 +02:00
Andreas Piesk 724467a1a7 regexp fails if url_encoded_fmt_stream_map is first argument 2013-10-16 22:18:01 +02:00
Thomas Perl bda982be02 Update copyright years for 2013 2013-03-05 16:38:48 +01:00
Thomas Perl 39daccbd92 QML UI: Initial support for Sailfish Silica 2013-03-01 11:19:18 +01:00
Thomas Perl aa488bccdf YouTube: Fix directory search (bug 1760)
For users who set their realname as display name,
search results resulted in non-working feeds.

Now using the username from the URI to fix this.
2013-01-27 13:24:30 +01:00
Thomas Perl 16ddd925a5 YouTube: Fix downloading on Harmattan 2012-11-23 12:03:41 +01:00
Thomas Perl 811323f5eb YouTube: Remove dependency on OrderedDict
We still need to support Python 2.6 easily, as this is
what we have on MeeGo 1.2 Harmattan.
2012-11-18 21:35:21 +01:00
Thomas Perl 9e218bc3b5 YouTube: Cleanup the format selection patch 2012-10-23 13:41:40 +02:00
Chionsas 14ab2d0478 YouTube: Gtk UI for video quality selection (pull request 19)
1) Redid the youtube video format list (added fallbacks for each quality
setting) and added a new config key youtube.preferred_format_ids, that
accepts a list of supported quality ids.

2) Added a GUI setting switcher that lets a user pick between predefined
video quality settings and respects the 'custom' setting.  'Custom'
should currently only be used if the user prefers 3D formats or 3GP.
All other variants are in the normal settings with sane fallbacks.

Existing users will not feel any change (current fmt=18 default is
respected). Only the default fallback for get_real_download_url() was
changed (to 720p), but that will never be called unless the user clears
her youtube.preferred_fmt_id variable.
2012-10-23 13:41:31 +02:00
Thomas Perl 6733a23f0d YouTube: Add support for https:// links 2012-09-28 16:02:50 +02:00
Andreas Piesk d1d78ed685 YouTube: Fix the new 403 issue (bug 1665) 2012-09-28 16:01:04 +02:00
Thomas Perl 6db58176f6 YouTube: Parse error messages, improve downloading 2012-09-23 20:29:29 +02:00