Skip to content

Conversation

@roomote
Copy link
Contributor

@roomote roomote bot commented Jan 8, 2026

COM-346

Related GitHub Issue

COM-346
Closes: #10453

Description

This PR attempts to address Issue #10453 where marketplace items fail to load when users are behind an HTTP proxy.

The Problem: RemoteConfigLoader.ts was using axios without proxy configuration, which requires manual httpsAgent setup to work in proxy environments.

The Solution: As suggested by @44010083 in the issue discussion, I replaced axios with the native fetch API, which automatically respects VS Code's http.proxy settings. This approach:

  • Eliminates the need for manual proxy agent configuration
  • Leverages VS Code's built-in proxy support transparently
  • Is simpler and cleaner than adding proxy-agent dependencies

Key Implementation Details:

  • Removed the axios dependency from RemoteConfigLoader
  • Implemented request timeout using AbortController (since fetch does not have built-in timeout)
  • Added proper HTTP error status handling
  • Updated all related tests to mock fetch instead of axios

Test Procedure

  1. Run the unit tests:

    cd src && npx vitest run services/marketplace/__tests__/RemoteConfigLoader.spec.ts
    cd src && npx vitest run services/marketplace/__tests__/MarketplaceManager.spec.ts
    
  2. Manual testing (for users with proxy environments):

    • Configure VS Code's http.proxy setting
    • Open Roo Code marketplace page
    • Verify marketplace items load correctly

All unit tests pass (22 tests total across both files).

Pre-Submission Checklist

  • Issue Linked: This PR is linked to an approved GitHub Issue (see "Related GitHub Issue" above).
  • Scope: My changes are focused on the linked issue (one major feature/fix per PR).
  • Self-Review: I have performed a thorough self-review of my code.
  • Testing: New and/or updated tests have been added to cover my changes (if applicable).
  • Documentation Impact: I have considered if my changes require documentation updates (see "Documentation Updates" section below).
  • Contribution Guidelines: I have read and agree to the Contributor Guidelines.

Documentation Updates

  • No documentation updates are required.

Additional Notes

This fix follows the suggestion from @44010083 in the original issue. The native fetch API in VS Code extensions automatically inherits the proxy configuration, making this a much cleaner solution than manually configuring proxy agents.

Feedback and guidance are welcome!


Important

Replaces axios with fetch in RemoteConfigLoader for HTTP proxy support and updates tests accordingly.

  • Behavior:
    • Replaces axios with fetch in RemoteConfigLoader.ts to support HTTP proxy settings in VS Code.
    • Implements request timeout using AbortController.
    • Adds HTTP error status handling.
  • Tests:
    • Updates tests in RemoteConfigLoader.spec.ts and MarketplaceManager.spec.ts to mock fetch instead of axios.
    • Adds test for HTTP error response handling in RemoteConfigLoader.spec.ts.

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

…pport

This fix addresses Issue #10453 where marketplace items fail to load
in HTTP proxy environments. The native fetch API automatically respects
VS Code's http.proxy settings, unlike axios which requires manual
proxy agent configuration.

Changes:
- Replace axios.get with native fetch API in RemoteConfigLoader
- Implement timeout using AbortController
- Update tests to mock fetch instead of axios
- Remove unused axios mock from MarketplaceManager tests
@roomote
Copy link
Contributor Author

roomote bot commented Jan 8, 2026

Rooviewer Clock   See task on Roo Cloud

Review complete. No issues found.

The PR correctly replaces axios with the native fetch API to enable HTTP proxy support in VS Code environments. The implementation uses the standard AbortController pattern for timeouts and properly handles HTTP error responses. All 22 tests pass.

Mention @roomote in a comment to request specific changes to this pull request or fix all unresolved issues.

@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Jan 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels.

Projects

Status: Triage

Development

Successfully merging this pull request may close these issues.

[BUG] When in an HTTP proxy environment, MCPs and modes cannot be retrieved

3 participants