diff --git a/.github/ISSUE_TEMPLATE/bug_report.yaml b/.github/ISSUE_TEMPLATE/bug_report.yaml index 1d1f2e9..8cd7394 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yaml +++ b/.github/ISSUE_TEMPLATE/bug_report.yaml @@ -30,24 +30,59 @@ body: For example: `rip url https://example.com` + - type: markdown + attributes: + value: "```\n" + - type: textarea validations: required: true attributes: - label: Traceback - description: If there was any error output, paste it here + label: Debug Traceback + description: | + Run your command, with `-vvv` appended to it, and paste the output here. + For example, if the problematic command was `rip url https://example.com`, then + you would run `rip url https://example.com -vvv` to get the debug logs. + Make sure to check the logs for any personal information such as emails and remove them. + + - type: markdown + attributes: + value: "```" - type: textarea attributes: label: Screenshots and recordings description: | - If applicable, add screenshots to help explain your problem. You can also record an asciinema session: https://asciinema.org/ + If applicable, add screenshots to help explain your problem. + You can also record an asciinema session: https://asciinema.org/ + + - type: markdown + attributes: + value: "```\n" + + - type: textarea + validations: + required: true + attributes: + label: Config File + description: | + Find the config file using `rip config --open` and paste the contents here. + Make sure you REMOVE YOUR CREDENTIALS! + + - type: markdown + attributes: + value: "```" + - type: input validations: required: true attributes: label: Operating System - placeholder: e.g. Windows 10, Ubuntu 20.04, Arch Linux, macOS 10.15... + placeholder: e.g. Windows, Linux, macOS... + + - type: markdown + attributes: + value: "```\n" - type: input validations: @@ -57,7 +92,15 @@ body: description: Run `rip --version` to check. placeholder: e.g. 1.5 + - type: markdown + attributes: + value: "```" + - type: textarea attributes: label: Additional context description: Add any other context about the problem here. + + - type: markdown + attributes: + value: "Thanks for completing our form!" diff --git a/.github/ISSUE_TEMPLATE/config.yaml b/.github/ISSUE_TEMPLATE/config.yaml new file mode 100644 index 0000000..3ba13e0 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yaml @@ -0,0 +1 @@ +blank_issues_enabled: false diff --git a/streamrip/utils.py b/streamrip/utils.py index a64b4f8..5412b78 100644 --- a/streamrip/utils.py +++ b/streamrip/utils.py @@ -342,13 +342,24 @@ def get_cover_urls(resp: dict, source: str) -> dict: } if source == "deezer": + resp_keys = ("cover", "cover_medium", "cover_large", "cover_xl") + resp_keys_fallback = ( + "picture", + "picture_medium", + "picture_large", + "picture_xl", + ) cover_urls = { - sk: resp.get(rk) # size key, resp key - for sk, rk in zip( + sk: resp.get( + rk, resp.get(rkf) + ) # size key, resp key, resp key fallback + for sk, rk, rkf in zip( COVER_SIZES, - ("cover", "cover_medium", "cover_large", "cover_xl"), + resp_keys, + resp_keys_fallback, ) } + print(cover_urls) if cover_urls["large"] is None and resp.get("cover_big") is not None: cover_urls["large"] = resp["cover_big"]