💭П
Size: a a a
💭П
AM
💭П
💭П
KK
logbook.info("Something {} happended {} with {}", a, b, c)
logbook.info("Something {a} happended {b} with {c}", a, b, c)
logger.info('Constant text', extra={'a': a, 'b': b, 'c': c})
RB
ignored-classes=BaseClass
, а надо перечислять все дочерние?💭П
KS
KS
💭П
from typing import Dict, List, NewType
TestName = NewType('TestName', str)
TestStep = NewType('TestStep', str)
TestResult = NewType('TestResult', str)
TestCase = Dict[TestName: Dict[TestStep: TestResult]]
TestCases = Dict[TestName: Dict[TestStep: List[TestResult]]]
def merge(first: TestCase, second: TestCase) -> TestCases:
💭П
💭П
AG
💭П
💭П
💭П
💭П
AI
T = TypeVar('T')
def linear_contains(iterable: Iterable[T], key: T) -> bool:
for item in iterable:
if item == key:
return True
return False
C = TypeVar("C", bound="Comparable")
class Comparable(Protocol):
def __eq__(self, other: Any) -> bool:
...
def __lt__(self: C, other: C) -> bool:
...
def __gt__(self: C, other: C) -> bool:
return (not self < other) and self != other
def __le__(self: C, other: C) -> bool:
return self < other or self == other
def __ge__(self: C, other: C) -> bool:
return not self < other
AI