playwright-core 1.45.1 → 1.45.2-beta-1721667620000

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.
@@ -34,8 +34,8 @@ class Tracing extends _channelOwner.ChannelOwner {
34
34
  this._isTracing = false;
35
35
  }
36
36
  async start(options = {}) {
37
- await this._wrapApiCall(async () => {
38
- this._includeSources = !!options.sources;
37
+ this._includeSources = !!options.sources;
38
+ const traceName = await this._wrapApiCall(async () => {
39
39
  await this._channel.tracingStart({
40
40
  name: options.name,
41
41
  snapshots: options.snapshots,
@@ -46,16 +46,15 @@ class Tracing extends _channelOwner.ChannelOwner {
46
46
  name: options.name,
47
47
  title: options.title
48
48
  });
49
- await this._startCollectingStacks(response.traceName);
49
+ return response.traceName;
50
50
  }, true);
51
+ await this._startCollectingStacks(traceName);
51
52
  }
52
53
  async startChunk(options = {}) {
53
- await this._wrapApiCall(async () => {
54
- const {
55
- traceName
56
- } = await this._channel.tracingStartChunk(options);
57
- await this._startCollectingStacks(traceName);
58
- }, true);
54
+ const {
55
+ traceName
56
+ } = await this._channel.tracingStartChunk(options);
57
+ await this._startCollectingStacks(traceName);
59
58
  }
60
59
  async _startCollectingStacks(traceName) {
61
60
  if (!this._isTracing) {
@@ -275,12 +275,8 @@ class Chromium extends _browserType.BrowserType {
275
275
  if (_os.default.platform() === 'darwin') {
276
276
  // See https://github.com/microsoft/playwright/issues/7362
277
277
  chromeArguments.push('--enable-use-zoom-for-dsf=false');
278
- }
279
- if (options.headless) {
280
278
  // See https://bugs.chromium.org/p/chromium/issues/detail?id=1407025.
281
- // See also https://github.com/microsoft/playwright/issues/30585
282
- // and chromium fix at https://issues.chromium.org/issues/338414704.
283
- chromeArguments.push('--enable-gpu');
279
+ if (options.headless) chromeArguments.push('--use-angle');
284
280
  }
285
281
  if (options.devtools) chromeArguments.push('--auto-open-devtools-for-tabs');
286
282
  if (options.headless) {