@jsenv/core 27.0.0-alpha.28 → 27.0.0-alpha.29

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jsenv/core",
3
- "version": "27.0.0-alpha.28",
3
+ "version": "27.0.0-alpha.29",
4
4
  "description": "Tool to develop, test and build js projects",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -91,7 +91,6 @@
91
91
  "@jsenv/assert": "2.5.4",
92
92
  "@jsenv/eslint-config": "16.0.9",
93
93
  "@jsenv/file-size-impact": "12.1.11",
94
- "@jsenv/github-release-package": "1.4.0",
95
94
  "@jsenv/https-local": "1.0.8",
96
95
  "@jsenv/importmap-node-module": "5.1.3",
97
96
  "@jsenv/package-workspace": "0.0.5",
@@ -22,6 +22,7 @@ import {
22
22
  fetchFileSystem,
23
23
  } from "@jsenv/server"
24
24
  import { createLogger } from "@jsenv/logger"
25
+ import { Abort } from "@jsenv/abort"
25
26
 
26
27
  import { initProcessAutorestart } from "@jsenv/utils/file_watcher/process_auto_restart.js"
27
28
  import { createTaskLog } from "@jsenv/utils/logs/task_log.js"
@@ -79,13 +80,17 @@ export const startBuildServer = async ({
79
80
  const logger = createLogger({ logLevel })
80
81
 
81
82
  let buildPromise
82
- let abortController
83
+ let buildAbortController
83
84
  const runBuild = async () => {
85
+ buildAbortController = new AbortController()
86
+ const buildOperation = Abort.startOperation()
87
+ buildOperation.addAbortSignal(signal)
88
+ buildOperation.addAbortSignal(buildAbortController.signal)
84
89
  const buildTask = createTaskLog(logger, `execute build command`)
85
90
  buildPromise = executeCommand(buildCommand, {
86
91
  cwd: rootDirectoryUrl,
87
92
  logLevel: buildCommandLogLevel,
88
- signal,
93
+ signal: buildOperation.signal,
89
94
  })
90
95
  try {
91
96
  await buildPromise
@@ -173,7 +178,7 @@ export const startBuildServer = async ({
173
178
  watchedFilePatterns,
174
179
  cooldownBetweenFileEvents,
175
180
  fileChangeCallback: ({ url, event }) => {
176
- abortController.abort()
181
+ buildAbortController.abort()
177
182
  // setTimeout is to ensure the abortController.abort() above
178
183
  // is properly taken into account so that logs about abort comes first
179
184
  // then logs about re-running the build happens
@@ -191,8 +191,8 @@ export const createRuntimeFromPlaywright = ({
191
191
  navigation: performance.navigation.toJSON(),
192
192
  measures,
193
193
  }
194
- /* eslint-enable no-undef */
195
194
  },
195
+ /* eslint-enable no-undef */
196
196
  )
197
197
  result.performance = performance
198
198
  return result