adobe / adobe/aio-cli

🐞 GraphQL Mesh Queries Failing Locally with Internal Error

Open
#833 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
95
Forks
45
PR merge metrics
No merged PRs in 30d

Description

### **Description**

GraphQL queries executed via Adobe API Mesh have started failing locally with an internal error, despite no recent code changes.

The same codebase was working as expected approximately a month ago. The issue began occurring suddenly during local execution.

***

### **Environment Details**

* **CLI Version:** `@adobe/aio-cli@11.0.0`
* **Execution Command:**
```bash
aio api-mesh run mesh.json --port 9000
```
* **Environment:** Local development (macOS)

***

### **Observed Behaviour**

* All GraphQL queries error out during local execution.
* Resolver-level debugging logs show an internal error originating from GraphQL Mesh runtime.

#### **Error Trace**

```plaintext
Error: internal error; reference = n82otsafmt6lmr2k5rfakqen
at async wrappedFetchFn (file:///Users/prack/.local/share/@adobe/aio-cli/node_modules/@graphql-mesh/runtime/esm/get-mesh.js:57:24)
at async field.resolve (file:///Users/prack/.local/share/@adobe/aio-cli/node_modules/@omnigraph/json-schema/index.js:596:34)
at async Promise.all (index 1)
at async promiseForObject (file:///Users/prack/.local/share/@adobe/aio-cli/node_modules/@graphql-tools/executor/esm/execution/promiseForObject.js:11:28)
at null. (async file:///.../worker.js:28893:29)
at async Promise.all (index 0)
at async DataLoader4.batchExecuteLoadFn [as _batchLoadFn] (file:///Users/prack/.local/share/@adobe/aio-cli/node_modules/@graphql-tools/batch-execute/esm/createBatchingExecutor.js:37:25) {
path: [ 'hawksearch' ],
locations: undefined,
extensions: {}
}
```

***

### **Expected Behaviour**

* GraphQL queries should execute successfully as they did previously without any changes to the codebase or configuration.

***

### **Additional Context**

* No changes have been made to:
* Mesh configuration (`mesh.json`)
* Resolver logic
* Underlying APIs (as far as known)
* Issue seems to originate within the GraphQL Mesh runtime or a dependency update.
Wrangler logs show - workerd/jsg/util.c++:325: error: e = kj/compat/tls.c++:256: failed: TLS peer's certificate is not trusted; reason = self signed certificate in certificate chain

***

### **Request**

* Guidance on potential causes for this sudden failure.
* Any known issues with recent updates to `@adobe/aio-cli` or GraphQL Mesh dependencies.
* Suggested debugging steps or workarounds.

***

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the failure with `aio api-mesh run mesh.json --port 9000` and compare the GraphQL Mesh runtime trace with the Wrangler TLS error. Inspect the mentioned `mesh.json` configuration and runtime dependency versions; done means identifying whether the certificate or dependency issue causes the local query failures and documenting a confirmed workaround or next step.

Written by the indexing model from the issue text.

Assessment

Tech stack
graphql, javascript
Domain
api, cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.