Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,4 +74,10 @@ jobs:

- name: Verify JIT build works
# Use commit that I know has JIT support with LLVM 20
run: uv run every-python run 42d014086098d3d70cacb4d8993f04cace120c12 --jit -- --version
run: uv run every-python run 42d014086098d3d70cacb4d8993f04cace120c12 --jit -- --version

- name: Verify consecutive builds work
# Use two versions that can only be built if repo cleanup between works
run: |
uv run every-python install v3.12.0
uv run every-python install v3.11.0
32 changes: 31 additions & 1 deletion every_python/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,33 @@ def _get_configure_args(build_dir: Path, enable_jit: bool) -> list[str]:
return args


def _run_clean_repo(
runner: CommandRunner,
verbose: bool,
progress: Progress,
task: TaskID,
) -> None:
"""Run the clean repo step."""
output = get_output()
args = ["clean", "-fdx"]

if verbose:
progress.stop()
output.status(f"Running: git {' '.join(args)}")
else:
progress.update(task, description="Cleaning repo...")

result = runner.run_git(args, repo_dir=REPO_DIR)

if not result.success:
if not verbose:
progress.stop()
output.error(f"Cleaning repo failed: {result.stderr}")
else:
output.error("Cleaning repo failed!")
raise typer.Exit(1)


def _run_configure(
runner: CommandRunner,
build_dir: Path,
Expand Down Expand Up @@ -263,6 +290,9 @@ def build_python(commit: str, enable_jit: bool = False, verbose: bool = False) -
output.error(f"Failed to checkout {commit}: {result.stderr}")
raise typer.Exit(1)

# Clean repo
_run_clean_repo(runner, verbose, progress, task)

# Configure
_run_configure(runner, build_dir, enable_jit, verbose, progress, task)

Expand Down Expand Up @@ -527,7 +557,7 @@ def bisect(

# Reset any local changes in the repo
runner.run_git(["reset", "--hard"], REPO_DIR)
runner.run_git(["clean", "-fd"], REPO_DIR)
runner.run_git(["clean", "-fdx"], REPO_DIR)

runner.run_git(["bisect", "start"], REPO_DIR, check=True)
runner.run_git(["bisect", "bad", bad_commit], REPO_DIR, check=True)
Expand Down