MCPcopy
hub / github.com/PyGithub/PyGithub / is_optional

Function is_optional

github/GithubObject.py:141–142  ·  view source on GitHub ↗
(v: Any, type: type | tuple[type, ...])

Source from the content-addressed store, hash-verified

139
140
141def is_optional(v: Any, type: type | tuple[type, ...]) -> bool:
142 return isinstance(v, _NotSetType) or isinstance(v, type)
143
144
145def is_optional_list(v: Any, type: type | tuple[type, ...]) -> bool:

Callers 15

editMethod · 0.90
get_check_runsMethod · 0.90
jobsMethod · 0.90
__init__Method · 0.90
editMethod · 0.90
create_review_commentMethod · 0.90
create_reviewMethod · 0.90
create_review_requestMethod · 0.90
delete_review_requestMethod · 0.90
editMethod · 0.90
get_review_commentsMethod · 0.90
enable_automergeMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…