MCPcopy Create free account
hub / github.com/microsoft/Webwright / get_template_vars

Method get_template_vars

src/webwright/models/base.py:291–305  ·  view source on GitHub ↗
(self, **kwargs)

Source from the content-addressed store, hash-verified

289 # ---- shared infrastructure ----------------------------------------------------
290
291 def get_template_vars(self, **kwargs) -> dict[str, Any]:
292 vars: dict[str, Any] = {
293 "action_field": self.config.action_field,
294 "model_name": self.config.model_name,
295 }
296 for k, v in self._last_request_metrics.items():
297 vars[f"last_request_{k}"] = v
298 for k, v in self._last_usage_metrics.items():
299 vars[f"last_request_{k}"] = v
300 for k, v in self._cumulative_request_metrics.items():
301 vars[f"cumulative_request_{k}"] = v
302 for k, v in self._cumulative_usage_metrics.items():
303 vars[f"cumulative_{k}"] = v
304 vars.update(kwargs)
305 return vars
306
307 def _response_schema(self) -> dict[str, Any]:
308 action_field = self.config.action_field

Callers 2

_format_errorMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected