Skip to content

Orpc Doesn't Load the URL properlly in start, alchemy hono clodflare environment #1020

@Tenuka22

Description

@Tenuka22

Please help me I've been debugging for hours

Image When I remove this try catch block I get
Error: Not Found
       router https://_____workers.dev/admin/images:1
       <anonymous> https://____workers.dev/admin/images:38
   dist-w2TFgg8G.js:8:64119

It is requesting my /admin/images and it's not requesting the server. I've thrown the env values in the server and the values are proper. (No issue with env)

Image

For a env issue I've added clodflare env to runtime env

Image

I've not chnaged my ORPC client and tanstack logic (query), Also added a fallback on server url as well. But this occur, Becauseof this I'm unable to use preloading. Maybe There is something I'm missing out on

Image

Alchemy is sill the same with small tweaks // Also I've added tracing but I don't see console.logs (Maybe there is something I'm missing here)

{
  "defined": false,
  "level": "error",
  "code": "NOT_FOUND",
  "message": "Not Found",
  "data": {
    "headers": {
      "cache-control": "private, max-age=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0",
      "cf-ray": "9f0c5dcdd992fdc0-SIN",
      "content-length": "16",
      "content-type": "text/plain; charset=UTF-8",
      "date": "Thu, 23 Apr 2026 11:00:45 GMT",
      "expires": "Thu, 01 Jan 1970 00:00:01 GMT",
      "referrer-policy": "same-origin",
      "server": "cloudflare",
      "x-frame-options": "SAMEORIGIN"
    },
    "status": 404
  },
  "status": 404,
  "$workers": {
    "truncated": false,
    "event": {
      "request": {
        "url": "https://___-web-____dev/admin/images", // This is the issue 
        "method": "GET",
        "path": "/admin/images"
      }
    },
    "outcome": "ok",
    "scriptName": "noura-web-noura",
    "eventType": "fetch",
    "executionModel": "stateless",
    "scriptVersion": {
      "id": "31ae4c8e-f5df-4582-9c79-92e115782cd2"
    },
    "requestId": "9f0c5dcd7a73fd9a"
  },
  "$metadata": {
    "id": "01KPWZZQ52YZXFCN1A9EAX91WY",
    "requestId": "9f0c5dcd7a73fd9a",
    "trigger": "GET /admin/images",
    "service": "noura-web-noura",
    "level": "error",
    "error": "Not Found",
    "message": "Not Found",
    "account": "9195035a266fb69a67dae65447aaaf91",
    "type": "cf-worker",
    "fingerprint": "46b7d6a5a30fde42cb6ff921c9e65df6",
    "origin": "fetch",
    "messageTemplate": "Not Found"
  }
}

Issue clodflare trail

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions