Open buildbreaker opened 3 weeks ago
I'm using dd-api-client on frontend with a proxy to my backend to proxy the requests.
When updating to 1.26.0 I started receiving this error on the frontend
An error occurred during the HTTP request: TypeError: Failed to execute 'fetch' on 'Window': Illegal invocation
I feel like this error is related to the one reported on this issue
Describe the bug I'm currently using the datadog api client within my cloudflare worker and I recently updated the client from version 1.24 to 1.27. I ran into this error since the update:
I took a look at the changes across the different versions and found this PR: https://github.com/DataDog/datadog-api-client-typescript/pull/1646
It looks like that might be that change that caused the error I started observing. I was able to resolve my problem by downgrading back to 1.24.
To Reproduce Steps to reproduce the behavior: Try calling a datadog api client within a CF worker context. It's tail logs describe the error I shared. (I can provide a repo which can be used to test if that's desired)
Expected behavior I would like to expect that the latest datadog client continues to send requests in my cloudflare worker.
Screenshots n/a
Environment and Versions (please complete the following information): A clear and precise description of your setup:
version for this project in use. 1.27 (but it looks like any version that is 1.26 or later)
services, libraries, languages and tools list and versions. package.json:
Additional context I am guessing this has to do with the CF runtime releasing the
this
reference in the PR when the client attempts to make the fetch request call.cc @linnea-moment