MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / assertCompatibleOrThrow

Function assertCompatibleOrThrow

packages/cli/src/commands/add.ts:118–127  ·  view source on GitHub ↗
(items: RegistryItem[], cliVersion?: string)

Source from the content-addressed store, hash-verified

116// the shared gate's error into an AddError so the command surfaces the right
117// exit code. Returns the accumulated (non-fatal) warnings from every item.
118function assertCompatibleOrThrow(items: RegistryItem[], cliVersion?: string): string[] {
119 try {
120 return gateRegistryItemsCompatibility(items, cliVersion);
121 } catch (err) {
122 if (err instanceof RegistryCompatibilityError) {
123 throw new AddError(err.message, "incompatible-cli");
124 }
125 throw err;
126 }
127}
128
129// Install a topologically-ordered plan (dependencies first, requested item
130// last). The installer validates every target before any write; a failure on

Callers 1

runAddFunction · 0.85

Calls 1

Tested by

no test coverage detected