projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9510709
)
[pluralsight] Detect blocked account error message (#12070)
author
Sergey M․
<dstftw@gmail.com>
Fri, 10 Feb 2017 15:48:11 +0000
(22:48 +0700)
committer
Sergey M․
<dstftw@gmail.com>
Fri, 10 Feb 2017 15:48:11 +0000
(22:48 +0700)
youtube_dl/extractor/pluralsight.py
patch
|
blob
|
history
diff --git
a/youtube_dl/extractor/pluralsight.py
b/youtube_dl/extractor/pluralsight.py
index 5c798e874837ff1704650fa991d5b07cde8ab210..00b275eb14ecb5aaa314dcfae1a7860af1ac6109 100644
(file)
--- a/
youtube_dl/extractor/pluralsight.py
+++ b/
youtube_dl/extractor/pluralsight.py
@@
-92,6
+92,10
@@
class PluralsightIE(PluralsightBaseIE):
raise ExtractorError('Unable to login: %s' % error, expected=True)
if all(p not in response for p in ('__INITIAL_STATE__', '"currentUser"')):
+ BLOCKED = 'Your account has been blocked due to suspicious activity'
+ if BLOCKED in response:
+ raise ExtractorError(
+ 'Unable to login: %s' % BLOCKED, expected=True)
raise ExtractorError('Unable to log in')
def _get_subtitles(self, author, clip_id, lang, name, duration, video_id):