Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions agents/package.json

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚩 examples/package.json still uses old 0.54.x OpenTelemetry versions

The examples/package.json still declares @opentelemetry/api-logs: ^0.54.0, @opentelemetry/exporter-logs-otlp-http: ^0.54.0, @opentelemetry/exporter-trace-otlp-http: ^0.54.0, @opentelemetry/otlp-exporter-base: ^0.54.0, and @opentelemetry/sdk-logs: ^0.54.0. The lockfile confirms that the examples workspace resolves these to 0.54.2 while the agents workspace resolves to 0.218.0. This means two different versions of these packages coexist in the monorepo. While examples is a private package and not published, this inconsistency could lead to confusing behavior when debugging telemetry in example agents. It may be worth updating examples to match.

Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,14 @@
"@livekit/throws-transformer": "0.1.8",
"@livekit/typed-emitter": "^3.0.0",
"@opentelemetry/api": "^1.9.0",
"@opentelemetry/api-logs": "^0.54.0",
"@opentelemetry/api-logs": "^0.219.0",
"@opentelemetry/core": "^2.2.0",
"@opentelemetry/exporter-logs-otlp-proto": "^0.54.0",
"@opentelemetry/exporter-trace-otlp-proto": "^0.54.0",
"@opentelemetry/exporter-logs-otlp-proto": "^0.219.0",
"@opentelemetry/exporter-trace-otlp-proto": "^0.219.0",
"@opentelemetry/instrumentation-pino": "^0.43.0",

@devin-ai-integration devin-ai-integration Bot Jun 11, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚩 instrumentation-pino still resolves to old api-logs version

The @opentelemetry/instrumentation-pino@0.43.0 package (specified in agents/package.json:65) still resolves to @opentelemetry/api-logs@0.54.2 according to the lockfile, while the direct dependency @opentelemetry/api-logs is now ^0.219.0. This means two different versions of api-logs are installed. Since instrumentation-pino uses its own copy internally for creating log records, and the agents code imports SeverityNumber from the top-level api-logs@0.219.0, there could be subtle enum value mismatches if SeverityNumber changed between versions. Worth verifying that the instrumentation-pino package is also compatible with the 0.219.x ecosystem.

Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

Comment on lines 58 to 65

@devin-ai-integration devin-ai-integration Bot Jun 11, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚩 Large version jump for api-logs, sdk-logs, and exporter packages (0.54.x → 0.214.x)

Four packages jump from 0.54.x to 0.214.x (api-logs, sdk-logs, exporter-logs-otlp-proto, exporter-trace-otlp-proto). This is due to the OpenTelemetry JS project's versioning realignment (experimental packages went from 0.5x to 0.200+ to match stable package versions). While the lockfile resolves and the key APIs used in the codebase (SeverityNumber enum values from api-logs, LogRecord/LogRecordProcessor from sdk-logs) are standardized OTLP types unlikely to have changed, this is a major jump spanning many releases. A full build verification (pnpm build) should be confirmed to pass, as well as runtime testing of the telemetry/tracing path (e.g., cloud tracer setup at agents/src/telemetry/traces.ts:213-280 and log export at agents/src/telemetry/otel_http_exporter.ts).

Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

"@opentelemetry/otlp-exporter-base": "^0.208.0",
"@opentelemetry/otlp-exporter-base": "^0.219.0",
"@opentelemetry/resources": "^1.28.0",
"@opentelemetry/sdk-logs": "^0.54.0",
"@opentelemetry/sdk-logs": "^0.219.0",
"@opentelemetry/sdk-trace-base": "^1.28.0",
"@opentelemetry/sdk-trace-node": "^1.28.0",
Comment on lines 69 to 70

@devin-ai-integration devin-ai-integration Bot May 1, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔴 Trace exporter version mismatch causes incompatible span processing at runtime

The experimental OpenTelemetry packages are updated to 0.219.x (agents/package.json:61-68) without updating the stable packages (sdk-trace-base, sdk-trace-node, resources) from 1.x to the required 2.x, so the trace exporter may fail to serialize spans correctly.

Impact: Traces exported to LiveKit Cloud observability may be malformed or silently dropped because the exporter expects 2.x span structures but receives 1.x spans.

Version compatibility matrix violation between OTel experimental and stable packages

The OpenTelemetry JS ecosystem requires version-aligned groups:

  • Experimental 0.54.x works with stable 1.x
  • Experimental 0.219.x works with stable 2.x

The lockfile confirms the mismatch:

  • @opentelemetry/exporter-trace-otlp-proto@0.219.0 depends on @opentelemetry/sdk-trace-base@2.8.0 and @opentelemetry/resources@2.8.0
  • @opentelemetry/sdk-trace-node@1.30.1 (from the unchanged ^1.28.0 specifier) depends on @opentelemetry/sdk-trace-base@1.30.1

In agents/src/telemetry/traces.ts:256-265, the code creates an OTLPTraceExporter (0.219.0, internally linked to sdk-trace-base@2.8.0) and passes it to BatchSpanProcessor from sdk-trace-node@1.30.1. At runtime:

  1. NodeTracerProvider (1.x) creates spans as ReadableSpan from sdk-trace-base@1.30.1
  2. BatchSpanProcessor (1.x) passes those spans to OTLPTraceExporter.export()
  3. The exporter's otlp-transformer@0.219.0 serializes spans expecting ReadableSpan from sdk-trace-base@2.8.0

Between major versions, ReadableSpan had breaking changes (resource type changed from Resource class to IResource interface, time representation changes). The transformer may access properties that are missing or structured differently on 1.x spans.

The fix should also update:

  • @opentelemetry/sdk-trace-base to ^2.8.0
  • @opentelemetry/sdk-trace-node to ^2.8.0
  • @opentelemetry/resources to ^2.8.0
Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

"@opentelemetry/semantic-conventions": "^1.28.0",
Expand Down
Loading
Loading