8000 Add all GitHubSession attributes to __attrs__. #946 · wickmaster/github3.py@8197cba · GitHub
[go: up one dir, main page]

Skip to content

Commit 8197cba

Browse files
committed
Add all GitHubSession attributes to __attrs__. sigmavirus24#946
GitHubSession objects can't be properly copied without the __attrs__ list being correct. The requests Session object implements __getstate__ using the __attrs__ list.
1 parent 3e79aae commit 8197cba

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/github3/session.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,9 @@ class GitHubSession(requests.Session):
9191
__attrs__ = requests.Session.__attrs__ + [
9292
"base_url",
9393
"two_factor_auth_cb",
94+
"default_connect_timeout",
95+
"default_read_timeout",
96+
"request_counter",
9497
]
9598

9699
def __init__(self, default_connect_timeout=4, default_read_timeout=10):

0 commit comments

Comments
 (0)
0