[py] Missing Headers Assignment in Network Class’s _on_request() by shbenzer · Pull Request #15736 · SeleniumHQ/selenium
User description
🔗 Related Issues
💥 What does this PR do?
Addresses missing header assignment discovered in #15735 using https://w3c.github.io/webdriver-bidi/#module-network-definition
🔄 Types of changes
- Bug fix (backwards compatible)
PR Type
Bug fix
Description
-
Fixes missing
headersassignment in Network class's_on_request -
Ensures request headers are properly captured in BiDi events
Changes walkthrough 📝
| Relevant files | |||
|---|---|---|---|
| Bug fix |
|
Need help?
Type /help how to ...in the comments thread for any questions about Qodo Merge usage.Check out the documentation for more information.
shbenzer
changed the title
[py] Missing Headers Assignment in _on_request()
[py] Missing Headers Assignment in Network Class’s _on_request()
shbenzer
marked this pull request as ready for review
PR Reviewer Guide 🔍
Here are some key observations to aid the review process:
| ⏱️ Estimated effort to review: 1 🔵⚪⚪⚪⚪ |
| 🧪 No relevant tests |
| 🔒 No security concerns identified |
⚡ Recommended focus areas for reviewTest Coverage
|
PR Code Suggestions ✨
Explore these optional code suggestions:
| Category | Suggestion | Impact |
| Learned best practice |
Use empty dict as defaultUse an empty dictionary as the default value for headers instead of None. This py/selenium/webdriver/common/bidi/network.py [138] -headers=event_data.params["request"].get("headers", None), +headers=event_data.params["request"].get("headers", {}),
Suggestion importance[1-10]: 6__ Why: | Low |
| ||
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
This was referenced
Sep 12, 2025This was referenced
Sep 19, 2025This was referenced
Oct 1, 2025This was referenced
Dec 21, 2025This was referenced
Jan 19, 2026This was referenced
Feb 16, 2026This was referenced
Feb 23, 2026This 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