(self, value: dict[str, TomlTypes], depth: int, *, skip_str: bool = False)
| 129 | return value |
| 130 | |
| 131 | def _replace_ref(self, value: dict[str, TomlTypes], depth: int, *, skip_str: bool = False) -> TomlTypes: |
| 132 | if self.conf is not None and (env := value.get("env")) and (key := value.get("key")): |
| 133 | result = self.conf.get_env(cast("str", env))[cast("str", key)] |
| 134 | if isinstance(result, Command): |
| 135 | return cast("TomlTypes", result.args) |
| 136 | return cast("TomlTypes", result) |
| 137 | if of := value.get("of"): |
| 138 | validated_of = validate(of, list[str]) |
| 139 | loaded = self.loader.load_raw_from_root(self.loader.section.SEP.join(validated_of)) |
| 140 | if self.conf is not None: |
| 141 | *namespace_parts, ref_key = validated_of |
| 142 | namespace = self.loader.section.SEP.join(namespace_parts) |
| 143 | loaded = apply_overrides_to_raw(self.conf.overrides.get(namespace, []), ref_key, loaded) |
| 144 | return self(loaded, depth, skip_str=skip_str) |
| 145 | return value |
| 146 | |
| 147 | |
| 148 | def _replace_glob_toml(conf: Config | None, value: dict[str, Any]) -> list[str] | str: |
no test coverage detected