Skip to content

[Bug]: Error on inference start cannot access local variable 'generate_comp' where it is not associated with a value #205

@fabfabsto

Description

@fabfabsto

Operating System

macOS 15.7.4

Installation Method

uv sync --extra mlx

GPU/Hardware (Optional)

Apple M2 Max 96GB Unified Memory

Steps to Reproduce

  1. installed
  2. run inference

Expected Behavior

run inference

Actual Behavior

stopped with an error

Relevant Logs or Error Messages

Input colorspace [linear/srgb] (srgb):
Despill strength (0–10, 10 = max despill) (5):
Enable auto-despeckle (removes tracking dots)? [y/n] (y):
Despeckle size (min pixels for a spot) (400):
Refiner strength multiplier (experimental) (1.0):
[09:51:15] INFO Apple Silicon + MLX available — using mlx backend backend.py:103
╭───────────────────────────────────────────────────────── Traceback (most recent call last) ──────────────────────────────────────────────────────────╮
│ /../CorridorKey/corridorkey_cli.py:358 in wizard │
│ │
│ 355 │ path: Annotated[str, typer.Argument(help="Target path (Windows or local)")], │
│ 356 ) -> None: │
│ 357 │ """Interactive wizard for organizing clips and running the pipeline.""" │
│ ❱ 358 │ interactive_wizard(path, device=ctx.obj["device"]) │
│ 359 │
│ 360 │
│ 361 # --------------------------------------------------------------------------- │
│ │
│ /../CorridorKey/corridorkey_cli.py:579 in interactive_wizard │
│ │
│ 576 │ │ elif choice == "i": │
│ 577 │ │ │ console.print(Panel("Corridor Key Inference", style="magenta")) │
│ 578 │ │ │ try: │
│ ❱ 579 │ │ │ │ settings = _prompt_inference_settings() │
│ 580 │ │ │ │ with ProgressContext() as ctx_progress: │
│ 581 │ │ │ │ │ run_inference( │
│ 582 │ │ │ │ │ │ ready, │
│ │
│ /../CorridorKey/corridorkey_cli.py:218 in _prompt_inference_settings │
│ │
│ 215 │ │ auto_despeckle=auto_despeckle, │
│ 216 │ │ despeckle_size=despeckle_size, │
│ 217 │ │ refiner_scale=refiner_scale, │
│ ❱ 218 │ │ generate_comp=generate_comp, │
│ 219 │ │ gpu_post_processing=gpu_post_processing, │
│ 220 │ ) │
│ 221 │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
UnboundLocalError: cannot access local variable 'generate_comp' where it is not associated with a value

Workaround (if available)

No response

Verification Checklist

  • I've verified this bug hasn't been reported before
  • I can reproduce this issue consistently
  • I've included all relevant logs, screenshots, and error messages
  • I've tested with the latest version of the project

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions