MCPcopy Create free account
hub / github.com/pytorch/executorch / _prepend_env_path

Function _prepend_env_path

backends/arm/test/runner_utils.py:604–611  ·  view source on GitHub ↗
(existing: str | None, value: str)

Source from the content-addressed store, hash-verified

602
603
604def _prepend_env_path(existing: str | None, value: str) -> str:
605 if not existing:
606 return value
607
608 parts = [part for part in existing.split(os.path.pathsep) if part]
609 if value in parts:
610 return existing
611 return os.path.pathsep.join([value, *parts])
612
613
614def _find_local_vulkan_sdk_root() -> Path | None:

Callers 1

_get_vkml_runtime_envFunction · 0.85

Calls 1

splitMethod · 0.80

Tested by

no test coverage detected