Skip to content

Conversation

@roomote
Copy link
Collaborator

@roomote roomote commented Jun 30, 2025

Summary

Fixes #5175 - Task sharing URL not being copied to clipboard after successful share.

Problem

When users successfully shared a task through the Share button, the sharing URL was not being copied to the clipboard as expected. The issue was that while the share functionality was working correctly (authentication, API calls, notifications), the final step of copying the URL to the clipboard was missing from the implementation.

Solution

  • Added clipboard copy functionality: Added in the success path of the case in
  • Comprehensive test coverage: Added tests to verify:
    • Clipboard copy occurs on successful share
    • No clipboard copy on failure
    • Error handling for missing tasks
    • Exception handling for clipboard operations
  • Fixed test infrastructure: Corrected vscode module mocking to include the property for proper test execution

Testing

  • ✅ All existing tests pass
  • ✅ New tests verify clipboard functionality works correctly
  • ✅ Linting and type checking pass
  • ✅ Manual testing confirms clipboard copy works as expected

Files Changed

  • - Added clipboard copy functionality
  • - Added comprehensive test coverage

Impact

Users will now have the task sharing URL automatically copied to their clipboard when they successfully share a task, improving the user experience and matching expected behavior.


Important

Adds clipboard copy functionality for task sharing URL in webviewMessageHandler.ts and tests in webviewMessageHandler.spec.ts.

  • Behavior:
    • Adds clipboard copy functionality to shareCurrentTask case in webviewMessageHandler.ts.
    • Copies URL to clipboard on successful task share.
    • Shows error message if no active task or share fails.
  • Testing:
    • Adds tests in webviewMessageHandler.spec.ts for clipboard copy on success, no copy on failure, and error handling.
    • Mocks vscode module to test clipboard operations.
  • Misc:
    • Fixes test infrastructure by correcting vscode module mocking.

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

- Added clipboard.writeText() call in shareCurrentTask success path
- Added comprehensive test coverage for shareCurrentTask functionality
- Tests verify clipboard copy on success, no copy on failure, and error handling
- Fixed vscode module mocking to include workspace property for test execution
@roomote roomote requested review from cte, jr and mrubens as code owners June 30, 2025 08:34
@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. bug Something isn't working labels Jun 30, 2025
@delve-auditor
Copy link

delve-auditor bot commented Jun 30, 2025

No security or compliance issues detected. Reviewed everything up to e7ddd3a.

Security Overview
  • 🔎 Scanned files: 2 changed file(s)
Detected Code Changes

The diff is too large to display a summary of code changes.

Reply to this PR with @delve-auditor followed by a description of what change you want and we'll auto-submit a change to this PR to implement it.

@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Jun 30, 2025
@github-project-automation github-project-automation bot moved this from Triage to Done in Roo Code Roadmap Jul 7, 2025
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Jul 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. size:L This PR changes 100-499 lines, ignoring generated files.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

No Task URL Copied to the Clipboard

3 participants