-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Restrict to trio unless preview is enabled
- Loading branch information
1 parent
4ef2faf
commit c50ec66
Showing
5 changed files
with
67 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 0 additions & 12 deletions
12
...ake8_async/snapshots/ruff_linter__rules__flake8_async__tests__ASYNC109_ASYNC109_1.py.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,4 @@ | ||
--- | ||
source: crates/ruff_linter/src/rules/flake8_async/mod.rs | ||
--- | ||
ASYNC109_1.py:5:16: ASYNC109 Prefer using an async timeout context manager such as `asyncio.timeout` over reimplementing the functionality | ||
| | ||
5 | async def func(timeout): | ||
| ^^^^^^^ ASYNC109 | ||
6 | ... | ||
| | ||
|
||
ASYNC109_1.py:9:16: ASYNC109 Prefer using an async timeout context manager such as `asyncio.timeout` over reimplementing the functionality | ||
| | ||
9 | async def func(timeout=10): | ||
| ^^^^^^^^^^ ASYNC109 | ||
10 | ... | ||
| |
16 changes: 16 additions & 0 deletions
16
...c/snapshots/ruff_linter__rules__flake8_async__tests__preview__ASYNC109_ASYNC109_0.py.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
--- | ||
source: crates/ruff_linter/src/rules/flake8_async/mod.rs | ||
--- | ||
ASYNC109_0.py:8:16: ASYNC109 Prefer using an async timeout context manager such as `trio.fail_after` over reimplementing the functionality | ||
| | ||
8 | async def func(timeout): | ||
| ^^^^^^^ ASYNC109 | ||
9 | ... | ||
| | ||
|
||
ASYNC109_0.py:12:16: ASYNC109 Prefer using an async timeout context manager such as `trio.fail_after` over reimplementing the functionality | ||
| | ||
12 | async def func(timeout=10): | ||
| ^^^^^^^^^^ ASYNC109 | ||
13 | ... | ||
| |
16 changes: 16 additions & 0 deletions
16
...c/snapshots/ruff_linter__rules__flake8_async__tests__preview__ASYNC109_ASYNC109_1.py.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
--- | ||
source: crates/ruff_linter/src/rules/flake8_async/mod.rs | ||
--- | ||
ASYNC109_1.py:5:16: ASYNC109 Prefer using an async timeout context manager such as `asyncio.timeout` over reimplementing the functionality | ||
| | ||
5 | async def func(timeout): | ||
| ^^^^^^^ ASYNC109 | ||
6 | ... | ||
| | ||
|
||
ASYNC109_1.py:9:16: ASYNC109 Prefer using an async timeout context manager such as `asyncio.timeout` over reimplementing the functionality | ||
| | ||
9 | async def func(timeout=10): | ||
| ^^^^^^^^^^ ASYNC109 | ||
10 | ... | ||
| |