Skip to content

refactor(core): remove temporary locationServiceMapLayer constant#35052

Closed
Robin1987China wants to merge 1 commit into
anomalyco:devfrom
Robin1987China:deprecate-location-service-map-layer
Closed

refactor(core): remove temporary locationServiceMapLayer constant#35052
Robin1987China wants to merge 1 commit into
anomalyco:devfrom
Robin1987China:deprecate-location-service-map-layer

Conversation

@Robin1987China

Copy link
Copy Markdown
Contributor

Issue for this PR

N/A

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Remove the temporary locationServiceMapLayer singleton from packages/core/src/location-services.ts. It was marked // This is temporary for backwards compatibility and wraps buildLocationServiceMap(). Having both the singleton and the factory creates API confusion.

All 8 call sites (7 source + 1 test) are migrated to use buildLocationServiceMap() directly. The call sites in server.ts were already migrated upstream. Pure mechanical replacement, no behavior change.

How did you verify your code works?

  • All existing tests pass (25/25: core layer-node + location-layer + opencode system)
  • Full typecheck passes (bun typecheck, 35 packages)
  • grep -r locationServiceMapLayer returns zero results in packages/

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@Robin1987China Robin1987China force-pushed the deprecate-location-service-map-layer branch 2 times, most recently from b77ff1b to e30e0b4 Compare July 3, 2026 05:58
All call sites migrated to buildLocationServiceMap() factory.
The constant was marked 'temporary for backwards compatibility'
and its usage in server.ts was already migrated upstream.
@Robin1987China Robin1987China force-pushed the deprecate-location-service-map-layer branch from e30e0b4 to 88ff1cf Compare July 9, 2026 05:39
@Robin1987China

Copy link
Copy Markdown
Contributor Author

Closing in favor of #36204, which retargets this change to the v2 branch where the active V2 session/location-core work is being reviewed. The fix is identical (code is the same on both branches).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant