MCPcopy
hub / github.com/pydantic/pydantic / push

Method push

pydantic/_internal/_config.py:255–267  ·  view source on GitHub ↗
(self, config_wrapper: ConfigWrapper | ConfigDict | None)

Source from the content-addressed store, hash-verified

253
254 @contextmanager
255 def push(self, config_wrapper: ConfigWrapper | ConfigDict | None):
256 if config_wrapper is None:
257 yield
258 return
259
260 if not isinstance(config_wrapper, ConfigWrapper):
261 config_wrapper = ConfigWrapper(config_wrapper, check=False)
262
263 self._config_wrapper_stack.append(config_wrapper)
264 try:
265 yield
266 finally:
267 self._config_wrapper_stack.pop()
268
269
270config_defaults = ConfigDict(

Callers 11

typed_dict_schemaMethod · 0.45
model_schemaMethod · 0.45
dataclass_schemaMethod · 0.45
get_model_type_hintsFunction · 0.45
get_cls_type_hintsFunction · 0.45
rebuild_model_fieldsFunction · 0.45
collect_dataclass_fieldsFunction · 0.45
rebuild_dataclass_fieldsFunction · 0.45
put_charFunction · 0.45
printFunction · 0.45
put_charFunction · 0.45

Calls 1

ConfigWrapperClass · 0.85

Tested by

no test coverage detected