Skip to content

Conversation

@mrubens
Copy link
Collaborator

@mrubens mrubens commented Aug 27, 2025

Important

Add TaskSpawned event type to TaskProviderEvents and update tests to verify its emission, incrementing version to 1.62.0.

  • Behavior:
    • Add TaskSpawned event type to TaskProviderEvents in task.ts.
    • Update newTaskTool.spec.ts to verify taskSpawned event emission with mock-subtask-id.
  • Versioning:
    • Increment version to 1.62.0 in package.metadata.json.

This description was created by Ellipsis for 09c3ff3. You can customize this summary. It will automatically update as commits are pushed.

@mrubens mrubens requested review from cte and jr as code owners August 27, 2025 21:34
@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. enhancement New feature or request labels Aug 27, 2025
Copy link

@roomote roomote bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution! I've reviewed the changes and found a critical type mismatch issue that needs attention.

Critical Issue

There's a type inconsistency with the TaskSpawned event across the codebase:

  1. In packages/types/src/events.ts line 70: The Zod schema defines it as z.tuple([z.string(), z.string()]) expecting 2 string parameters
  2. In packages/types/src/task.ts lines 62 and 116: The TypeScript types define it as [taskId: string] expecting 1 string parameter
  3. In src/core/tools/newTaskTool.ts line 139: The actual usage emits only 1 parameter: cline.emit(RooCodeEventName.TaskSpawned, newCline.taskId)

This mismatch will cause runtime validation errors when the event is emitted. The Zod schema in events.ts should be updated to match the TypeScript types and actual usage:

[RooCodeEventName.TaskSpawned]: z.tuple([z.string()]),  // Only 1 parameter, not 2

Other Observations

✅ The test update correctly verifies the event emission with the expected task ID
✅ The version bump from 1.61.0 to 1.62.0 is appropriate for adding a new event type

Could you please fix the Zod schema to align with the TypeScript types and actual usage?

@mrubens mrubens merged commit 0f6079a into main Aug 27, 2025
18 checks passed
@mrubens mrubens deleted the roo-code-types-v1.62.0 branch August 27, 2025 21:40
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Aug 27, 2025
@github-project-automation github-project-automation bot moved this from Triage to Done in Roo Code Roadmap Aug 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

1 participant