@channel Hello team, the below function is getting...
# support
m
@channel Hello team, the below function is getting in red color while integrating with the react project registerInstrumentations({ instrumentations: [ new FetchInstrumentation({ propagateTraceHeaderCorsUrls: ["/.*/g"], clearTimingResources: true, applyCustomAttributesOnSpan: ( span: Span, request: Request | RequestInit, result: Response | FetchError ) => { const attributes = (span as any).attributes; if (attributes.component === "fetch") { span.updateName(
${attributes["http.method"]} ${attributes["http.url"]}
); } if (result instanceof Error) { span.setStatus({ code: SpanStatusCode.ERROR, message: result.message, }); span.recordException(result.stack || result.name); } }, }), ], });
p
you mean
registerInstrumentations
functions?
m
yes
p
@Mohit Verma I think you are facing issues with not setting up the libraries correctly. Can you try instrumenting a simple app before getting more complex. May be just instrument a sample
create-react-app
m
yes sampled the basic one now
and followed the docs
p
so, are things working for a basic app?
m
no, the traces are getting failed
for teh given example in the doc
attached screenshot please have a look at it
p
oh, what are the error messages? Is SigNoz installed correctly? Also, can you run this troubleshooting binary where you are running your application and share what output you get? https://signoz.io/docs/install/troubleshooting/#using-troubleshooting-repository
m
ok doing
please let me know if any support person can connect once