Skip to content
Myr

Respect trust_env on redirect.

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Cory Benfield · committed by Cory Benfield · parent 326a22e · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:requests/sessions.py+1 added-1 removed
167 unmodified lines
168 del headers['Authorization']169170 # However, .netrc might have more auth for us. Let's get it if it171 # does.172 new_auth = get_netrc_auth(url)172 new_auth = get_netrc_auth(url) if self.trust_env else None173 if new_auth is not None:174 prepared_request.prepare_auth(new_auth)175176 resp = self.send(
392 unmodified lines