Skip to content

Fix authentication content node dumping#1241

Merged
AndreyNikiforov merged 2 commits intoicloud-photos-downloader:masterfrom
AndreyNikiforov:fix/authentication-content-node-dumping
Sep 1, 2025
Merged

Fix authentication content node dumping#1241
AndreyNikiforov merged 2 commits intoicloud-photos-downloader:masterfrom
AndreyNikiforov:fix/authentication-content-node-dumping

Conversation

@AndreyNikiforov
Copy link
Copy Markdown
Collaborator

No description provided.

AndreyNikiforov and others added 2 commits September 1, 2025 17:49
Previously, response_body() incorrectly used response.raw.stream which is
not a valid attribute, causing content to be skipped for authentication
requests and other non-streaming responses that needed content capture.

Changes:
- Add is_streaming_response() function using response.raw.isclosed()
- Update response_body() to properly detect streaming vs non-streaming
- Add comprehensive tests with local HTTP server
- Verify JSON/text responses include content in HAR entries
- Verify streaming responses skip content to prevent memory leaks
- Test with multi-GB streams to ensure no memory consumption

This fixes authentication request logging where content was missing
from HAR entries, improving debugging capabilities for auth issues.

Related to icloud-photos-downloader#1240

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
Add entry for the HTTP response content capture fix that ensures
authentication requests and other non-streaming responses properly
include their content in HAR entries for improved debugging.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
@AndreyNikiforov AndreyNikiforov merged commit 278a035 into icloud-photos-downloader:master Sep 1, 2025
398 checks passed
@AndreyNikiforov AndreyNikiforov deleted the fix/authentication-content-node-dumping branch September 1, 2025 18:19
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