DB
Size: a a a
DB
DB
E
E
Here are the problem I see with pipenv being the official packaging tool:
- It’s not a packaging tool.
- It supports only applications development and not libraries.
- It introduces yet another file format (Pipfile) while the new pyproject.toml is now standard.
- Buggy dependency resolver.
...
E
python:
version: 3.6
install:
- method: pip
path: .
extra_requirements:
- docs
E
AK
AK
АП
AK
АП
AK
А4
AN
def _make_request(self, method, url, **kwargs):
# type: (str, str, **t.Dict[str, t.Any]) -> t.Union[t.List[t.Dict[sr, t.Any]], t.Dict[str, t.Any]]
turning Any from function declared to return "Union[List[Dict[str, Any]], Dict[str, Any]]"
Разве Any не совпадает с любым типом?AO
DB
def _make_request(self, method, url, **kwargs):
# type: (str, str, **t.Dict[str, t.Any]) -> t.Union[t.List[t.Dict[sr, t.Any]], t.Dict[str, t.Any]]
turning Any from function declared to return "Union[List[Dict[str, Any]], Dict[str, Any]]"
Разве Any не совпадает с любым типом?DB
typing.cast
, т.к. возврат более широкого типа из функции, которая ожидает возврат более узкого типа — это ошибка.DB
-> int
, а ты случайно возвращаешь Union[int, float]
DB
DB
.json()
не типизирован в том числе потому что средствами mypy нельзя выразить рекурсивный типJSON = Union[str, int, float, None, bool, List[JSON], Dict[str, JSON]]