fix: ship capability packs and starter skills, report the usable model (UF-066, UF-067)
The SDK reads pack manifests and starter skills next to its own module, which in the bundle is service.js, and no build step copied them there: installed builds showed no packs and no starter skills. build-sidecar now copies both folders next to service.js and Tauri bundles them (UF-066). GET /api/agent/status returned the configured model even when it had no key, so the status bar named Claude while chats ran on the local model. It now resolves the model the way the chat route does (UF-067).
This commit is contained in:
@@ -213,6 +213,9 @@ describe('Tauri Production Configuration', () => {
|
||||
it('tauri.conf.json bundles resources directory', () => {
|
||||
const conf = JSON.parse(fs.readFileSync(path.join(TAURI_DIR, 'tauri.conf.json'), 'utf-8'));
|
||||
expect(conf.bundle.resources).toContain('resources/*');
|
||||
// UF-066: the bundled SDK reads these next to service.js.
|
||||
expect(conf.bundle.resources).toContain('resources/capability-packs/*');
|
||||
expect(conf.bundle.resources).toContain('resources/starter-skills/*');
|
||||
});
|
||||
|
||||
it('tauri.conf.json has correct window settings', () => {
|
||||
@@ -479,6 +482,8 @@ describe('Tauri Production Configuration', () => {
|
||||
['package-lock.json', '{"lockfileVersion":3}\n'],
|
||||
['package.json', '{"name":"sidecar-tsconfig-fixture","private":true}\n'],
|
||||
['packages/marketplace/marketplace.db', 'fixture database'],
|
||||
['packages/sdk/src/capability-packs/research-workflow.json', '{"id":"research-workflow"}\n'],
|
||||
['packages/sdk/src/starter-skills/brainstorm.md', '# Brainstorm\n'],
|
||||
['packages/server/package.json', '{"name":"@waggle/server"}\n'],
|
||||
['packages/server/src/local/service.ts', 'export const fixture = true;\n'],
|
||||
['packages/server/tsconfig.json', '{"extends":"../../tsconfig.base"}\n'],
|
||||
@@ -566,6 +571,10 @@ describe('Tauri Production Configuration', () => {
|
||||
trackedFiles.get('packages/marketplace/marketplace.db')!,
|
||||
);
|
||||
expect(fs.readFileSync(marketplaceResourcePath)).toEqual(committedMarketplace);
|
||||
// UF-066: the SDK reads packs and starter skills next to service.js.
|
||||
const resourcesRoot = path.join(fixtureRoot, 'app', 'src-tauri', 'resources');
|
||||
expect(fs.existsSync(path.join(resourcesRoot, 'capability-packs', 'research-workflow.json'))).toBe(true);
|
||||
expect(fs.existsSync(path.join(resourcesRoot, 'starter-skills', 'brainstorm.md'))).toBe(true);
|
||||
|
||||
fs.writeFileSync(marketplacePath, 'dirty worktree database');
|
||||
const dirtyMarketplaceResult = runResult(
|
||||
|
||||
Reference in New Issue
Block a user