playwright-opentelemetry 0.18.1 → 0.18.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/fixture.cjs CHANGED
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_screenshots_zip = require("./screenshots-zip-Cy2Wivw7.cjs");
2
+ const require_screenshots_zip = require("./screenshots-zip-nJZiEIbI.cjs");
3
3
  let node_fs_promises = require("node:fs/promises");
4
4
  node_fs_promises = require_screenshots_zip.__toESM(node_fs_promises, 1);
5
5
  let node_path = require("node:path");
package/dist/fixture.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { T as generateSpanId, a as supportsScreencastScreenshots, b as writeFixtureHandoffFile, d as flushFixtureSpans, f as registerExpectedTrace, g as SCREENSHOTS_HANDOFF_FILE, m as shouldRetainPlaywrightTrace, o as resolvePlaywrightOpentelemetryConfig, p as couldRetainPlaywrightTrace, r as createScreenshotsZip, s as BROWSER_SERVICE_NAME, t as SCREENSHOTS_ATTACHMENT_NAME, u as createTestTraceContext, x as filterRetainedDestinations } from "./screenshots-zip-CU1X4mzh.mjs";
1
+ import { T as generateSpanId, a as supportsScreencastScreenshots, b as writeFixtureHandoffFile, d as flushFixtureSpans, f as registerExpectedTrace, g as SCREENSHOTS_HANDOFF_FILE, m as shouldRetainPlaywrightTrace, o as resolvePlaywrightOpentelemetryConfig, p as couldRetainPlaywrightTrace, r as createScreenshotsZip, s as BROWSER_SERVICE_NAME, t as SCREENSHOTS_ATTACHMENT_NAME, u as createTestTraceContext, x as filterRetainedDestinations } from "./screenshots-zip-DnK_MAtf.mjs";
2
2
  import fs from "node:fs/promises";
3
3
  import path from "node:path";
4
4
  import { test as test$1 } from "@playwright/test";
package/dist/index.cjs CHANGED
@@ -1,4 +1,4 @@
1
1
  //#region src/index.ts
2
- var src_default = require("./reporter-BuViICz8.cjs").PlaywrightOpentelemetryReporter;
2
+ var src_default = require("./reporter-D4i206BM.cjs").PlaywrightOpentelemetryReporter;
3
3
  //#endregion
4
4
  module.exports = src_default;
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { t as PlaywrightOpentelemetryReporter } from "./reporter-_CyyuDJs.mjs";
1
+ import { t as PlaywrightOpentelemetryReporter } from "./reporter-DKhFsfiL.mjs";
2
2
  //#region src/index.ts
3
3
  var src_default = PlaywrightOpentelemetryReporter;
4
4
  //#endregion
@@ -1,4 +1,4 @@
1
- const require_screenshots_zip = require("./screenshots-zip-Cy2Wivw7.cjs");
1
+ const require_screenshots_zip = require("./screenshots-zip-nJZiEIbI.cjs");
2
2
  let node_fs = require("node:fs");
3
3
  node_fs = require_screenshots_zip.__toESM(node_fs, 1);
4
4
  let node_fs_promises = require("node:fs/promises");
@@ -9,6 +9,7 @@ let _zip_js_zip_js = require("@zip.js/zip.js");
9
9
  //#region src/reporter/otel-attributes.ts
10
10
  const ATTR_CODE_FILE_PATH = "code.file.path";
11
11
  const ATTR_CODE_LINE_NUMBER = "code.line.number";
12
+ const ATTR_CODE_COLUMN_NUMBER = "code.column.number";
12
13
  const ATTR_TEST_CASE_NAME = "test.case.name";
13
14
  const ATTR_TEST_CASE_TITLE = "test.case.title";
14
15
  const ATTR_TEST_CASE_RESULT_STATUS = "test.case.result.status";
@@ -231,9 +232,10 @@ var PlaywrightOpentelemetryReporter = class {
231
232
  attributes["playwright.test.status"] = result.status;
232
233
  attributes["playwright.test.describes"] = describes;
233
234
  if (test.location) {
234
- const { file, line } = test.location;
235
+ const { file, line, column } = test.location;
235
236
  attributes[ATTR_CODE_FILE_PATH] = this.rootDir ? node_path.default.relative(this.rootDir, file) : file;
236
237
  attributes[ATTR_CODE_LINE_NUMBER] = line;
238
+ attributes[ATTR_CODE_COLUMN_NUMBER] = column;
237
239
  }
238
240
  const stepSpans = [];
239
241
  for (const step of result.steps ?? []) this.processTestStep(step, testSpanId, traceId, [], stepSpans);
@@ -388,9 +390,10 @@ var PlaywrightOpentelemetryReporter = class {
388
390
  attributes[ATTR_TEST_STEP_CATEGORY] = step.category;
389
391
  if (phase) attributes[ATTR_TEST_PHASE] = phase;
390
392
  if (step.location) {
391
- const { file, line } = step.location;
393
+ const { file, line, column } = step.location;
392
394
  attributes[ATTR_CODE_FILE_PATH] = this.rootDir ? node_path.default.relative(this.rootDir, file) : file;
393
395
  attributes[ATTR_CODE_LINE_NUMBER] = line;
396
+ attributes[ATTR_CODE_COLUMN_NUMBER] = column;
394
397
  }
395
398
  const stepSpan = {
396
399
  traceId,
@@ -1,4 +1,4 @@
1
- import { C as PLAYWRIGHT_TRACE_API_SOURCE_REPORTER, D as sendSpans, E as generateTraceId, O as withPlaywrightTraceApiHeaders, S as PLAYWRIGHT_TRACE_API_SOURCE_HEADER, T as generateSpanId, a as supportsScreencastScreenshots, c as FIXTURE_SPANS_ATTACHMENT_NAME, i as readScreenshotsZip, l as TRACE_CONTEXT_ATTACHMENT_NAME, m as shouldRetainPlaywrightTrace, n as addScreenshotsToZip, o as resolvePlaywrightOpentelemetryConfig, r as createScreenshotsZip, t as SCREENSHOTS_ATTACHMENT_NAME, v as fixtureHandoffDir, w as buildOtlpRequest, x as filterRetainedDestinations, y as fixtureHandoffRoot } from "./screenshots-zip-CU1X4mzh.mjs";
1
+ import { C as PLAYWRIGHT_TRACE_API_SOURCE_REPORTER, D as sendSpans, E as generateTraceId, O as withPlaywrightTraceApiHeaders, S as PLAYWRIGHT_TRACE_API_SOURCE_HEADER, T as generateSpanId, a as supportsScreencastScreenshots, c as FIXTURE_SPANS_ATTACHMENT_NAME, i as readScreenshotsZip, l as TRACE_CONTEXT_ATTACHMENT_NAME, m as shouldRetainPlaywrightTrace, n as addScreenshotsToZip, o as resolvePlaywrightOpentelemetryConfig, r as createScreenshotsZip, t as SCREENSHOTS_ATTACHMENT_NAME, v as fixtureHandoffDir, w as buildOtlpRequest, x as filterRetainedDestinations, y as fixtureHandoffRoot } from "./screenshots-zip-DnK_MAtf.mjs";
2
2
  import fsSync from "node:fs";
3
3
  import fs from "node:fs/promises";
4
4
  import path from "node:path";
@@ -6,6 +6,7 @@ import { BlobReader, BlobWriter, TextWriter, ZipReader, ZipWriter } from "@zip.j
6
6
  //#region src/reporter/otel-attributes.ts
7
7
  const ATTR_CODE_FILE_PATH = "code.file.path";
8
8
  const ATTR_CODE_LINE_NUMBER = "code.line.number";
9
+ const ATTR_CODE_COLUMN_NUMBER = "code.column.number";
9
10
  const ATTR_TEST_CASE_NAME = "test.case.name";
10
11
  const ATTR_TEST_CASE_TITLE = "test.case.title";
11
12
  const ATTR_TEST_CASE_RESULT_STATUS = "test.case.result.status";
@@ -228,9 +229,10 @@ var PlaywrightOpentelemetryReporter = class {
228
229
  attributes["playwright.test.status"] = result.status;
229
230
  attributes["playwright.test.describes"] = describes;
230
231
  if (test.location) {
231
- const { file, line } = test.location;
232
+ const { file, line, column } = test.location;
232
233
  attributes[ATTR_CODE_FILE_PATH] = this.rootDir ? path.relative(this.rootDir, file) : file;
233
234
  attributes[ATTR_CODE_LINE_NUMBER] = line;
235
+ attributes[ATTR_CODE_COLUMN_NUMBER] = column;
234
236
  }
235
237
  const stepSpans = [];
236
238
  for (const step of result.steps ?? []) this.processTestStep(step, testSpanId, traceId, [], stepSpans);
@@ -385,9 +387,10 @@ var PlaywrightOpentelemetryReporter = class {
385
387
  attributes[ATTR_TEST_STEP_CATEGORY] = step.category;
386
388
  if (phase) attributes[ATTR_TEST_PHASE] = phase;
387
389
  if (step.location) {
388
- const { file, line } = step.location;
390
+ const { file, line, column } = step.location;
389
391
  attributes[ATTR_CODE_FILE_PATH] = this.rootDir ? path.relative(this.rootDir, file) : file;
390
392
  attributes[ATTR_CODE_LINE_NUMBER] = line;
393
+ attributes[ATTR_CODE_COLUMN_NUMBER] = column;
391
394
  }
392
395
  const stepSpan = {
393
396
  traceId,
package/dist/reporter.cjs CHANGED
@@ -1,4 +1,4 @@
1
1
  //#region src/reporter/index.ts
2
- var reporter_default = require("./reporter-BuViICz8.cjs").PlaywrightOpentelemetryReporter;
2
+ var reporter_default = require("./reporter-D4i206BM.cjs").PlaywrightOpentelemetryReporter;
3
3
  //#endregion
4
4
  module.exports = reporter_default;
package/dist/reporter.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { t as PlaywrightOpentelemetryReporter } from "./reporter-_CyyuDJs.mjs";
1
+ import { t as PlaywrightOpentelemetryReporter } from "./reporter-DKhFsfiL.mjs";
2
2
  //#region src/reporter/index.ts
3
3
  var reporter_default = PlaywrightOpentelemetryReporter;
4
4
  //#endregion
@@ -2,7 +2,7 @@ import fs from "node:fs/promises";
2
2
  import path from "node:path";
3
3
  import { BlobReader, BlobWriter, TextWriter, ZipReader, ZipWriter } from "@zip.js/zip.js";
4
4
  //#region package.json
5
- var version = "0.18.1";
5
+ var version = "0.18.2";
6
6
  const PLAYWRIGHT_TRACE_API_SOURCE_HEADER = "x-playwright-otel-source";
7
7
  const PLAYWRIGHT_TRACE_API_SOURCE_REPORTER = "reporter";
8
8
  function withPlaywrightTraceApiHeaders(headers) {
@@ -26,7 +26,7 @@ let node_path = require("node:path");
26
26
  node_path = __toESM(node_path, 1);
27
27
  let _zip_js_zip_js = require("@zip.js/zip.js");
28
28
  //#region package.json
29
- var version = "0.18.1";
29
+ var version = "0.18.2";
30
30
  const PLAYWRIGHT_TRACE_API_SOURCE_HEADER = "x-playwright-otel-source";
31
31
  const PLAYWRIGHT_TRACE_API_SOURCE_REPORTER = "reporter";
32
32
  function withPlaywrightTraceApiHeaders(headers) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "playwright-opentelemetry",
3
- "version": "0.18.1",
3
+ "version": "0.18.2",
4
4
  "description": "A reporter for Playwright that can export traces and spans in opentelemetry format.",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",