Skip to content

HttpRunner.layerHttpOptions results in double-slash routing #5919

@sdemjanenko

Description

@sdemjanenko

What version of Effect is running?

@effect/rpc: 0.72.2

What steps can reproduce the bug?

When using HttpRunner.layerHttpOptions:

 const HttpRunnerWithHealthLayer = HttpLayerRouter.serve(
  Layer.merge(HttpRunner.layerHttpOptions({ path: '/' }), HealthRouteLayer)
).pipe(Layer.provide(HttpRunner.layerClientProtocolHttpDefault));

The URL that is generated begins with //

I noticed this in server logs

[02:39:58.131] INFO (#97) http.span.2=2ms:
  RouteNotFound: POST // not found
      at http.server POST
  http.status: 404
  http.method: POST
  http.url: //

What is the expected behavior?

No response

What do you see instead?

No response

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions