Skip to content
This repository has been archived by the owner on Oct 13, 2024. It is now read-only.

fix(yt-dl): validate audio url and add retry logic #486

Closed
wants to merge 3 commits into from

Conversation

ReenigneArcher
Copy link
Member

@ReenigneArcher ReenigneArcher commented Jul 26, 2024

Description

After merging #481 there are issues with YouTube urls.

It seems the urls provided by youtube are inaccessible due to 403 errors. When these are sent to Plex, a 406 response is given. See ytdl-org/youtube-dl#32882 for more info.

  • Some retry logic was added.
  • Improved unit tests.

Screenshot

Issues Fixed or Closed

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Dependency update (updates to dependencies)
  • Documentation update (changes to documentation)
  • Repository update (changes to repository files, e.g. .github/...)

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated the in code docstring/documentation-blocks for new or existing methods/components

Branch Updates

LizardByte requires that branches be up-to-date before merging. This means that after any PR is merged, this branch
must be updated before it can be merged. You must also
Allow edits from maintainers.

  • I want maintainers to keep my branch updated

tests/conftest.py Outdated Show resolved Hide resolved
Copy link

codecov bot commented Jul 26, 2024

Codecov Report

Attention: Patch coverage is 31.66667% with 41 lines in your changes missing coverage. Please review.

Project coverage is 69.55%. Comparing base (29d0e8e) to head (e71e641).
Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
Contents/Code/youtube_dl_helper.py 32.20% 40 Missing ⚠️
Contents/Code/plex_api_helper.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #486      +/-   ##
==========================================
+ Coverage   67.98%   69.55%   +1.56%     
==========================================
  Files          12       12              
  Lines        1087     1120      +33     
==========================================
+ Hits          739      779      +40     
+ Misses        348      341       -7     
Flag Coverage Δ
Linux 68.92% <31.66%> (+0.94%) ⬆️
Windows 68.92% <31.66%> (+0.94%) ⬆️
macOS 69.55% <31.66%> (+1.56%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
Contents/Code/default_prefs.py 100.00% <ø> (ø)
Contents/Code/plex_api_helper.py 55.15% <0.00%> (+6.06%) ⬆️
Contents/Code/youtube_dl_helper.py 39.25% <32.20%> (-2.64%) ⬇️

... and 3 files with indirect coverage changes

@ReenigneArcher ReenigneArcher enabled auto-merge (squash) July 26, 2024 15:19
ReenigneArcher referenced this pull request in ytdl-org/youtube-dl Jul 26, 2024
tests/conftest.py Outdated Show resolved Hide resolved
tests/conftest.py Outdated Show resolved Hide resolved
@ReenigneArcher ReenigneArcher changed the title tests: increase time to wait for themes tests: fix unit tests Jul 26, 2024
@ReenigneArcher ReenigneArcher force-pushed the ReenigneArcher-patch-1 branch 9 times, most recently from fda0e82 to 978b1f0 Compare July 27, 2024 21:14
@ReenigneArcher ReenigneArcher changed the title tests: fix unit tests fix(yt-dl): validate audio url and add retry logic Jul 27, 2024
Copy link

sonarcloud bot commented Aug 11, 2024

@ReenigneArcher ReenigneArcher deleted the ReenigneArcher-patch-1 branch September 22, 2024 01:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant