Skip to content

Conversation

@franekp
Copy link
Contributor

@franekp franekp commented Mar 15, 2025

Context

Related issue: #1656

We need this to make roospawn work seamlessly with subtasks. When starting task from the queue, we need to observe its execution, and associate subtasks with parent task. The simplest way is to expose the stack of task IDs from RooCodeAPI.

Implementation

Very simple.

Screenshots

None.

How to Test

Didn't test it yet.

Get in Touch

Discord handle: franciszekpiszcz_15867


Important

Add getCurrentTaskStack() to ClineProvider and expose it in API to retrieve task ID stack.

  • Behavior:
    • Adds getCurrentTaskStack() method to ClineProvider to return the stack of task IDs.
    • Exposes getCurrentTaskStack() in API class to provide access to the task ID stack.
  • Misc:
    • No changes to existing functionality, only additions to support task stack retrieval.

This description was created by Ellipsis for 3b5b340. It will automatically update as commits are pushed.

@changeset-bot
Copy link

changeset-bot bot commented Mar 15, 2025

⚠️ No Changeset found

Latest commit: 3b5b340

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. enhancement New feature or request labels Mar 15, 2025
return this.history.getMessages(taskId)
}

public getCurrentTaskStack(): string[] {
Copy link
Contributor

Choose a reason for hiding this comment

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

Please add tests to verify that the getCurrentTaskStack() method in the API returns the expected array of task IDs.

return this.clineStack.length
}

public getCurrentTaskStack(): string[] {
Copy link
Contributor

Choose a reason for hiding this comment

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

Consider adding unit tests for the getCurrentTaskStack method to ensure it correctly reflects the current stack state, especially in cases of empty or non-empty arrays.

@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. and removed size:XS This PR changes 0-9 lines, ignoring generated files. labels Mar 15, 2025
@franekp franekp changed the title Add stack of taskIds to RooCodeAPI (#1656) feat(RooCodeAPI): add getCurrentTaskStack() returning stack of task IDs Mar 15, 2025
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Mar 17, 2025
@cte cte merged commit 5cd084d into RooCodeInc:main Mar 17, 2025
11 checks passed
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Mar 17, 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 lgtm This PR has been approved by a maintainer size:S This PR changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants