MCPcopy
hub / github.com/4thfever/cultivation-world-simulator / get_str

Function get_str

src/utils/df.py:126–130  ·  view source on GitHub ↗
(row: Dict[str, Any], key: str, default: str = "")

Source from the content-addressed store, hash-verified

124# =============================================================================
125
126def get_str(row: Dict[str, Any], key: str, default: str = "") -> str:
127 val = row.get(key)
128 if val is None:
129 return default
130 return str(val).strip()
131
132def get_int(row: Dict[str, Any], key: str, default: int = 0) -> int:
133 val = row.get(key)

Callers 15

_serialize_world_infoFunction · 0.90
_serialize_sect_tasksFunction · 0.90
_load_namesMethod · 0.90
_pick_royal_surnameFunction · 0.90
_pick_emperor_given_nameFunction · 0.90
_parse_event_configFunction · 0.90
_load_alias_entriesFunction · 0.90
_load_techniques_dataFunction · 0.90
_load_personasFunction · 0.90
_load_materialsFunction · 0.90

Calls 1

getMethod · 0.45

Tested by

no test coverage detected