Skip to content

Commit

Permalink
Update streamlink to 3.0.0
Browse files Browse the repository at this point in the history
OAuth fork is not needed anymore because streamlink now supports custom HTTP headers for API requests.
  • Loading branch information
TheDrHax committed Dec 12, 2021
1 parent 75d0d00 commit 20fe697
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
requests
python-dateutil
git+https://github.com/TheDrHax/streamlink[email protected]
streamlink==3.0.3
docopt==0.6.2
praat-parselmouth==0.4.0
numpy<1.19.0,>=1.16.0
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

EXTRAS = {
'record': [
'streamlink>=2.4.0',
'streamlink>=3.0.0',
'parse>=1.19.0'
],
'offset': [
Expand Down
2 changes: 1 addition & 1 deletion twitch_utils/record.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def _args(self) -> list:
'hls-segment-threads': self.threads}

if self.oauth:
params['twitch-oauth-token'] = self.oauth
params['twitch-api-header'] = f'Authorization=OAuth {self.oauth}'

if self.start > 0:
params['hls-start-offset'] = math.floor(self.start)
Expand Down
2 changes: 1 addition & 1 deletion twitch_utils/twitch.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ class TwitchAPI:
def _session(token: str) -> Session:
s = Session()
s.headers['Client-ID'] = 'kimne78kx3ncx6brgo4mv6wki5h1ko'
s.headers['Authorization'] = f'Bearer {token}'
s.headers['Authorization'] = f'OAuth {token}'
return s

def __init__(self, oauth: str):
Expand Down

0 comments on commit 20fe697

Please sign in to comment.