Change Log¶
asyncprawcore follows semantic versioning.
Unreleased¶
3.1.0 (2026/06/10)¶
Added
Support for Python 3.14.
Add an
__all__to theasyncprawcorepackage to explicitly define its public API.Add a
py.typedmarker (PEP 561) so that downstream projects can type check against asyncprawcore’s inline annotations.Add read-only
Session.authorizer,Session.rate_limiter, andSession.requestorproperties, aBaseAuthorizer.authenticatorproperty, and aBaseAuthenticator.requestorproperty, so that downstream code can reach these objects without accessing protected attributes.Add Sphinx-based documentation, published at https://asyncprawcore.readthedocs.io/.
Changed
Improved exception message when
asyncio.TimeoutErroris raised.Improve source docstrings and type annotations so that references render cleanly in the new documentation.
Fixed type hinting for
dataandparamsinRequestor.request().Pass
filestoaiohttp.ClientSession.request()inRequestor.request()correctly again.Widen the
authorizerparameter ofsession()toBaseAuthorizerto matchSession, so that passing anImplicitAuthorizerorDeviceIDAuthorizertype checks.Widen the
data,files,json, andparamsparameter annotations ofSession.request()to reflect the values it already accepts at runtime (for example a non-dictdatabody, alistjsonpayload, and anyIOfile object), so that callers no longer need to cast these arguments.
Removed
Support for Python 3.9, which is end-of-life on 2025-10-31.
3.0.2 (2025/08/06)¶
Changed
Improved type hinting.
3.0.1 (2025/08/02)¶
Fixed
Increase half-second delay introduced in
3.0.0to a full second delay.
3.0.0 (2025/08/02)¶
Changed
Session creation is now delayed and existing sessions will be reused.
Drop support for Python 3.8, which was end-of-life on 2024-10-07.
RateLimiterattributenext_request_timestamphas been removed and replaced withnext_request_timestamp_ns.
Fixed
Add a half-second delay when there are no more requests in the rate limit window and the window has zero seconds remaining to avoid a semi-rare case where Reddit will return a 429 response resulting in a
TooManyRequestsexception.
Removed
Remove
RateLimiterattributereset_timestamp.
2.4.0 (2023/11/27)¶
Changed
Drop support for Python 3.6, which was end-of-life on 2021-12-23.
DeviceIDAuthorizercan be now used withTrustedAuthenticator.Updated rate limit algorithm to better handle Reddit’s new rate limits.
Drop support for Python 3.7, which was end-of-life on 2023-06-27.
2.3.0 (2021/07/27)¶
Added
301 redirects result in a
Redirectexception.Requestoris now initialized with atimeoutparameter.ScriptAuthorizer,ReadOnlyAuthorizer, andDeviceIDAuthorizerhave a new parameter,scopes, which determines the scope of access requests.Retry 408 “Request Timeout” HTTP responses.
2.2.1 (2021/07/06)¶
Changed
Cast non-string objects to string when preprocessing
dataandparams.
2.2.0 (2021/06/15)¶
Added
Support 202 “Accepted” HTTP responses.
Fixed
The expected HTTP response status code for a request made with the proper credentials to api/v1/revoke_token has been changed from 204 to 200.
2.1.0 (2021/06/15)¶
Added
Add a
URITooLongexception.ScriptAuthorizerhas a new parametertwo_factor_callbackthat supplies OTPs (One-Time Passcodes) whenScriptAuthorizer.refresh()is called.Add a
TooManyRequestsexception.
Fixed
Fix
RuntimeWarningwhen executing pre/post refresh token callbacks.
2.0.0 (2021-02-23)¶
Added
Authorizeroptionally takes apre_refresh_callbackkeyword argument. If provided, the function will called with the instance ofAuthorizerprior to refreshing the access and refresh tokens.Authorizeroptionally takes apost_refresh_callbackkeyword argument. If provided, the function will called with the instance ofAuthorizerafter refreshing the access and refresh tokens.
Changed
The
refresh_tokenargument toAuthorizermust now be passed by keyword, and cannot be passed as a positional argument.
1.5.1 (2021-01-25)¶
Changed
Improved preprocessing for
dataandparamsinSession.request().
1.5.0 (2020-09-28)¶
Added
Requestor.request()can be given a timeout parameter to control the amount of time to wait for a request to succeed.
Changed
Added preprocessing for
dataandparamsinasyncprawcore.Session.request()for compatibility withaiohttp.
Fixed
RateLimiter will not sleep longer than next_request_timestamp.
Fixed
Keys with a
Nonevalue in thedataorparamsparameters forasyncprawcore.Session.request()are now dropped asaiohttp.ClientSession.request()does not acceptNonevalues indataandparams.Keys with a boolean value in the
paramsparameter forasyncprawcore.Session.request()are now casted to a string asaiohttp.ClientSession.request()does not accept boolean values inparams.
1.4.0.post2 (2020-07-12)¶
Fixed
How files are handled.
datais now able to be passed withfilessince asyncpraw can make requests with both parameters.Fixed
SpecialExceptionnot able to getresponse.json()since it is a coroutine.
1.4.0.post1 (2020-07-03)¶
Fixed
Documentation errors.
authorize_urlwill correctly return astrinstead ofyarl.URL().
1.4.0 (2020-06-20)¶
Converted from
requeststoaiohttpfor asynchronous operation.Updated upto version 1.4.0 of prawcore.
Forked from praw-dev/prawcore