Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Y
ytdl-patched
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lesmiscore
ytdl-patched
Commits
1619836c
Unverified
Commit
1619836c
authored
3 years ago
by
raleeper
Committed by
GitHub
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
[crackle] Look for non-DRM formats (#1938)
Authored by: raleeper
parent
e3c7d495
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
yt_dlp/extractor/crackle.py
+21
-19
21 additions, 19 deletions
yt_dlp/extractor/crackle.py
with
21 additions
and
19 deletions
yt_dlp/extractor/crackle.py
+
21
−
19
View file @
1619836c
...
...
@@ -23,32 +23,35 @@
class
CrackleIE
(
InfoExtractor
):
_VALID_URL
=
r
'
(?:crackle:|https?://(?:(?:www|m)\.)?(?:sony)?crackle\.com/(?:playlist/\d+/|(?:[^/]+/)+))(?P<id>\d+)
'
_TESTS
=
[{
#
geo restricted to CA
'
url
'
:
'
https://www.crackle.com/
andromeda/2502343
'
,
#
Crackle is available in the United States and territories
'
url
'
:
'
https://www.crackle.com/
thanksgiving/2510064
'
,
'
info_dict
'
:
{
'
id
'
:
'
25
02343
'
,
'
id
'
:
'
25
10064
'
,
'
ext
'
:
'
mp4
'
,
'
title
'
:
'
Under The Night
'
,
'
description
'
:
'
md5:
d2b8ca816579ae8a7bf28bfff8cefc8a
'
,
'
duration
'
:
2583
,
'
title
'
:
'
Touch Football
'
,
'
description
'
:
'
md5:
cfbb513cf5de41e8b56d7ab756cff4df
'
,
'
duration
'
:
1398
,
'
view_count
'
:
int
,
'
average_rating
'
:
0
,
'
age_limit
'
:
1
4
,
'
genre
'
:
'
Action, Sci-Fi
'
,
'
creator
'
:
'
Allan Kroeker
'
,
'
artist
'
:
'
Keith Hamilton Cobb, Kevin Sorbo, Lisa Ryder, Lexa Doig, Robert Hewitt Wolfe
'
,
'
release_year
'
:
20
00
,
'
series
'
:
'
Andromeda
'
,
'
episode
'
:
'
Under The Night
'
,
'
age_limit
'
:
1
7
,
'
genre
'
:
'
Comedy
'
,
'
creator
'
:
'
Daniel Powell
'
,
'
artist
'
:
'
Chris Elliott, Amy Sedaris
'
,
'
release_year
'
:
20
16
,
'
series
'
:
'
Thanksgiving
'
,
'
episode
'
:
'
Touch Football
'
,
'
season_number
'
:
1
,
'
episode_number
'
:
1
,
},
'
params
'
:
{
# m3u8 download
'
skip_download
'
:
True
,
}
},
'
expected_warnings
'
:
[
'
Trying with a list of known countries
'
],
},
{
'
url
'
:
'
https://www.sonycrackle.com/
andromeda/2502343
'
,
'
url
'
:
'
https://www.sonycrackle.com/
thanksgiving/2510064
'
,
'
only_matching
'
:
True
,
}]
...
...
@@ -129,7 +132,6 @@ def _real_extract(self, url):
break
ignore_no_formats
=
self
.
get_param
(
'
ignore_no_formats_error
'
)
allow_unplayable_formats
=
self
.
get_param
(
'
allow_unplayable_formats
'
)
if
not
media
or
(
not
media
.
get
(
'
MediaURLs
'
)
and
not
ignore_no_formats
):
raise
ExtractorError
(
...
...
@@ -143,9 +145,9 @@ def _real_extract(self, url):
for
e
in
media
.
get
(
'
MediaURLs
'
)
or
[]:
if
e
.
get
(
'
UseDRM
'
):
has_drm
=
True
if
not
allow_unplayable_formats
:
continue
format_url
=
url_or_none
(
e
.
get
(
'
Path
'
))
format_url
=
url_or_none
(
e
.
get
(
'
DRMPath
'
))
else
:
format_url
=
url_or_none
(
e
.
get
(
'
Path
'
))
if
not
format_url
:
continue
ext
=
determine_ext
(
format_url
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment