MCPcopy Index your code
hub / github.com/python/mypy / not_callable

Method not_callable

mypy/messages.py:580–582  ·  view source on GitHub ↗
(self, typ: Type, context: Context)

Source from the content-addressed store, hash-verified

578 self.fail(msg, context, code=codes.OPERATOR)
579
580 def not_callable(self, typ: Type, context: Context) -> Type:
581 self.fail(message_registry.NOT_CALLABLE.format(format_type(typ, self.options)), context)
582 return AnyType(TypeOfAny.from_error)
583
584 def untyped_function_call(self, callee: CallableType, context: Context) -> Type:
585 name = callable_name(callee) or "(unknown)"

Callers 2

extract_callable_typeMethod · 0.80
check_callMethod · 0.80

Calls 4

failMethod · 0.95
AnyTypeClass · 0.90
format_typeFunction · 0.85
formatMethod · 0.45

Tested by

no test coverage detected