Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Soundcloud thing (nathom knows) #164

Closed
neiltho opened this issue Sep 3, 2021 · 1 comment
Closed

Soundcloud thing (nathom knows) #164

neiltho opened this issue Sep 3, 2021 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@neiltho
Copy link

neiltho commented Sep 3, 2021

StopIteration

0

at /Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/json/decoder.py:353 in raw_decode
349│ have extraneous data at the end.
350│
351│ """
352│ try:
→ 353│ obj, end = self.scan_once(s, idx)
354│ except StopIteration as err:
355│ raise JSONDecodeError("Expecting value", s, err.value) from None
356│ return obj, end
357│

The following error occurred when trying to handle this error:

JSONDecodeError

Expecting value: line 1 column 1 (char 0)

at /Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/json/decoder.py:355 in raw_decode
351│ """
352│ try:
353│ obj, end = self.scan_once(s, idx)
354│ except StopIteration as err:
→ 355│ raise JSONDecodeError("Expecting value", s, err.value) from None
356│ return obj, end
357│

If this was unexpected, please open a Bug Report at https://github.com/nathom/streamrip/issues/new/choose
neilthomas@Noels-MacBook-Air ~ % rip url https://soundcloud.com/ccottrill/sets/sling -vvv
DEBUG:streamrip:Config loaded
DEBUG:streamrip:Fetching url https://api-v2.soundcloud.com/resolve?url=https://soundcloud.com/ccottrill/sets/sling with params {'client_id': 'QFciLWLC1GS4P3EZvXIjA3jKhKO5pKB3', 'app_version': '1626941202', 'app_locale': 'en'}

StopIteration

0

at /Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/json/decoder.py:353 in raw_decode
349│ have extraneous data at the end.
350│
351│ """
352│ try:
→ 353│ obj, end = self.scan_once(s, idx)
354│ except StopIteration as err:
355│ raise JSONDecodeError("Expecting value", s, err.value) from None
356│ return obj, end
357│

The following error occurred when trying to handle this error:

Stack trace:

15 Library/Python/3.8/lib/python/site-packages/cleo/application.py:314 in run
312│
313│ try:
→ 314│ exit_code = self._run(io)
315│ except Exception as e:
316│ if not self._catch_exceptions:

14 Library/Python/3.8/lib/python/site-packages/rip/cli.py:624 in _run
622│ logger.addHandler(fh)
623│
→ 624│ super()._run(io)
625│
626│ def create_io(self, input=None, output=None, error_output=None):

13 Library/Python/3.8/lib/python/site-packages/cleo/application.py:409 in _run
407│ io.set_input(ArgvInput(argv))
408│
→ 409│ exit_code = self._run_command(command, io)
410│ self._running_command = None
411│

12 Library/Python/3.8/lib/python/site-packages/cleo/application.py:416 in _run_command
414│ def _run_command(self, command: Command, io: IO) -> int:
415│ if self._event_dispatcher is None:
→ 416│ return command.run(io)
417│
418│ # Bind before the console.command event,

11 Library/Python/3.8/lib/python/site-packages/cleo/commands/base_command.py:118 in run
116│ io.input.validate()
117│
→ 118│ status_code = self.execute(io)
119│
120│ if status_code is None:

10 Library/Python/3.8/lib/python/site-packages/cleo/commands/command.py:85 in execute
83│
84│ try:
→ 85│ return self.handle()
86│ except KeyboardInterrupt:
87│ return 1

9 Library/Python/3.8/lib/python/site-packages/rip/cli.py:84 in handle
82│
83│ if urls:
→ 84│ core.handle_urls(";".join(urls))
85│
86│ if len(core) > 0:

8 Library/Python/3.8/lib/python/site-packages/rip/core.py:167 in handle_urls
165│ self.extend(YoutubeVideo(u) for u in youtube_urls)
166│
→ 167│ parsed = self.parse_urls(url)
168│ if not parsed and len(self) == 0:
169│ if "last.fm" in url:

7 Library/Python/3.8/lib/python/site-packages/rip/core.py:476 in parse_urls
474│ parsed.extend(URL_REGEX.findall(url)) # Qobuz, Tidal, Dezer
475│ soundcloud_urls = SOUNDCLOUD_URL_REGEX.findall(url)
→ 476│ soundcloud_items = [
477│ self.clients["soundcloud"].get(u) for u in soundcloud_urls
478│ ]

6 Library/Python/3.8/lib/python/site-packages/rip/core.py:477 in
475│ soundcloud_urls = SOUNDCLOUD_URL_REGEX.findall(url)
476│ soundcloud_items = [
→ 477│ self.clients["soundcloud"].get(u) for u in soundcloud_urls
478│ ]
479│

5 Library/Python/3.8/lib/python/site-packages/streamrip/clients.py:1159 in get
1157│
1158│ if "http" in str(id):
→ 1159│ resp, _ = self._get(f"resolve?url={id}")
1160│ elif media_type == "track":
1161│ resp, _ = self._get(f"{media_type}s/{id}")

4 Library/Python/3.8/lib/python/site-packages/streamrip/clients.py:1251 in _get
1249│ r = self.session.get(url, params=params)
1250│
→ 1251│ return r.json(), r.status_code
1252│

3 Library/Python/3.8/lib/python/site-packages/requests/models.py:910 in json
908│ # used.
909│ pass
→ 910│ return complexjson.loads(self.text, **kwargs)
911│
912│ @Property

2 /Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/json/init.py:357 in loads
355│ parse_int is None and parse_float is None and
356│ parse_constant is None and object_pairs_hook is None and not kw):
→ 357│ return _default_decoder.decode(s)
358│ if cls is None:
359│ cls = JSONDecoder

1 /Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/json/decoder.py:337 in decode
335│
336│ """
→ 337│ obj, end = self.raw_decode(s, idx=_w(s, 0).end())
338│ end = _w(s, end).end()
339│ if end != len(s):

JSONDecodeError

Expecting value: line 1 column 1 (char 0)

at /Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/json/decoder.py:355 in raw_decode
351│ """
352│ try:
353│ obj, end = self.scan_once(s, idx)
354│ except StopIteration as err:
→ 355│ raise JSONDecodeError("Expecting value", s, err.value) from None
356│ return obj, end
357│

If this was unexpected, please open a Bug Report at https://github.com/nathom/streamrip/issues/new/choose

Bug Report

Current Behavior
A clear and concise description of the behavior.

Command used:

# Type the command that caused the bug here

Expected behavior
A clear and concise description of what you expected to happen.

streamrip Configuration File (find using rip config -o):

# Paste the contents of config.toml here
# REMOVE YOUR CREDENTIALS
[your]
config = "file"

Environment

  • streamrip version(s): [e.g. v0.5.2]
  • Python version: [e.g. 3.8]
  • OS: [e.g. OSX 10.13.4, Windows 10]

Traceback

# Paste the text that Python dumped on the error here
# Delete this section if there was no traceback

Possible Solution

Additional context/Screenshots
Add any other context about the problem here. If applicable, add screenshots to help explain.

@neiltho neiltho added the bug Something isn't working label Sep 3, 2021
nathom added a commit that referenced this issue Sep 7, 2021
@nathom
Copy link
Owner

nathom commented Sep 12, 2021

Fixed in v1.5.

@nathom nathom closed this as completed Sep 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants