anomalyco / anomalyco/opencode

Loopback server URLs are misclassified as remote

Open Beginner friendly
#49,923 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
209k
Forks
27.5k
PR merge metrics
PR metrics pending

Description

Description

Explicit HTTP server connections are classified as local by slicing the URL string. Loopback URLs using uppercase LOCALHOST, IPv6 [::1], or user-info such as user@localhost are therefore treated as remote. This disables desktop-only local actions such as opening paths even though the server is on the local machine.

Plugins

None

OpenCode version

1.18.31

Steps to reproduce
  1. Call ServerConnection.local(...) for:
    • http://LOCALHOST:4096
    • http://user@localhost:4096
    • http://[::1]:4096
  2. Inspect each result.

Expected: all three loopback connections are local.
Actual: all three return false.

Screenshot and/or share link

Not applicable; focused classifier calls reproduce the result.

Operating System

All

Terminal

All

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the ServerConnection.local(...) entry point and reproduce the three loopback URL cases from the issue: uppercase LOCALHOST, user-info, and IPv6 [::1]. Done means each connection is classified as local and the existing focused classifier checks confirm the expected results.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
networking
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
78/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.