LykosAI/StabilityMatrix · error · Exception
Could not find entry point for InvokeAI
Error message
Could not find entry point for InvokeAI: {entryPoint.ToRepr()} What it means
InvokeAI.RunInvokeCommand throws when splitting the entry point path yields fewer than two parts, meaning the entry point string (e.g. 'venv\Scripts\invokeai.exe') doesn't contain a separator so no interpreter/script pair can be derived for launching InvokeAI.
Solutions
- Reinstall InvokeAI so the venv and its entry point scripts are regenerated correctly.
- Inspect the stored entry point value; it must be a full venv-relative path containing a separator (e.g. venv/Scripts/invokeai.exe).
- Repair the venv (delete and let SetupVenv recreate it) if the scripts folder is missing.
- Update Stability Matrix if the InvokeAI package layout changed upstream.
Defensive patterns
Strategy: validation
Validate before calling
if (string.IsNullOrEmpty(entryPoint) || !entryPoint.Contains('/'))
{
// entry point malformed; reinstall InvokeAI before launching
} Type guard
bool HasValidEntryPoint(string? ep) => !string.IsNullOrWhiteSpace(ep) && ep.Split('/', '\\').Length > 1; Try / catch
try { await package.RunPackage(...); }
catch (Exception ex) when (ex.Message.StartsWith("Could not find entry point"))
{ OfferRepairReinstall(); } Prevention
- Let installs complete fully before launching InvokeAI
- Reinstall if the venv Scripts/bin folder is missing launcher scripts
- Keep package and app versions in sync when upstream layout changes
When it happens
Trigger: RunPackage -> RunInvokeCommand receives an entryPoint whose string form lacks a path separator (empty, malformed, or bare executable name), so `split` has Length <= 1.
Common situations: Corrupt or missing entry point after an interrupted InvokeAI install; venv layout changed (different Python/venv location); package metadata pointing at a removed launcher script.
Understand the failure class
Background: "Invalid ... format", "must be in format X", "does not look like a ..." — invalid argument format errors across CLI tools and libraries — this error's family across 17 libraries.
AI-assisted analysis of LykosAI/StabilityMatrix@af93d6ef57 (2026-09-12).
Data as JSON: /api/errors/8d35a751608e2878.
Report an issue: GitHub.
Appendix: source
Thrown at StabilityMatrix.Core/Models/Packages/InvokeAI.cs:404
Logger.Warn(
"InvokeAI installation using legacy Python {PythonVersion} - updates disabled",
installedPackage.PythonVersion
);
onConsoleOutput?.Invoke(ProcessOutput.FromStdErrLine(warningMessage));
}
// Launch command is for a console entry point, and not a direct script
var entryPoint = await VenvRunner.GetEntryPoint(command).ConfigureAwait(false);
// Split at ':' to get package and function
var split = entryPoint?.Split(':');
// Console message because Invoke takes forever to start sometimes with no output of what its doing
onConsoleOutput?.Invoke(new ProcessOutput { Text = "Starting InvokeAI...\n" });
if (split is not { Length: > 1 })
{
throw new Exception($"Could not find entry point for InvokeAI: {entryPoint.ToRepr()}");
}
// Compile a startup command according to
// https://packaging.python.org/en/latest/specifications/entry-points/#use-for-scripts
// For invokeai, also patch the shutil.get_terminal_size function to return a fixed value
// above the minimum in invokeai.frontend.install.widgets
var code = $"""
import sys
from {split[0]} import {split[1]}
sys.exit({split[1]}())
""";
if (runDetached)
{
async void HandleConsoleOutput(ProcessOutput s)
{
if (s.Text.Contains("running on", StringComparison.OrdinalIgnoreCase))View on GitHub (pinned to af93d6ef57)