作成者 | SHA1 | メッセージ | 日付 |
---|---|---|---|
David Robertson |
1026776380
|
mypy plugin to check `@cached` return types (#14911)
Co-authored-by: David Robertson <davidr@element.io> Co-authored-by: Patrick Cloke <patrickc@matrix.org> Co-authored-by: Erik Johnston <erik@matrix.org> Assert that the return type of callables wrapped in @cached and @cachedList are cachable (aka immutable). |
7ヶ月前 |
Patrick Cloke |
aa483cb4c9
|
Update ruff config (#16283)
Enable additional checks & clean-up unneeded configuration. |
8ヶ月前 |
Patrick Cloke |
1f55c04cbc
|
Improve type hints for cached decorator. (#15658)
The cached decorators always return a Deferred, which was not properly propagated. It was close enough when wrapping coroutines, but failed if a bare function was wrapped. |
1年前 |
Mathieu Velten |
6bd8763804
|
Add cache invalidation across workers to module API (#13667)
Signed-off-by: Mathieu Velten <mathieuv@matrix.org> |
1年前 |
David Robertson |
5331fb5b47
|
allow `on_invalidate=None` in `@cached` methods (#12769) | 2年前 |
David Robertson |
30c8e7e408
|
Make `scripts-dev` pass `mypy --disallow-untyped-defs` (#12356)
Not enforced in config yet. One day. |
2年前 |
Jonathan de Jong |
4b965c862d
|
Remove redundant "coding: utf-8" lines (#9786)
Part of #9744 Removes all redundant `# -*- coding: utf-8 -*-` lines from files, as python 3 automatically reads source code as utf-8 now. `Signed-off-by: Jonathan de Jong <jonathan@automatia.nl>` |
3年前 |
Eric Eastwood |
0a00b7ff14
|
Update black, and run auto formatting over the codebase (#9381)
- Update black version to the latest
- Run black auto formatting over the codebase
- Run autoformatting according to [`docs/code_style.md
`](
|
3年前 |
Patrick Cloke |
5d34f40d49
|
Add type hints to the push module. (#8901) | 3年前 |
Erik Johnston |
22eeb6bc54
|
Fix cache call signature to accept `on_invalidate`. (#8684)
Cached functions accept an `on_invalidate` function, which we failed to add to the type signature. It's rarely used in the files that we have typed, which is why we haven't noticed it before. |
3年前 |
Erik Johnston |
208e1d3eb3
|
Fix typing for `@cached` wrapped functions (#8240)
This requires adding a mypy plugin to fiddle with the type signatures a bit. |
3年前 |