diff --git a/CHANGELOG.md b/CHANGELOG.md index 90f5b28b292..7b2d2e6ec65 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -80,6 +80,18 @@ For semantic convention package changes, see the [semconv CHANGELOG](packages/se * chore!: Raise the minimum supported Node.js version to `^18.19.0 || >=20.6.0`. Support for Node.js 14, 16, and early minor versions of 18 and 20 have been dropped. This applies to all packages except the 'api' and 'semantic-conventions' packages. [#5395](https://github.com/open-telemetry/opentelemetry-js/issues/5395) @trentm * feat(core)!: remove TracesSamplerValues from exports [#5406](https://github.com/open-telemetry/opentelemetry-js/pull/5406) @pichlermarc * (user-facing): TracesSamplerValues was only consumed internally and has been removed from exports without replacement +* feat(core)!: remove unused and obsolete functions and types [#5444](https://github.com/open-telemetry/opentelemetry-js/pull/5444) @pichlermarc + * (user-facing): `VERSION` was an internal constant that was unintentionally exported. It has been removed without replacement. + * (user-facing): `isWrapped` has been removed in favor of `isWrapped` from `@opentelemetry/instrumentation` + * (user-facing): `ShimWrapped` has been removed in favor of `ShimWrapped` from `@opentelemetry/instrumentation` + * (user-facing): `hexToBase64` was a utility function that is not used by the SDK anymore. It has been removed without replacement. + * (user-facing): `hexToBinary` was a utility function that now internal to `@opentelemetry/otlp-tranformer`. It has been removed without replacement. + * (user-facing): `baggageUtils.getKeyParis` was an internal utility function that was unintentionally exported. It has been removed without replacement. + * (user-facing): `baggageUtils.serializeKeyPairs` was an internal utility function that was unintentionally exported. It has been removed without replacement. + * (user-facing): `baggageUtils.parseKeyPairsIntoRecord,` has been removed in favor of `parseKeyPairsIntoRecord` + * (user-facing): `baggageUtils.parsePairKeyValue` was an internal utility function that was unintentionally exported. It has been removed without replacement. + * (user-facing): `TimeOriginLegacy` has been removed without replacement. + * (user-facing): `isAttributeKey` was an internal utility function that was unintentionally exported. It has been removed without replacement. ### :rocket: (Enhancement) diff --git a/experimental/packages/opentelemetry-instrumentation-xml-http-request/test/xhr.test.ts b/experimental/packages/opentelemetry-instrumentation-xml-http-request/test/xhr.test.ts index e2f74d48b74..8ee8643c078 100644 --- a/experimental/packages/opentelemetry-instrumentation-xml-http-request/test/xhr.test.ts +++ b/experimental/packages/opentelemetry-instrumentation-xml-http-request/test/xhr.test.ts @@ -14,8 +14,11 @@ * limitations under the License. */ import * as api from '@opentelemetry/api'; -import { otperformance as performance, isWrapped } from '@opentelemetry/core'; -import { registerInstrumentations } from '@opentelemetry/instrumentation'; +import { otperformance as performance } from '@opentelemetry/core'; +import { + registerInstrumentations, + isWrapped, +} from '@opentelemetry/instrumentation'; import { B3Propagator, B3InjectEncoding, diff --git a/experimental/packages/otlp-exporter-base/src/configuration/otlp-http-env-configuration.ts b/experimental/packages/otlp-exporter-base/src/configuration/otlp-http-env-configuration.ts index ba05242c9c1..220eb57a1b7 100644 --- a/experimental/packages/otlp-exporter-base/src/configuration/otlp-http-env-configuration.ts +++ b/experimental/packages/otlp-exporter-base/src/configuration/otlp-http-env-configuration.ts @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -import { baggageUtils } from '@opentelemetry/core'; +import { parseKeyPairsIntoRecord } from '@opentelemetry/core'; import { diag } from '@opentelemetry/api'; import { getSharedConfigurationFromEnvironment } from './shared-env-configuration'; import { OtlpHttpConfiguration } from './otlp-http-configuration'; @@ -27,10 +27,10 @@ function getStaticHeadersFromEnv( const nonSignalSpecificRawHeaders = process.env['OTEL_EXPORTER_OTLP_HEADERS']?.trim(); - const signalSpecificHeaders = baggageUtils.parseKeyPairsIntoRecord( + const signalSpecificHeaders = parseKeyPairsIntoRecord( signalSpecificRawHeaders ); - const nonSignalSpecificHeaders = baggageUtils.parseKeyPairsIntoRecord( + const nonSignalSpecificHeaders = parseKeyPairsIntoRecord( nonSignalSpecificRawHeaders ); @@ -45,8 +45,8 @@ function getStaticHeadersFromEnv( // the non-specific ones. return Object.assign( {}, - baggageUtils.parseKeyPairsIntoRecord(nonSignalSpecificRawHeaders), - baggageUtils.parseKeyPairsIntoRecord(signalSpecificRawHeaders) + parseKeyPairsIntoRecord(nonSignalSpecificRawHeaders), + parseKeyPairsIntoRecord(signalSpecificRawHeaders) ); } diff --git a/experimental/packages/otlp-grpc-exporter-base/src/configuration/otlp-grpc-env-configuration.ts b/experimental/packages/otlp-grpc-exporter-base/src/configuration/otlp-grpc-env-configuration.ts index e0c10adcd45..d4017d8ca00 100644 --- a/experimental/packages/otlp-grpc-exporter-base/src/configuration/otlp-grpc-env-configuration.ts +++ b/experimental/packages/otlp-grpc-exporter-base/src/configuration/otlp-grpc-env-configuration.ts @@ -15,7 +15,7 @@ */ import { UnresolvedOtlpGrpcConfiguration } from './otlp-grpc-configuration'; import type { ChannelCredentials, Metadata } from '@grpc/grpc-js'; -import { baggageUtils } from '@opentelemetry/core'; +import { parseKeyPairsIntoRecord } from '@opentelemetry/core'; import { createEmptyMetadata, createInsecureCredentials, @@ -47,10 +47,10 @@ function getMetadataFromEnv(signalIdentifier: string): Metadata | undefined { const nonSignalSpecificRawHeaders = process.env['OTEL_EXPORTER_OTLP_HEADERS']?.trim(); - const signalSpecificHeaders = baggageUtils.parseKeyPairsIntoRecord( + const signalSpecificHeaders = parseKeyPairsIntoRecord( signalSpecificRawHeaders ); - const nonSignalSpecificHeaders = baggageUtils.parseKeyPairsIntoRecord( + const nonSignalSpecificHeaders = parseKeyPairsIntoRecord( nonSignalSpecificRawHeaders ); diff --git a/packages/opentelemetry-core/src/common/hex-to-binary.ts b/experimental/packages/otlp-transformer/src/common/hex-to-binary.ts similarity index 100% rename from packages/opentelemetry-core/src/common/hex-to-binary.ts rename to experimental/packages/otlp-transformer/src/common/hex-to-binary.ts diff --git a/experimental/packages/otlp-transformer/src/common/utils.ts b/experimental/packages/otlp-transformer/src/common/utils.ts index 1d3fd73c580..756e80f4a4d 100644 --- a/experimental/packages/otlp-transformer/src/common/utils.ts +++ b/experimental/packages/otlp-transformer/src/common/utils.ts @@ -16,7 +16,8 @@ import type { OtlpEncodingOptions, Fixed64, LongBits } from './internal-types'; import { HrTime } from '@opentelemetry/api'; -import { hexToBinary, hrTimeToNanoseconds } from '@opentelemetry/core'; +import { hrTimeToNanoseconds } from '@opentelemetry/core'; +import { hexToBinary } from './hex-to-binary'; export function hrTimeToNanos(hrTime: HrTime): bigint { const NANOSECONDS = BigInt(1_000_000_000); diff --git a/experimental/packages/otlp-transformer/test/common.test.ts b/experimental/packages/otlp-transformer/test/common.test.ts index a3d05aaa6a3..38444c48914 100644 --- a/experimental/packages/otlp-transformer/test/common.test.ts +++ b/experimental/packages/otlp-transformer/test/common.test.ts @@ -14,10 +14,10 @@ * limitations under the License. */ -import { hexToBinary } from '@opentelemetry/core'; import { toAnyValue } from '../src/common/internal'; import * as assert from 'assert'; import { getOtlpEncoder } from '../src/common/utils'; +import { hexToBinary } from '../src/common/hex-to-binary'; const traceId = 'abcdef01234567890000000000000000'; const spanId = '12341234abcdabcd'; diff --git a/experimental/packages/otlp-transformer/test/logs.test.ts b/experimental/packages/otlp-transformer/test/logs.test.ts index 656a03c1224..2d14bcd6cbc 100644 --- a/experimental/packages/otlp-transformer/test/logs.test.ts +++ b/experimental/packages/otlp-transformer/test/logs.test.ts @@ -14,7 +14,7 @@ * limitations under the License. */ import { HrTime, TraceFlags } from '@opentelemetry/api'; -import { InstrumentationScope, hexToBinary } from '@opentelemetry/core'; +import { InstrumentationScope } from '@opentelemetry/core'; import { Resource } from '@opentelemetry/resources'; import * as assert from 'assert'; import { ReadableLogRecord } from '@opentelemetry/sdk-logs'; @@ -29,6 +29,7 @@ import { import { createExportLogsServiceRequest } from '../src/logs/internal'; import { ProtobufLogsSerializer } from '../src/logs/protobuf'; import { JsonLogsSerializer } from '../src/logs/json'; +import { hexToBinary } from '../src/common/hex-to-binary'; function createExpectedLogJson( options: OtlpEncodingOptions diff --git a/experimental/packages/otlp-transformer/test/trace.test.ts b/experimental/packages/otlp-transformer/test/trace.test.ts index 7fa0be3674b..a4ae8b0ce02 100644 --- a/experimental/packages/otlp-transformer/test/trace.test.ts +++ b/experimental/packages/otlp-transformer/test/trace.test.ts @@ -15,7 +15,7 @@ */ import * as root from '../src/generated/root'; import { SpanKind, SpanStatusCode, TraceFlags } from '@opentelemetry/api'; -import { TraceState, hexToBinary } from '@opentelemetry/core'; +import { TraceState } from '@opentelemetry/core'; import { Resource } from '@opentelemetry/resources'; import { ReadableSpan } from '@opentelemetry/sdk-trace-base'; import * as assert from 'assert'; @@ -25,6 +25,7 @@ import { ESpanKind, EStatusCode } from '../src/trace/internal-types'; import { createExportTraceServiceRequest } from '../src/trace/internal'; import { ProtobufTraceSerializer } from '../src/trace/protobuf'; import { JsonTraceSerializer } from '../src/trace/json'; +import { hexToBinary } from '../src/common/hex-to-binary'; function createExpectedSpanJson(options: OtlpEncodingOptions) { const useHex = options.useHex ?? false; diff --git a/experimental/packages/otlp-transformer/test/utils.ts b/experimental/packages/otlp-transformer/test/utils.ts index d13c9cf314c..f9856f5f507 100644 --- a/experimental/packages/otlp-transformer/test/utils.ts +++ b/experimental/packages/otlp-transformer/test/utils.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import { hexToBinary } from '@opentelemetry/core'; +import { hexToBinary } from '../src/common/hex-to-binary'; /** * utility function to convert a string representing a hex value to a base64 string diff --git a/integration-tests/api/test/core-entries.test.js b/integration-tests/api/test/core-entries.test.js deleted file mode 100644 index 423ccf0ca2a..00000000000 --- a/integration-tests/api/test/core-entries.test.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright The OpenTelemetry Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -const assert = require('assert'); - -// Using `node16` or `nodenext` in `tsconfig.json#moduleResolution` -// requires the TypeScript to generate ESModule outputs. This is a breaking -// change for CJS users. -// So we have to use plain JavaScript to verify the `package.json#exports` here. - -describe('@opentelemetry/core entries', () => { - it('should import baggage utils under named const', async () => { - const mod = await import('@opentelemetry/core'); - assert.ok(mod.baggageUtils.getKeyPairs != null); - }); - - it('should require baggage utils under named const', () => { - const mod = require('@opentelemetry/core'); - assert.ok(mod.baggageUtils.getKeyPairs != null); - }); -}); diff --git a/packages/opentelemetry-core/src/index.ts b/packages/opentelemetry-core/src/index.ts index d9143bff357..992304beff1 100644 --- a/packages/opentelemetry-core/src/index.ts +++ b/packages/opentelemetry-core/src/index.ts @@ -16,11 +16,7 @@ export { W3CBaggagePropagator } from './baggage/propagation/W3CBaggagePropagator'; export { AnchoredClock, Clock } from './common/anchored-clock'; -export { - isAttributeKey, - isAttributeValue, - sanitizeAttributes, -} from './common/attributes'; +export { isAttributeValue, sanitizeAttributes } from './common/attributes'; export { globalErrorHandler, setGlobalErrorHandler, @@ -40,32 +36,14 @@ export { millisToHrTime, timeInputToHrTime, } from './common/time'; -export { - ErrorHandler, - InstrumentationScope, - ShimWrapped, - TimeOriginLegacy, -} from './common/types'; -export { hexToBinary } from './common/hex-to-binary'; +export { ErrorHandler, InstrumentationScope } from './common/types'; export { ExportResult, ExportResultCode } from './ExportResult'; -import { - getKeyPairs, - serializeKeyPairs, - parseKeyPairsIntoRecord, - parsePairKeyValue, -} from './baggage/utils'; -export const baggageUtils = { - getKeyPairs, - serializeKeyPairs, - parseKeyPairsIntoRecord, - parsePairKeyValue, -}; +export { parseKeyPairsIntoRecord } from './baggage/utils'; export { SDK_INFO, _globalThis, getEnv, getEnvWithoutDefaults, - hexToBase64, otperformance, unrefTimer, } from './platform'; @@ -105,9 +83,7 @@ export { export { merge } from './utils/merge'; export { TimeoutError, callWithTimeout } from './utils/timeout'; export { isUrlIgnored, urlMatches } from './utils/url'; -export { isWrapped } from './utils/wrap'; export { BindOnceFuture } from './utils/callback'; -export { VERSION } from './version'; import { _export } from './internal/exporter'; export const internal = { _export, diff --git a/packages/opentelemetry-core/src/platform/browser/hex-to-base64.ts b/packages/opentelemetry-core/src/platform/browser/hex-to-base64.ts deleted file mode 100644 index dee61ec727d..00000000000 --- a/packages/opentelemetry-core/src/platform/browser/hex-to-base64.ts +++ /dev/null @@ -1,21 +0,0 @@ -/* - * Copyright The OpenTelemetry Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { hexToBinary } from '../../common/hex-to-binary'; - -export function hexToBase64(hexStr: string): string { - return btoa(String.fromCharCode(...hexToBinary(hexStr))); -} diff --git a/packages/opentelemetry-core/src/platform/browser/index.ts b/packages/opentelemetry-core/src/platform/browser/index.ts index 7ce43661f36..75440efebd0 100644 --- a/packages/opentelemetry-core/src/platform/browser/index.ts +++ b/packages/opentelemetry-core/src/platform/browser/index.ts @@ -16,7 +16,6 @@ export { getEnvWithoutDefaults, getEnv } from './environment'; export { _globalThis } from './globalThis'; -export { hexToBase64 } from './hex-to-base64'; export { otperformance } from './performance'; export { SDK_INFO } from './sdk-info'; export { unrefTimer } from './timer-util'; diff --git a/packages/opentelemetry-core/src/platform/index.ts b/packages/opentelemetry-core/src/platform/index.ts index b0c9af51158..c61187bc426 100644 --- a/packages/opentelemetry-core/src/platform/index.ts +++ b/packages/opentelemetry-core/src/platform/index.ts @@ -18,7 +18,6 @@ export { _globalThis, getEnv, getEnvWithoutDefaults, - hexToBase64, otperformance, unrefTimer, } from './node'; diff --git a/packages/opentelemetry-core/src/platform/node/hex-to-base64.ts b/packages/opentelemetry-core/src/platform/node/hex-to-base64.ts deleted file mode 100644 index 7be359e6512..00000000000 --- a/packages/opentelemetry-core/src/platform/node/hex-to-base64.ts +++ /dev/null @@ -1,20 +0,0 @@ -/* - * Copyright The OpenTelemetry Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -import { hexToBinary } from '../../common/hex-to-binary'; - -export function hexToBase64(hexStr: string): string { - return Buffer.from(hexToBinary(hexStr)).toString('base64'); -} diff --git a/packages/opentelemetry-core/src/platform/node/index.ts b/packages/opentelemetry-core/src/platform/node/index.ts index 7ce43661f36..75440efebd0 100644 --- a/packages/opentelemetry-core/src/platform/node/index.ts +++ b/packages/opentelemetry-core/src/platform/node/index.ts @@ -16,7 +16,6 @@ export { getEnvWithoutDefaults, getEnv } from './environment'; export { _globalThis } from './globalThis'; -export { hexToBase64 } from './hex-to-base64'; export { otperformance } from './performance'; export { SDK_INFO } from './sdk-info'; export { unrefTimer } from './timer-util'; diff --git a/packages/opentelemetry-core/src/utils/wrap.ts b/packages/opentelemetry-core/src/utils/wrap.ts deleted file mode 100644 index a32da964634..00000000000 --- a/packages/opentelemetry-core/src/utils/wrap.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright The OpenTelemetry Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { ShimWrapped } from '../common/types'; - -/** - * Checks if certain function has been already wrapped - * @param func - */ -export function isWrapped(func: unknown): func is ShimWrapped { - return ( - typeof func === 'function' && - typeof (func as ShimWrapped).__original === 'function' && - typeof (func as ShimWrapped).__unwrap === 'function' && - (func as ShimWrapped).__wrapped === true - ); -} diff --git a/packages/opentelemetry-core/test/platform/hex-to-base64.test.ts b/packages/opentelemetry-core/test/platform/hex-to-base64.test.ts deleted file mode 100644 index 3249621072f..00000000000 --- a/packages/opentelemetry-core/test/platform/hex-to-base64.test.ts +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright The OpenTelemetry Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import * as assert from 'assert'; -import { hexToBase64 } from '../../src/platform'; - -describe('hexToBase64', () => { - it('convert hex to base64', () => { - const id1 = '7deb739e02e44ef2'; - const id2 = '12abc034d567e89ff26e608c8cf42c80'; - const id3 = id2.toUpperCase(); - assert.strictEqual(hexToBase64(id1), 'fetzngLkTvI='); - assert.strictEqual(hexToBase64(id2), 'EqvANNVn6J/ybmCMjPQsgA=='); - assert.strictEqual(hexToBase64(id3), 'EqvANNVn6J/ybmCMjPQsgA=='); - // Don't use the preallocated path - assert.strictEqual( - hexToBase64(id2.repeat(2)), - 'EqvANNVn6J/ybmCMjPQsgBKrwDTVZ+if8m5gjIz0LIA=' - ); - }); -}); diff --git a/packages/opentelemetry-core/test/utils/wrap.test.ts b/packages/opentelemetry-core/test/utils/wrap.test.ts deleted file mode 100644 index 5c9b91f85de..00000000000 --- a/packages/opentelemetry-core/test/utils/wrap.test.ts +++ /dev/null @@ -1,82 +0,0 @@ -/* - * Copyright The OpenTelemetry Authors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import * as assert from 'assert'; - -import { isWrapped, ShimWrapped } from '../../src'; - -function makeWrapped( - wrapped: unknown, - unwrap: any, - original: any -): ShimWrapped { - const wrapper = function () {}; - defineProperty(wrapper, '__wrapped', wrapped); - defineProperty(wrapper, '__unwrap', unwrap); - defineProperty(wrapper, '__original', original); - return wrapper as unknown as ShimWrapped; -} - -function defineProperty(obj: any, name: string, value: unknown) { - // eslint-disable-next-line no-prototype-builtins - const enumerable = !!obj[name] && obj.propertyIsEnumerable(name); - Object.defineProperty(obj, name, { - configurable: true, - enumerable: enumerable, - writable: true, - value: value, - }); -} - -const notWrappedFunctions: any[] = []; -notWrappedFunctions.push( - makeWrapped( - false, - () => {}, - () => {} - ) -); -notWrappedFunctions.push(makeWrapped(false, 'foo', () => {})); -notWrappedFunctions.push(makeWrapped(false, () => {}, 'foo')); -notWrappedFunctions.push({ - __wrapped: true, - __unwrap: function () {}, - __original: function () {}, -}); - -describe('utils-wrap', () => { - describe('isWrapped', () => { - it('should return true when function was wrapped', () => { - const wrapped: ShimWrapped = makeWrapped( - true, - () => {}, - () => {} - ); - assert.strictEqual(isWrapped(wrapped), true, 'function is not wrapped'); - }); - - it('should return false when function is not wrapped', () => { - notWrappedFunctions.forEach((wrapped: unknown, index: number) => { - const result = isWrapped(wrapped as ShimWrapped); - assert.strictEqual( - result, - false, - `function number #${index} is wrapped` - ); - }); - }); - }); -}); diff --git a/packages/opentelemetry-exporter-zipkin/test/common/transform.test.ts b/packages/opentelemetry-exporter-zipkin/test/common/transform.test.ts index 0c78dbbcf87..c580a07ca24 100644 --- a/packages/opentelemetry-exporter-zipkin/test/common/transform.test.ts +++ b/packages/opentelemetry-exporter-zipkin/test/common/transform.test.ts @@ -20,7 +20,6 @@ import { hrTimeDuration, hrTimeToMicroseconds, millisToHrTime, - VERSION, } from '@opentelemetry/core'; import { IResource } from '@opentelemetry/resources'; import { ReadableSpan } from '@opentelemetry/sdk-trace-base'; @@ -34,6 +33,7 @@ import { _toZipkinTags, } from '../../src/transform'; import * as zipkinTypes from '../../src/types'; +import { VERSION } from '../../src/version'; const resource = { attributes: {