Skip to content
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

Httpsession requests typing #2699

Merged
merged 20 commits into from
Jun 25, 2024
Merged
Changes from 1 commit
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
6590674
update: HttpSession.request (copied from requests.Session.request)
tdadela May 2, 2024
e47e868
annotate HttpSession.request
tdadela May 4, 2024
125b723
feat(HttpSession): override requests.Session methods to provide bette…
tdadela May 4, 2024
9e6e388
Merge branch 'locustio:master' into httpsession-request-typing
tdadela May 4, 2024
5cd0675
fix(HttpSession): rest methods positional arguments
tdadela May 4, 2024
c716225
fix(HttpSession): rest methods pass positional arguments to super()
tdadela May 5, 2024
108e17d
minor: collections.abc import
tdadela May 5, 2024
f2b1247
minor: comments explaining ignores
tdadela May 5, 2024
ddc6bfe
Merge remote-tracking branch 'origin' into httpsession-request-typing
tdadela Jun 9, 2024
e464109
refactor: call self.requests directly inside HttpSession REST methods
tdadela Jun 18, 2024
e489d9b
refactor: use typing_extensions.Unpack only if python version < 3.11
tdadela Jun 19, 2024
472d597
feat: patch, post, put return type
tdadela Jun 23, 2024
6790aab
mypy: enable_incomplete_feature - Unpack; annotate all REST functions…
tdadela Jun 23, 2024
3500c23
fix: mypy & pyright errors
tdadela Jun 23, 2024
91f6aeb
fix: ignore[misc] in REST functions by changing TypedDicts
tdadela Jun 23, 2024
357d404
fix: pass all arguments in REST functions
tdadela Jun 23, 2024
c2140c8
fix: pass all arguments to the request function
tdadela Jun 23, 2024
a68a2e0
rm outdated ignore[override]
tdadela Jun 24, 2024
f9bcd7c
rm outdated ignore[misc], mypy setting
tdadela Jun 24, 2024
b04aec4
feat: HttpSession docstrings
tdadela Jun 24, 2024
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
fix: pass all arguments to the request function
  • Loading branch information
tdadela committed Jun 23, 2024
commit c2140c8359a6fa8b79145a311c34f12adaa64a98
2 changes: 1 addition & 1 deletion locust/clients.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ def request( # type: ignore[override]

start_time = time.time()
start_perf_counter = time.perf_counter()
response = self._send_request_safe_mode(method, url, **kwargs)
response = self._send_request_safe_mode(method, url, data=data, json=json, **kwargs)
response_time = (time.perf_counter() - start_perf_counter) * 1000

request_before_redirect = (response.history and response.history[0] or response).request
Expand Down
Loading