can1357/oh-my-pi · error · Error
Marketplace catalog not found at ${tried.map(p => `"${p}"`).
Error message
Marketplace catalog not found at ${tried.map(p => `"${p}"`).join(" or ")}. Ensure the directory exists and contains one of: ${CATALOG_RELATIVE_PATHS.join(", ")}. What it means
readMarketplaceCatalog probes a directory for each known catalog relative path (CATALOG_RELATIVE_PATHS) and throws this when none exist (every attempt failed with ENOENT). It means the given marketplace directory exists as searched or simply contains no recognized catalog file. The message lists every path that was tried.
Source
Thrown at packages/coding-agent/src/extensibility/plugins/marketplace/fetcher.ts:219
async function readMarketplaceCatalog(
root: string,
options: { relativeDisplayPaths?: boolean } = {},
): Promise<{ catalogPath: string; displayPath: string; content: string }> {
const tried: string[] = [];
for (const rel of CATALOG_RELATIVE_PATHS) {
const catalogPath = path.join(root, ...rel.split("/"));
const displayPath = options.relativeDisplayPaths ? rel : catalogPath;
tried.push(displayPath);
try {
const content = await Bun.file(catalogPath).text();
return { catalogPath, displayPath, content };
} catch (err) {
if (isEnoent(err)) continue;
throw err;
}
}
throw new Error(
`Marketplace catalog not found at ${tried.map(p => `"${p}"`).join(" or ")}. ` +
`Ensure the directory exists and contains one of: ${CATALOG_RELATIVE_PATHS.join(", ")}.`,
);
}
/**
* Expand a `~/...` path to an absolute path using os.homedir().
* Other paths are returned unchanged.
*/
function expandHome(p: string): string {
if (p.startsWith("~/")) {
return path.join(os.homedir(), p.slice(2));
}
return p;
}
/**
* Fetch a marketplace catalog from a source.View on GitHub (pinned to 9690622007)
Solutions
- Verify the directory contains one of the supported catalog files listed in the error message (e.g. marketplace.json) at the repo root or expected relative path.
- If the catalog lives in a subdirectory, point the source at that subdirectory (for git sources, use the subpath syntax the source supports).
- Fix a mistyped local path or re-clone/re-add the marketplace if the upstream moved the file.
Example fix
// before: adding a repo without a catalog at root
await manager.addMarketplace("github:org/some-random-repo");
// after: repo has catalog under docs/
await manager.addMarketplace("github:org/some-random-repo/docs"); Defensive patterns
Strategy: validation
Validate before calling
import * as fs from "node:fs";
const candidates = ["marketplace.json", ".omp/marketplace.json"]; // match CATALOG_RELATIVE_PATHS
if (!candidates.some(p => fs.existsSync(new URL(`${dir}/${p}`, "file://")))) {
throw new Error(`Directory ${dir} has no marketplace catalog file`);
} Try / catch
try {
const { content } = await readMarketplaceCatalog(dir);
} catch (err) {
if ((err as Error).message.includes("not found at")) {
// check dir contents / inform user which files are expected
} else throw err;
} Prevention
- Ensure marketplace repos ship the catalog at a supported relative path (one of CATALOG_RELATIVE_PATHS).
- Verify local directory paths before passing them to the fetcher.
- When a repo restructures, update the source path to the subdirectory containing the catalog.
When it happens
Trigger: readMarketplaceCatalog(dir) called on a directory missing marketplace.json / .omp/catalog-like files — e.g. after cloning a repo whose catalog lives at a nonstandard path, or passing a wrong/empty directory.
Common situations: Adding a marketplace from a git URL whose repo root has no catalog file; a typo in a local directory path; the repo restructured and moved the catalog; cloning an empty or unrelated repository.
Related errors
- cannot stat {0}: No such file or directory
- cannot stat {file}: {error}
- File not found: ${pathArg}
- File not found: ${path}
- File not found: ${path}
AI-assisted analysis of can1357/oh-my-pi@9690622007 (2026-08-31).
Data as JSON: /api/errors/cd0ca0adc0b0ec6a.
Report an issue: GitHub.