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

[FEATURE] Add throttle_protection plugin #799

Merged
merged 7 commits into from
Nov 5, 2023
Merged

Conversation

jmbannon
Copy link
Owner

@jmbannon jmbannon commented Nov 5, 2023

Provides options to make ytdl-sub look more 'human-like' to protect from throttling. For range-based values, a random number will be chosen within the range to avoid sleeps looking scripted.

Usage:

    throttle_protection:
      sleep_per_download_s:
        min: 2.2
        max: 10.8
      sleep_per_subscription_s:
        min: 9.0
        max: 14.1
      max_downloads_per_subscription:
        min: 10
        max: 36
      subscription_download_probability: 1.0

Copy link

codecov bot commented Nov 5, 2023

Codecov Report

Merging #799 (e5c0cd0) into master (19eee28) will decrease coverage by 0.02%.
The diff coverage is 96.39%.

@@            Coverage Diff             @@
##           master     #799      +/-   ##
==========================================
- Coverage   96.84%   96.82%   -0.02%     
==========================================
  Files          78       79       +1     
  Lines        5003     5108     +105     
==========================================
+ Hits         4845     4946     +101     
- Misses        158      162       +4     
Files Coverage Δ
src/ytdl_sub/cli/parsers/dl.py 100.00% <100.00%> (ø)
src/ytdl_sub/config/plugin_mapping.py 96.66% <100.00%> (ø)
src/ytdl_sub/config/preset.py 97.41% <100.00%> (ø)
src/ytdl_sub/validators/validators.py 99.18% <83.33%> (-0.82%) ⬇️
src/ytdl_sub/plugins/throttle_protection.py 96.73% <96.73%> (ø)

@jmbannon jmbannon changed the title [FEATURE] Add throttle_protection plugin [FEATURE] Add throttle_protection plugin Nov 5, 2023
@jmbannon jmbannon merged commit f1a2187 into master Nov 5, 2023
35 checks passed
@jmbannon jmbannon deleted the j/throttle-protection branch November 5, 2023 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant