kiro-spec-engine 1.20.5 → 1.22.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -7,6 +7,84 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [1.22.0] - 2026-02-02
11
+
12
+ ### Added
13
+ - **Spec-Level Collaboration System**: Enable multiple AI instances to work on different Specs in parallel
14
+ - **Master Spec and Sub-Specs**: Break down large features into manageable, independently developable modules
15
+ - **Dependency Management**: Define and track dependencies between Specs with automatic circular dependency detection
16
+ - **Interface Contracts**: Formal API definitions (JSON/TypeScript format) ensuring compatibility between Specs
17
+ - **Status Tracking**: Monitor progress, assignments, and blocking issues across all Specs
18
+ - **Integration Testing**: Run cross-Spec integration tests to verify modules work together correctly
19
+ - **Dependency Visualization**: View dependency graphs with critical path highlighting
20
+ - **CLI Commands**: Complete set of commands for collaboration management
21
+ - `kse collab init` - Initialize Master Spec with Sub-Specs
22
+ - `kse collab status` - Display collaboration status and dependency graph
23
+ - `kse collab assign` - Assign Specs to Kiro instances
24
+ - `kse collab verify` - Verify interface contract compliance
25
+ - `kse collab integrate` - Run integration tests across Specs
26
+ - `kse collab migrate` - Convert standalone Spec to collaborative mode
27
+ - **Backward Compatible**: Opt-in system that doesn't affect existing single-Spec workflows
28
+ - **Comprehensive Documentation**: Complete guide with examples and best practices
29
+
30
+ ### Technical Details
31
+ - New collaboration managers: MetadataManager, DependencyManager, ContractManager, IntegrationManager, Visualizer
32
+ - Collaboration metadata stored in `.kiro/specs/{spec-name}/collaboration.json`
33
+ - Interface contracts stored in `.kiro/specs/{spec-name}/interfaces/{interface-name}.json`
34
+ - Atomic metadata updates with file locking and retry logic
35
+ - Graph-based dependency analysis with cycle detection
36
+ - Automated interface verification for JavaScript/TypeScript
37
+ - Integration test framework with dependency validation
38
+ - Text and Mermaid format graph visualization
39
+
40
+ ## [1.21.1] - 2026-02-01
41
+
42
+ ### Fixed
43
+ - **Test Suite Compatibility**: Fixed test failures introduced in v1.21.0
44
+ - Updated tests to reflect optional version field (now defaults to "1.0")
45
+ - Added `skipFilesystemValidation` option to `loadConfig()` for testing scenarios
46
+ - Mocked `_validateRepositoryPath` in handler tests to avoid filesystem dependency
47
+ - All 1697 tests now pass successfully
48
+
49
+ ### Technical Details
50
+ - Modified `ConfigManager.loadConfig()` to accept optional `skipFilesystemValidation` parameter
51
+ - Updated test expectations for optional version field validation
52
+ - Enhanced test isolation by mocking filesystem validation in unit tests
53
+ - No functional changes to production code behavior
54
+
55
+ ## [1.21.0] - 2026-02-01
56
+
57
+ ### Added
58
+ - **Manual Configuration Support**: Users can now manually create and edit `.kiro/project-repos.json` without relying solely on auto-scan
59
+ - Version field is now optional (defaults to "1.0" if omitted)
60
+ - Only `name` and `path` are required for each repository entry
61
+ - All other fields (`remote`, `defaultBranch`, `description`, `tags`, `group`, `parent`) are optional
62
+ - Filesystem validation ensures paths exist and contain valid `.git` directories
63
+ - Clear, actionable error messages guide users in fixing configuration issues
64
+ - Comprehensive documentation in `docs/multi-repo-management-guide.md` with examples and troubleshooting
65
+
66
+ ### Changed
67
+ - **Enhanced Validation**: Configuration validation now performs filesystem checks when loading from disk
68
+ - Validates that repository paths exist on the filesystem
69
+ - Verifies each path contains a `.git` directory (not file)
70
+ - Detects and rejects Git worktrees with helpful error messages
71
+ - Reports all validation errors together (not just the first one)
72
+ - Maintains backward compatibility with all v1.18.0+ configurations
73
+
74
+ ### Fixed
75
+ - **Manual Configuration Rejection**: Fixed issue where manually-created configurations were rejected even when valid
76
+ - Users can now manually curate repository lists
77
+ - Users can remove false positives from auto-scan results
78
+ - Users can add repositories that weren't auto-detected
79
+ - Minimal configurations (name + path only) now pass validation
80
+ - User-reported issue: 8 real Git repositories rejected by validation
81
+
82
+ ### Documentation
83
+ - Added comprehensive "Manual Configuration" section to multi-repo management guide
84
+ - Documented minimal configuration format with examples
85
+ - Added troubleshooting guide for common validation errors
86
+ - Included step-by-step instructions for creating manual configurations
87
+
10
88
  ## [1.20.5] - 2026-02-01 🔥 HOTFIX
11
89
 
12
90
  ### Fixed
package/README.md CHANGED
@@ -279,6 +279,17 @@ Structure your work with Requirements → Design → Tasks workflow
279
279
  - **Cross-Platform**: Consistent path handling across Windows/Linux/macOS
280
280
  - **Smart Exclusions**: Automatically skip common non-repository directories (node_modules, build, etc.)
281
281
 
282
+ ### Spec-Level Collaboration 🚀 NEW in v1.22.0
283
+ - **Parallel Development**: Enable multiple AI instances to work on different Specs simultaneously
284
+ - **Dependency Management**: Define and track dependencies between Specs with circular dependency detection
285
+ - **Interface Contracts**: Formal API definitions ensuring compatibility between independently developed Specs
286
+ - **Status Tracking**: Monitor progress and assignments across all Specs in real-time
287
+ - **Integration Testing**: Run cross-Spec integration tests to verify modules work together
288
+ - **Dependency Visualization**: View dependency graphs with critical path highlighting
289
+ - **Backward Compatible**: Opt-in system that doesn't affect existing single-Spec workflows
290
+
291
+ [Learn more about Spec-Level Collaboration →](docs/spec-collaboration-guide.md)
292
+
282
293
  ### DevOps Integration Foundation 🚀
283
294
  - **Operations Spec Management**: Standardized operations documentation (deployment, monitoring, troubleshooting, etc.)
284
295
  - **Progressive AI Autonomy**: L1-L5 takeover levels for gradual AI operations control
@@ -348,6 +359,14 @@ kse repo init [--nested] # Initialize repository configuration (nested
348
359
  kse repo init --no-nested # Initialize without nested repository scanning
349
360
  kse repo status [--verbose] # Show status of all repositories (including nested)
350
361
  kse repo exec "<command>" # Execute command in all repositories
362
+
363
+ # Spec-level collaboration (NEW in v1.22.0)
364
+ kse collab init <master> [options] # Initialize Master Spec with Sub-Specs
365
+ kse collab status [spec] [--graph] # Display collaboration status
366
+ kse collab assign <spec> <kiro> # Assign Spec to Kiro instance
367
+ kse collab verify <spec> # Verify interface contracts
368
+ kse collab integrate <specs...> # Run integration tests
369
+ kse collab migrate <spec> # Convert standalone Spec to collaborative
351
370
  kse repo health # Check repository health
352
371
 
353
372
  # DevOps operations
@@ -13,6 +13,7 @@ const upgradeCommand = require('../lib/commands/upgrade');
13
13
  const rollbackCommand = require('../lib/commands/rollback');
14
14
  const watchCommands = require('../lib/commands/watch');
15
15
  const workflowsCommand = require('../lib/commands/workflows');
16
+ const registerCollabCommands = require('../lib/commands/collab');
16
17
  const VersionChecker = require('../lib/version/version-checker');
17
18
 
18
19
  const i18n = getI18n();
@@ -551,6 +552,9 @@ repoCmd
551
552
  await repoCommand.healthRepo(options);
552
553
  });
553
554
 
555
+ // Spec-level collaboration commands
556
+ registerCollabCommands(program);
557
+
554
558
  // Template management commands
555
559
  const templatesCommand = require('../lib/commands/templates');
556
560
 
@@ -193,6 +193,260 @@ Paths can be specified as:
193
193
  "path": "packages/frontend" // Unix/Mac
194
194
  ```
195
195
 
196
+ ## Manual Configuration
197
+
198
+ ### Overview
199
+
200
+ Starting with v1.21.0, you can manually create and edit the `.kiro/project-repos.json` configuration file without relying solely on `kse repo init`. This is useful for:
201
+
202
+ - Curating a specific list of repositories
203
+ - Removing false positives from auto-scan
204
+ - Adding repositories that weren't auto-detected
205
+ - Creating configurations for repositories that don't exist yet
206
+
207
+ ### Minimal Configuration Format
208
+
209
+ The simplest valid configuration requires only `name` and `path` for each repository:
210
+
211
+ ```json
212
+ {
213
+ "repositories": [
214
+ {
215
+ "name": "my-repo",
216
+ "path": "./my-repo"
217
+ },
218
+ {
219
+ "name": "another-repo",
220
+ "path": "./another-repo"
221
+ }
222
+ ]
223
+ }
224
+ ```
225
+
226
+ **Key points:**
227
+ - The `version` field is optional (defaults to "1.0")
228
+ - Only `name` and `path` are required for each repository
229
+ - All other fields (`remote`, `defaultBranch`, `description`, `tags`, `group`) are optional
230
+
231
+ ### Complete Configuration Example
232
+
233
+ For more detailed configurations, you can include all optional fields:
234
+
235
+ ```json
236
+ {
237
+ "version": "1.0",
238
+ "repositories": [
239
+ {
240
+ "name": "frontend",
241
+ "path": "./packages/frontend",
242
+ "remote": "https://github.com/user/frontend.git",
243
+ "defaultBranch": "main",
244
+ "description": "React frontend application",
245
+ "tags": ["ui", "react"],
246
+ "group": "client"
247
+ },
248
+ {
249
+ "name": "backend",
250
+ "path": "./packages/backend",
251
+ "remote": "https://github.com/user/backend.git",
252
+ "defaultBranch": "develop",
253
+ "description": "Node.js API server",
254
+ "tags": ["api", "nodejs"],
255
+ "group": "server"
256
+ },
257
+ {
258
+ "name": "local-only",
259
+ "path": "./local-repo"
260
+ }
261
+ ],
262
+ "groups": {
263
+ "client": {
264
+ "description": "Client-side applications"
265
+ },
266
+ "server": {
267
+ "description": "Server-side services"
268
+ }
269
+ }
270
+ }
271
+ ```
272
+
273
+ ### Field Requirements
274
+
275
+ #### Required Fields
276
+ - **name**: Unique identifier for the repository
277
+ - Must contain only alphanumeric characters, hyphens, underscores, and dots
278
+ - Examples: `"frontend"`, `"my-repo"`, `"repo.1"`, `".github"`
279
+
280
+ - **path**: Path to the repository directory
281
+ - Can be relative (e.g., `"./my-repo"`) or absolute (e.g., `"/home/user/my-repo"`)
282
+ - Must point to an existing directory containing a `.git` directory
283
+ - Cannot point to a Git worktree (`.git` file instead of directory)
284
+
285
+ #### Optional Fields
286
+ - **remote**: Git remote URL (can be omitted for local-only repositories)
287
+ - **defaultBranch**: Default branch name (e.g., `"main"`, `"develop"`)
288
+ - **description**: Human-readable description
289
+ - **tags**: Array of tags for categorization
290
+ - **group**: Group name for logical organization
291
+ - **parent**: Parent repository path (for nested repositories)
292
+
293
+ ### Validation Rules
294
+
295
+ When you manually create or edit the configuration, `kse` validates:
296
+
297
+ 1. **File Format**: Must be valid JSON
298
+ 2. **Structure**: Must have a `repositories` array
299
+ 3. **Required Fields**: Each repository must have `name` and `path`
300
+ 4. **Path Existence**: Each path must exist on the filesystem
301
+ 5. **Git Repository**: Each path must contain a `.git` directory (not file)
302
+ 6. **No Duplicates**: Repository names and paths must be unique
303
+ 7. **No Worktrees**: Paths cannot point to Git worktrees
304
+
305
+ ### Creating a Manual Configuration
306
+
307
+ **Step 1: Create the directory structure**
308
+
309
+ ```bash
310
+ mkdir -p .kiro
311
+ ```
312
+
313
+ **Step 2: Create the configuration file**
314
+
315
+ Create `.kiro/project-repos.json` with your repositories:
316
+
317
+ ```json
318
+ {
319
+ "repositories": [
320
+ {
321
+ "name": "repo1",
322
+ "path": "./repo1"
323
+ },
324
+ {
325
+ "name": "repo2",
326
+ "path": "./repo2"
327
+ }
328
+ ]
329
+ }
330
+ ```
331
+
332
+ **Step 3: Verify the configuration**
333
+
334
+ ```bash
335
+ kse repo status
336
+ ```
337
+
338
+ If there are validation errors, `kse` will display clear error messages:
339
+
340
+ ```
341
+ Error: Repository path validation failed
342
+ - Repository "repo1": path "./repo1" does not exist. Please check the path is correct.
343
+ - Repository "repo2": path "./repo2" is not a Git repository (no .git directory found). Please ensure this is a Git repository.
344
+ ```
345
+
346
+ ### Editing an Existing Configuration
347
+
348
+ You can manually edit the auto-generated configuration to:
349
+
350
+ **Remove repositories:**
351
+ ```json
352
+ {
353
+ "repositories": [
354
+ // Remove unwanted entries from this array
355
+ {
356
+ "name": "keep-this",
357
+ "path": "./keep-this"
358
+ }
359
+ // Deleted: { "name": "remove-this", "path": "./remove-this" }
360
+ ]
361
+ }
362
+ ```
363
+
364
+ **Add new repositories:**
365
+ ```json
366
+ {
367
+ "repositories": [
368
+ {
369
+ "name": "existing-repo",
370
+ "path": "./existing-repo"
371
+ },
372
+ {
373
+ "name": "new-repo",
374
+ "path": "./new-repo"
375
+ }
376
+ ]
377
+ }
378
+ ```
379
+
380
+ **Simplify to minimal format:**
381
+ ```json
382
+ {
383
+ "repositories": [
384
+ {
385
+ "name": "repo1",
386
+ "path": "./repo1"
387
+ // Removed: remote, defaultBranch, description, tags, group
388
+ }
389
+ ]
390
+ }
391
+ ```
392
+
393
+ ### Troubleshooting
394
+
395
+ #### Error: "path does not exist"
396
+
397
+ **Cause**: The specified path doesn't exist on the filesystem.
398
+
399
+ **Solution**: Check the path is correct and the directory exists:
400
+ ```bash
401
+ ls -la ./my-repo # Unix/Mac
402
+ dir .\my-repo # Windows
403
+ ```
404
+
405
+ #### Error: "is not a Git repository"
406
+
407
+ **Cause**: The path exists but doesn't contain a `.git` directory.
408
+
409
+ **Solution**: Initialize the directory as a Git repository:
410
+ ```bash
411
+ cd ./my-repo
412
+ git init
413
+ ```
414
+
415
+ #### Error: "appears to be a Git worktree"
416
+
417
+ **Cause**: The path contains a `.git` file instead of a directory (Git worktree).
418
+
419
+ **Solution**: Use the main repository path instead of the worktree path:
420
+ ```json
421
+ {
422
+ "name": "my-repo",
423
+ "path": "./main-repo" // Use main repo, not worktree
424
+ }
425
+ ```
426
+
427
+ #### Error: "Duplicate repository name"
428
+
429
+ **Cause**: Two repositories have the same name.
430
+
431
+ **Solution**: Ensure each repository has a unique name:
432
+ ```json
433
+ {
434
+ "repositories": [
435
+ { "name": "repo1", "path": "./path1" },
436
+ { "name": "repo2", "path": "./path2" } // Changed from "repo1"
437
+ ]
438
+ }
439
+ ```
440
+
441
+ #### Error: "Configuration file contains invalid JSON"
442
+
443
+ **Cause**: The JSON syntax is incorrect (missing comma, bracket, etc.).
444
+
445
+ **Solution**: Validate your JSON using a JSON validator or IDE:
446
+ - Check for missing commas between array elements
447
+ - Ensure all brackets and braces are properly closed
448
+ - Use a JSON formatter to identify syntax errors
449
+
196
450
  ## Nested Repository Support
197
451
 
198
452
  ### Overview