-
-
Notifications
You must be signed in to change notification settings - Fork 54
refactor: Refactor Download Management to Prevent Task Starvation #1713
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
Open
Barbarella6666666
wants to merge
17
commits into
Cyberdrop-DL:main
Choose a base branch
from
Barbarella6666666:fix-immediate-downloads
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 7 commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
3cc5c5f
fix: replace downloads TaskGroup with asyncio.Queue for task decoupling
Barbarella6666666 25f838f
feat: add download dispatcher that creates independent tasks from queue
Barbarella6666666 d41ba2c
refactor: wire dispatcher into __call__ and remove downloads TaskGroup
Barbarella6666666 508b8da
fix: run scrape-done UI callback as standalone task
Barbarella6666666 83c6d81
Merge remote-tracking branch 'other-repo/fix/immediate-downloads' int…
Barbarella6666666 193c3e6
fix: RUF006 Store a reference to the return value of `asyncio.create_…
Barbarella6666666 17fcdf8
refactor: fix ruff formatting
Barbarella6666666 798d1e6
refactor: add smoke test
NTFSvolume 80b503e
fix: use _done event in dispatcher loop and TaskGroup for shutdown
Barbarella6666666 5c7285b
refactor: move hide_scrape_panel into _download_dispatcher
Barbarella6666666 a0e29f3
feat: enable eager task factory to prevent download starvation
Barbarella6666666 7b7d895
fix: handle cancellation and Ctrl+C in download dispatcher
Barbarella6666666 90a0282
fix: replace broken TaskGroup+shield drain with asyncio.gather
Barbarella6666666 5a5986c
fix: remove fake download that intercepted real downloads
Barbarella6666666 1c341a3
fix: handle Ctrl+C by cancelling dispatcher instead of draining
Barbarella6666666 c344d65
refactor: replace eager_task_factory with worker pool for downloads
Barbarella6666666 12cfef7
fix: include pending queue in download queue count
Barbarella6666666 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should wait on done event. We can actually use a taskgroup