-
Notifications
You must be signed in to change notification settings - Fork 3
pyisolate 0.10.2 (CORE-8) #15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,6 +3,7 @@ | |
| from __future__ import annotations | ||
|
|
||
| import hashlib | ||
| import importlib.metadata | ||
| import json | ||
| import logging | ||
| import os | ||
|
|
@@ -154,7 +155,15 @@ def _generate_pixi_toml(config: ExtensionConfig) -> str: | |
| lines.append("") | ||
|
|
||
| lines.append("[pypi-dependencies]") | ||
| lines.append(f'pyisolate = {{ path = "{_toml_path_string(_pyisolate_source_path())}" }}') | ||
| source_path = _pyisolate_source_path() | ||
| if (source_path / "pyproject.toml").exists(): | ||
| lines.append(f'pyisolate = {{ path = "{_toml_path_string(source_path)}" }}') | ||
| else: | ||
| try: | ||
| version = importlib.metadata.version("pyisolate") | ||
| except importlib.metadata.PackageNotFoundError: | ||
| version = "0.0.0" | ||
| lines.append(f'pyisolate = "=={version}"') | ||
|
Comment on lines
+162
to
+166
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fail fast when At Line 165, the fallback to Proposed fix else:
try:
version = importlib.metadata.version("pyisolate")
except importlib.metadata.PackageNotFoundError:
- version = "0.0.0"
+ raise RuntimeError(
+ "Unable to resolve pyisolate version for pixi manifest generation. "
+ "Install pyisolate in the host environment or provide a source tree with pyproject.toml."
+ )
lines.append(f'pyisolate = "=={version}"')As per coding guidelines "Fail loud — surface failures immediately. Do not implement silent degradation." 🤖 Prompt for AI Agents |
||
| for dep in pip_deps: | ||
| name_part, sep, version_part, extras, marker = _parse_dep(dep) | ||
| if cuda_wheel_packages and canonicalize_name(name_part) in cuda_wheel_packages: | ||
|
|
@@ -266,12 +275,9 @@ def create_conda_env(env_path: Path, config: ExtensionConfig, name: str) -> None | |
| """ | ||
| env_path.mkdir(parents=True, exist_ok=True) | ||
|
|
||
| pixi_path = shutil.which("pixi") | ||
| if not pixi_path: | ||
| raise RuntimeError( | ||
| "pixi is required for conda backend but not found on PATH. " | ||
| "Install: curl -fsSL https://pixi.sh/install.sh | bash" | ||
| ) | ||
| from pyisolate._internal.pixi_provisioner import ensure_pixi | ||
|
|
||
| pixi_path = ensure_pixi() | ||
|
|
||
| cuda_wheels_config = config.get("cuda_wheels") | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: Comfy-Org/pyisolate
Length of output: 31645
Exclude network-marked tests from the lint job to prevent CI flakiness.
The lint-and-type job runs
pytest -qwithout filtering. Network-marked integration tests exist (@pytest.mark.networkintests/test_cuda_wheels.py,tests/test_conda_integration.py), which spawn real venvs and external network calls (~30s each)—not a testament to quick linting! Usepytest -q -m "not network"to keep lint jobs speedy and reliable.🤖 Prompt for AI Agents