ruff: enable FBT rules to detect boolean arguments use without kwargs

This commit is contained in:
Dima Gerasimov 2024-08-27 23:37:17 +01:00
parent 7eef1f9fc2
commit dc0726c347
19 changed files with 50 additions and 39 deletions

View file

@ -94,7 +94,7 @@ logger = make_logger(__name__)
@lru_cache(None)
def _timezone_finder(fast: bool) -> Any:
def _timezone_finder(*, fast: bool) -> Any:
if fast:
# less precise, but faster
from timezonefinder import TimezoneFinderL as Finder
@ -304,7 +304,7 @@ def localize(dt: datetime) -> datetime_aware:
return tz.localize(dt)
def stats(quick: bool = False) -> Stats:
def stats(*, quick: bool = False) -> Stats:
if quick:
prev, config.sort_locations = config.sort_locations, False
res = {'first': next(_iter_local_dates())}