8000 gh-86809: Add support for HTTP Range header in HTTPServer by lyc8503 · Pull Request #118949 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-86809: Add support for HTTP Range header in HTTPServer #118949

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
wants to merge 24 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add link to github discussion
  • Loading branch information
lyc8503 committed Jan 13, 2025
commit 06b8c80823102060697c17be5c9687326a6f6ae4
1 change: 1 addition & 0 deletions Lib/http/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -779,6 +779,7 @@ def send_head(self):
start, end = self._range
if start is None:
# parse_range() collapses (None, None) to None as it's invalid
# https://github.com/python/cpython/pull/118949#discussion_r1912397525
assert end is not None
# `end` here means suffix length
start = max(0, fs.st_size - end)
Expand Down
Loading
0