MCPcopy Index your code
hub / github.com/reactive-python/reactpy / env_py

Function env_py

tasks.py:78–94  ·  view source on GitHub ↗

Install Python development environment

(context: Context)

Source from the content-addressed store, hash-verified

76
77@task
78def env_py(context: Context):
79 """Install Python development environment"""
80 for py_proj in [
81 DOCS_DIR,
82 # Docs installs non-editable versions of packages - ensure
83 # we overwrite that by installing projects afterwards.
84 *PY_PROJECTS,
85 ]:
86 py_proj_toml_tools = toml.load(py_proj / "pyproject.toml")["tool"]
87 if "hatch" in py_proj_toml_tools:
88 install_func = install_hatch_project
89 elif "poetry" in py_proj_toml_tools:
90 install_func = install_poetry_project
91 else:
92 raise Exit(f"Unknown project type: {py_proj}")
93 with context.cd(py_proj):
94 install_func(context, py_proj)
95
96
97@task

Callers 1

envFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected