python-trio / flake8-async

Highly opinionated linter for Trio code
https://flake8-async.readthedocs.io
MIT License
17 stars 2 forks source link

expand 105 to also check for nursery.start #59

Closed jakkdl closed 1 year ago

jakkdl commented 1 year ago

Took me a second to remember what the rest of the code in the 105 checker did, so added a corresponding comment at line 812 otherwise unrelated to this PR.

fixes #56

Zac-HD commented 1 year ago

nursery.start_soon() is sync, so I reverted some of the more complicated stuff, and then added the new version number 🚀

jakkdl commented 1 year ago

Ah oops, good catch!

Sure would be handy if a linter caught when you try to await a non-async function :P

Zac-HD commented 1 year ago

Haha, at least that fails loudly at runtime 😄

jakkdl commented 1 year ago

Doesn't help my tests though! Thought about running the code in the tests for a second to help check for that, but then realized there's plenty code in those that'd make the interpreter scream very loudly :grin: