@lage-run/scheduler 1.5.0 → 1.5.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/CHANGELOG.json CHANGED
@@ -2,7 +2,37 @@
2
2
  "name": "@lage-run/scheduler",
3
3
  "entries": [
4
4
  {
5
- "date": "Thu, 23 Jan 2025 17:37:49 GMT",
5
+ "date": "Sat, 08 Mar 2025 02:33:56 GMT",
6
+ "version": "1.5.2",
7
+ "tag": "@lage-run/scheduler_v1.5.2",
8
+ "comments": {
9
+ "patch": [
10
+ {
11
+ "author": "beachball",
12
+ "package": "@lage-run/scheduler",
13
+ "comment": "Bump @lage-run/hasher to v1.7.0",
14
+ "commit": "not available"
15
+ }
16
+ ]
17
+ }
18
+ },
19
+ {
20
+ "date": "Tue, 04 Feb 2025 18:31:49 GMT",
21
+ "version": "1.5.1",
22
+ "tag": "@lage-run/scheduler_v1.5.1",
23
+ "comments": {
24
+ "patch": [
25
+ {
26
+ "author": "1581488+christiango@users.noreply.github.com",
27
+ "package": "@lage-run/scheduler",
28
+ "commit": "174afb345e9c221cdefa99726b7ef2a1c5456ef8",
29
+ "comment": "Fire the complete event at the correct time, fixes a bug where sometimes the start time of a task on the thread was before the end time of the previous task on that same thread"
30
+ }
31
+ ]
32
+ }
33
+ },
34
+ {
35
+ "date": "Thu, 23 Jan 2025 17:38:05 GMT",
6
36
  "version": "1.5.0",
7
37
  "tag": "@lage-run/scheduler_v1.5.0",
8
38
  "comments": {
package/CHANGELOG.md CHANGED
@@ -1,12 +1,28 @@
1
1
  # Change Log - @lage-run/scheduler
2
2
 
3
- <!-- This log was last generated on Thu, 23 Jan 2025 17:37:49 GMT and should not be manually modified. -->
3
+ <!-- This log was last generated on Sat, 08 Mar 2025 02:33:56 GMT and should not be manually modified. -->
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
+ ## 1.5.2
8
+
9
+ Sat, 08 Mar 2025 02:33:56 GMT
10
+
11
+ ### Patches
12
+
13
+ - Bump @lage-run/hasher to v1.7.0
14
+
15
+ ## 1.5.1
16
+
17
+ Tue, 04 Feb 2025 18:31:49 GMT
18
+
19
+ ### Patches
20
+
21
+ - Fire the complete event at the correct time, fixes a bug where sometimes the start time of a task on the thread was before the end time of the previous task on that same thread (1581488+christiango@users.noreply.github.com)
22
+
7
23
  ## 1.5.0
8
24
 
9
- Thu, 23 Jan 2025 17:37:49 GMT
25
+ Thu, 23 Jan 2025 17:38:05 GMT
10
26
 
11
27
  ### Minor changes
12
28
 
@@ -103,7 +103,6 @@ class WrappedTarget {
103
103
  }
104
104
  onAbort() {
105
105
  _class_private_field_set(this, _status, "aborted");
106
- this.duration = process.hrtime(this.startTime);
107
106
  this.options.logger.info("", {
108
107
  target: this.target,
109
108
  status: "aborted",
@@ -124,7 +123,6 @@ class WrappedTarget {
124
123
  }
125
124
  onComplete() {
126
125
  _class_private_field_set(this, _status, "success");
127
- this.duration = process.hrtime(this.startTime);
128
126
  this.options.logger.info("", {
129
127
  target: this.target,
130
128
  status: "success",
@@ -134,7 +132,6 @@ class WrappedTarget {
134
132
  }
135
133
  onFail() {
136
134
  _class_private_field_set(this, _status, "failed");
137
- this.duration = process.hrtime(this.startTime);
138
135
  this.options.logger.info("", {
139
136
  target: this.target,
140
137
  status: "failed",
@@ -146,9 +143,6 @@ class WrappedTarget {
146
143
  }
147
144
  }
148
145
  onSkipped(hash) {
149
- if (this.startTime[0] !== 0 && this.startTime[1] !== 0) {
150
- this.duration = process.hrtime(this.startTime);
151
- }
152
146
  _class_private_field_set(this, _status, "skipped");
153
147
  if (hash) {
154
148
  this.options.logger.info("", {
@@ -268,6 +262,7 @@ class WrappedTarget {
268
262
  };
269
263
  }, (worker)=>{
270
264
  worker.off("message", msgHandler);
265
+ this.duration = process.hrtime(this.startTime);
271
266
  releaseStdout();
272
267
  releaseStderr();
273
268
  }, abortSignal, target.priority);
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/WrappedTarget.ts"],"sourcesContent":["import { bufferTransform } from \"./bufferTransform.js\";\nimport { getLageOutputCacheLocation } from \"./getLageOutputCacheLocation.js\";\nimport { type LogEntry, LogLevel } from \"@lage-run/logger\";\n\nimport fs from \"fs\";\nimport path from \"path\";\nimport { mkdir, writeFile } from \"fs/promises\";\n\nimport type { Pool } from \"@lage-run/worker-threads-pool\";\nimport type { TargetRun, TargetStatus } from \"@lage-run/scheduler-types\";\nimport { getStartTargetId, type Target } from \"@lage-run/target-graph\";\nimport type { Logger } from \"@lage-run/logger\";\nimport type { TargetHasher } from \"@lage-run/hasher\";\nimport type { MessagePort } from \"worker_threads\";\n\nexport interface WrappedTargetOptions {\n root: string;\n target: Target;\n logger: Logger;\n shouldCache: boolean;\n continueOnError: boolean;\n abortController: AbortController;\n pool: Pool;\n hasher: TargetHasher;\n onMessage?: (message: any, postMessage: MessagePort[\"postMessage\"]) => void;\n}\n\nexport interface WorkerResult {\n stdoutBuffer: string;\n stderrBuffer: string;\n skipped: boolean;\n hash: string;\n value: unknown;\n id: string;\n}\n\n/**\n * Wraps a target with additional functionality:\n * 1. Caching\n * 2. Logging\n * 3. Abort signal\n * 4. Continue on error\n */\nexport class WrappedTarget implements TargetRun<WorkerResult> {\n #status: TargetStatus = \"pending\";\n #result: WorkerResult | undefined;\n queueTime: [number, number] = [0, 0];\n startTime: [number, number] = [0, 0];\n duration: [number, number] = [0, 0];\n target: Target;\n threadId = 0;\n\n get result() {\n return this.#result;\n }\n\n get status() {\n return this.#status;\n }\n\n get abortController() {\n return this.options.abortController;\n }\n\n set abortController(abortController: AbortController) {\n this.options.abortController = abortController;\n }\n\n get successful() {\n return this.#status === \"skipped\" || this.#status === \"success\";\n }\n\n get waiting() {\n return this.#status === \"pending\" || this.#status === \"queued\";\n }\n\n constructor(public options: WrappedTargetOptions) {\n this.target = options.target;\n\n if (this.target.id === getStartTargetId()) {\n this.#status = \"success\";\n }\n\n this.options.logger.info(\"\", { target: this.target, status: this.status });\n }\n\n onQueued() {\n this.#status = \"queued\";\n this.queueTime = process.hrtime();\n this.options.logger.info(\"\", { target: this.target, status: \"queued\" });\n }\n\n onAbort() {\n this.#status = \"aborted\";\n this.duration = process.hrtime(this.startTime);\n this.options.logger.info(\"\", { target: this.target, status: \"aborted\", threadId: this.threadId });\n }\n\n onStart(threadId: number) {\n if (this.status !== \"running\") {\n this.threadId = threadId;\n this.#status = \"running\";\n this.startTime = process.hrtime();\n this.options.logger.info(\"\", { target: this.target, status: \"running\", threadId });\n }\n }\n\n onComplete() {\n this.#status = \"success\";\n this.duration = process.hrtime(this.startTime);\n this.options.logger.info(\"\", {\n target: this.target,\n status: \"success\",\n duration: this.duration,\n threadId: this.threadId,\n });\n }\n\n onFail() {\n this.#status = \"failed\";\n this.duration = process.hrtime(this.startTime);\n this.options.logger.info(\"\", {\n target: this.target,\n status: \"failed\",\n duration: this.duration,\n threadId: this.threadId,\n });\n\n if (!this.options.continueOnError && this.options.abortController) {\n this.options.abortController.abort();\n }\n }\n\n onSkipped(hash?: string | undefined) {\n if (this.startTime[0] !== 0 && this.startTime[1] !== 0) {\n this.duration = process.hrtime(this.startTime);\n }\n\n this.#status = \"skipped\";\n\n if (hash) {\n this.options.logger.info(\"\", {\n target: this.target,\n status: \"skipped\",\n duration: this.duration,\n hash,\n threadId: this.threadId,\n });\n }\n }\n\n async run() {\n const { target, logger, shouldCache, abortController, root } = this.options;\n\n const abortSignal = abortController.signal;\n\n if (abortSignal.aborted) {\n this.onStart(0);\n this.onAbort();\n return;\n }\n\n try {\n this.#result = await this.runInPool();\n\n const cacheEnabled = target.cache && shouldCache && this.#result.hash;\n // Save output if cache is enabled & cache is hit\n if (!this.#result.skipped && cacheEnabled) {\n const outputLocation = getLageOutputCacheLocation(root, this.#result.hash);\n const outputPath = path.dirname(outputLocation);\n await mkdir(outputPath, { recursive: true });\n\n const output = `${this.#result.stdoutBuffer}\\n${this.#result.stderrBuffer}`;\n\n await writeFile(outputLocation, output);\n\n logger.verbose(`>> Saved cache - ${this.#result.hash}`, { target });\n }\n\n if (this.#result.skipped) {\n const { hash } = this.#result;\n\n const cachedOutputFile = getLageOutputCacheLocation(root, hash ?? \"\");\n\n const shouldShowCachedOutput = fs.existsSync(cachedOutputFile);\n if (shouldShowCachedOutput) {\n const cachedOutput = fs.readFileSync(cachedOutputFile, \"utf8\");\n logger.verbose(\">> Replaying cached output\", { target });\n logger.verbose(cachedOutput.trim(), { target });\n }\n\n this.onSkipped(hash);\n } else {\n this.onComplete();\n }\n\n return this.#result;\n } catch (e) {\n if (e instanceof Error) {\n logger.error(String(e), { target });\n }\n\n if (abortSignal.aborted) {\n this.onAbort();\n } else {\n this.onFail();\n }\n\n throw e;\n }\n }\n\n private async runInPool(): Promise<WorkerResult> {\n const { target, logger, abortController, pool } = this.options;\n const abortSignal = abortController.signal;\n\n let releaseStdout: any;\n let releaseStderr: any;\n\n const bufferStdout = bufferTransform();\n const bufferStderr = bufferTransform();\n\n let msgHandler: (data: LogEntry<any> & { type: string }) => void;\n\n const result = await (pool.exec(\n { target },\n target.weight ?? 1,\n (worker, stdout, stderr) => {\n const postMessage = worker.postMessage.bind(worker);\n\n msgHandler = (data) => {\n if (data.type === \"log\") {\n logger.log(data.level, data.msg, { target, threadId: worker.threadId });\n } else if (data.type === \"hash\") {\n this.options.hasher.hash(target).then((hash) => {\n worker.postMessage({ type: \"hash\", hash });\n });\n } else if (this.options.onMessage) {\n this.options.onMessage(data, postMessage);\n }\n };\n\n worker.on(\"message\", msgHandler);\n\n const threadId = worker.threadId;\n\n this.onStart(threadId);\n\n stdout.pipe(bufferStdout.transform);\n stderr.pipe(bufferStderr.transform);\n\n const releaseStdoutStream = logger.stream(LogLevel.verbose, stdout, { target, threadId });\n\n releaseStdout = () => {\n releaseStdoutStream();\n stdout.unpipe(bufferStdout.transform);\n };\n\n const releaseStderrStream = logger.stream(LogLevel.verbose, stderr, { target, threadId });\n\n releaseStderr = () => {\n releaseStderrStream();\n stderr.unpipe(bufferStderr.transform);\n };\n },\n (worker) => {\n worker.off(\"message\", msgHandler);\n releaseStdout();\n releaseStderr();\n },\n abortSignal,\n target.priority\n ) as Promise<{ value?: unknown; skipped: boolean; hash: string; id: string }>);\n\n return {\n stdoutBuffer: bufferStdout.buffer,\n stderrBuffer: bufferStderr.buffer,\n skipped: result?.skipped,\n hash: result?.hash,\n value: result?.value,\n id: result?.id,\n };\n }\n\n /**\n * A JSON representation of this wrapped target, suitable for serialization in tests.\n *\n * Skips the unpredictable properties of the wrapped target like the startTime and duration.\n *\n * @returns\n */\n toJSON() {\n return {\n target: this.target.id,\n status: this.status,\n };\n }\n\n /**\n * Reset the state of this wrapped target.\n */\n reset() {\n this.#result = undefined;\n this.#status = \"pending\";\n }\n}\n"],"names":["WrappedTarget","result","status","abortController","options","successful","waiting","onQueued","queueTime","process","hrtime","logger","info","target","onAbort","duration","startTime","threadId","onStart","onComplete","onFail","continueOnError","abort","onSkipped","hash","run","shouldCache","root","abortSignal","signal","aborted","runInPool","cacheEnabled","cache","skipped","outputLocation","getLageOutputCacheLocation","outputPath","path","dirname","mkdir","recursive","output","stdoutBuffer","stderrBuffer","writeFile","verbose","cachedOutputFile","shouldShowCachedOutput","fs","existsSync","cachedOutput","readFileSync","trim","e","Error","error","String","pool","releaseStdout","releaseStderr","bufferStdout","bufferTransform","bufferStderr","msgHandler","exec","weight","worker","stdout","stderr","postMessage","bind","data","type","log","level","msg","hasher","then","onMessage","on","pipe","transform","releaseStdoutStream","stream","LogLevel","unpipe","releaseStderrStream","off","priority","buffer","value","id","toJSON","reset","undefined","constructor","getStartTargetId"],"mappings":";;;;+BA2CaA;;;eAAAA;;;iCA3CmB;4CACW;wBACH;2DAEzB;6DACE;0BACgB;6BAIa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAkC5C,uCACA;AAFK,MAAMA;IASX,IAAIC,SAAS;QACX,gCAAO,IAAI,EAAC;IACd;IAEA,IAAIC,SAAS;QACX,gCAAO,IAAI,EAAC;IACd;IAE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AhCnB,SAAwB;aAExBI,YAA8B;YAAC;YAAG;SAAE;aACpCQ,YAA8B;YAAC;YAAG;SAAE;aACpCD,WAA6B;YAAC;YAAG;SAAE;aAEnCE,WAAW;QA2BT,IAAI,CAACJ,MAAM,GAAGT,QAAQS,MAAM;QAE5B,IAAI,IAAI,CAACA,MAAM,CAAC+E,EAAE,KAAKK,IAAAA,6BAAgB,KAAI;2CACpC,SAAU;QACjB;QAEA,IAAI,CAAC7F,OAAO,CAACO,MAAM,CAACC,IAAI,CAAC,IAAI;YAAEC,QAAQ,IAAI,CAACA,MAAM;YAAEX,QAAQ,IAAI,CAACA,MAAM;QAAC;IAC1E;AA6NF"}
1
+ {"version":3,"sources":["../src/WrappedTarget.ts"],"sourcesContent":["import { bufferTransform } from \"./bufferTransform.js\";\nimport { getLageOutputCacheLocation } from \"./getLageOutputCacheLocation.js\";\nimport { type LogEntry, LogLevel } from \"@lage-run/logger\";\n\nimport fs from \"fs\";\nimport path from \"path\";\nimport { mkdir, writeFile } from \"fs/promises\";\n\nimport type { Pool } from \"@lage-run/worker-threads-pool\";\nimport type { TargetRun, TargetStatus } from \"@lage-run/scheduler-types\";\nimport { getStartTargetId, type Target } from \"@lage-run/target-graph\";\nimport type { Logger } from \"@lage-run/logger\";\nimport type { TargetHasher } from \"@lage-run/hasher\";\nimport type { MessagePort } from \"worker_threads\";\n\nexport interface WrappedTargetOptions {\n root: string;\n target: Target;\n logger: Logger;\n shouldCache: boolean;\n continueOnError: boolean;\n abortController: AbortController;\n pool: Pool;\n hasher: TargetHasher;\n onMessage?: (message: any, postMessage: MessagePort[\"postMessage\"]) => void;\n}\n\nexport interface WorkerResult {\n stdoutBuffer: string;\n stderrBuffer: string;\n skipped: boolean;\n hash: string;\n value: unknown;\n id: string;\n}\n\n/**\n * Wraps a target with additional functionality:\n * 1. Caching\n * 2. Logging\n * 3. Abort signal\n * 4. Continue on error\n */\nexport class WrappedTarget implements TargetRun<WorkerResult> {\n #status: TargetStatus = \"pending\";\n #result: WorkerResult | undefined;\n queueTime: [number, number] = [0, 0];\n startTime: [number, number] = [0, 0];\n duration: [number, number] = [0, 0];\n target: Target;\n threadId = 0;\n\n get result() {\n return this.#result;\n }\n\n get status() {\n return this.#status;\n }\n\n get abortController() {\n return this.options.abortController;\n }\n\n set abortController(abortController: AbortController) {\n this.options.abortController = abortController;\n }\n\n get successful() {\n return this.#status === \"skipped\" || this.#status === \"success\";\n }\n\n get waiting() {\n return this.#status === \"pending\" || this.#status === \"queued\";\n }\n\n constructor(public options: WrappedTargetOptions) {\n this.target = options.target;\n\n if (this.target.id === getStartTargetId()) {\n this.#status = \"success\";\n }\n\n this.options.logger.info(\"\", { target: this.target, status: this.status });\n }\n\n onQueued() {\n this.#status = \"queued\";\n this.queueTime = process.hrtime();\n this.options.logger.info(\"\", { target: this.target, status: \"queued\" });\n }\n\n onAbort() {\n this.#status = \"aborted\";\n this.options.logger.info(\"\", { target: this.target, status: \"aborted\", threadId: this.threadId });\n }\n\n onStart(threadId: number) {\n if (this.status !== \"running\") {\n this.threadId = threadId;\n this.#status = \"running\";\n this.startTime = process.hrtime();\n this.options.logger.info(\"\", { target: this.target, status: \"running\", threadId });\n }\n }\n\n onComplete() {\n this.#status = \"success\";\n this.options.logger.info(\"\", {\n target: this.target,\n status: \"success\",\n duration: this.duration,\n threadId: this.threadId,\n });\n }\n\n onFail() {\n this.#status = \"failed\";\n this.options.logger.info(\"\", {\n target: this.target,\n status: \"failed\",\n duration: this.duration,\n threadId: this.threadId,\n });\n\n if (!this.options.continueOnError && this.options.abortController) {\n this.options.abortController.abort();\n }\n }\n\n onSkipped(hash?: string | undefined) {\n this.#status = \"skipped\";\n\n if (hash) {\n this.options.logger.info(\"\", {\n target: this.target,\n status: \"skipped\",\n duration: this.duration,\n hash,\n threadId: this.threadId,\n });\n }\n }\n\n async run() {\n const { target, logger, shouldCache, abortController, root } = this.options;\n\n const abortSignal = abortController.signal;\n\n if (abortSignal.aborted) {\n this.onStart(0);\n this.onAbort();\n return;\n }\n\n try {\n this.#result = await this.runInPool();\n\n const cacheEnabled = target.cache && shouldCache && this.#result.hash;\n // Save output if cache is enabled & cache is hit\n if (!this.#result.skipped && cacheEnabled) {\n const outputLocation = getLageOutputCacheLocation(root, this.#result.hash);\n const outputPath = path.dirname(outputLocation);\n await mkdir(outputPath, { recursive: true });\n\n const output = `${this.#result.stdoutBuffer}\\n${this.#result.stderrBuffer}`;\n\n await writeFile(outputLocation, output);\n\n logger.verbose(`>> Saved cache - ${this.#result.hash}`, { target });\n }\n\n if (this.#result.skipped) {\n const { hash } = this.#result;\n\n const cachedOutputFile = getLageOutputCacheLocation(root, hash ?? \"\");\n\n const shouldShowCachedOutput = fs.existsSync(cachedOutputFile);\n if (shouldShowCachedOutput) {\n const cachedOutput = fs.readFileSync(cachedOutputFile, \"utf8\");\n logger.verbose(\">> Replaying cached output\", { target });\n logger.verbose(cachedOutput.trim(), { target });\n }\n\n this.onSkipped(hash);\n } else {\n this.onComplete();\n }\n\n return this.#result;\n } catch (e) {\n if (e instanceof Error) {\n logger.error(String(e), { target });\n }\n\n if (abortSignal.aborted) {\n this.onAbort();\n } else {\n this.onFail();\n }\n\n throw e;\n }\n }\n\n private async runInPool(): Promise<WorkerResult> {\n const { target, logger, abortController, pool } = this.options;\n const abortSignal = abortController.signal;\n\n let releaseStdout: any;\n let releaseStderr: any;\n\n const bufferStdout = bufferTransform();\n const bufferStderr = bufferTransform();\n\n let msgHandler: (data: LogEntry<any> & { type: string }) => void;\n\n const result = await (pool.exec(\n { target },\n target.weight ?? 1,\n (worker, stdout, stderr) => {\n const postMessage = worker.postMessage.bind(worker);\n\n msgHandler = (data) => {\n if (data.type === \"log\") {\n logger.log(data.level, data.msg, { target, threadId: worker.threadId });\n } else if (data.type === \"hash\") {\n this.options.hasher.hash(target).then((hash) => {\n worker.postMessage({ type: \"hash\", hash });\n });\n } else if (this.options.onMessage) {\n this.options.onMessage(data, postMessage);\n }\n };\n\n worker.on(\"message\", msgHandler);\n\n const threadId = worker.threadId;\n\n this.onStart(threadId);\n\n stdout.pipe(bufferStdout.transform);\n stderr.pipe(bufferStderr.transform);\n\n const releaseStdoutStream = logger.stream(LogLevel.verbose, stdout, { target, threadId });\n\n releaseStdout = () => {\n releaseStdoutStream();\n stdout.unpipe(bufferStdout.transform);\n };\n\n const releaseStderrStream = logger.stream(LogLevel.verbose, stderr, { target, threadId });\n\n releaseStderr = () => {\n releaseStderrStream();\n stderr.unpipe(bufferStderr.transform);\n };\n },\n (worker) => {\n worker.off(\"message\", msgHandler);\n this.duration = process.hrtime(this.startTime);\n releaseStdout();\n releaseStderr();\n },\n abortSignal,\n target.priority\n ) as Promise<{ value?: unknown; skipped: boolean; hash: string; id: string }>);\n\n return {\n stdoutBuffer: bufferStdout.buffer,\n stderrBuffer: bufferStderr.buffer,\n skipped: result?.skipped,\n hash: result?.hash,\n value: result?.value,\n id: result?.id,\n };\n }\n\n /**\n * A JSON representation of this wrapped target, suitable for serialization in tests.\n *\n * Skips the unpredictable properties of the wrapped target like the startTime and duration.\n *\n * @returns\n */\n toJSON() {\n return {\n target: this.target.id,\n status: this.status,\n };\n }\n\n /**\n * Reset the state of this wrapped target.\n */\n reset() {\n this.#result = undefined;\n this.#status = \"pending\";\n }\n}\n"],"names":["WrappedTarget","result","status","abortController","options","successful","waiting","onQueued","queueTime","process","hrtime","logger","info","target","onAbort","threadId","onStart","startTime","onComplete","duration","onFail","continueOnError","abort","onSkipped","hash","run","shouldCache","root","abortSignal","signal","aborted","runInPool","cacheEnabled","cache","skipped","outputLocation","getLageOutputCacheLocation","outputPath","path","dirname","mkdir","recursive","output","stdoutBuffer","stderrBuffer","writeFile","verbose","cachedOutputFile","shouldShowCachedOutput","fs","existsSync","cachedOutput","readFileSync","trim","e","Error","error","String","pool","releaseStdout","releaseStderr","bufferStdout","bufferTransform","bufferStderr","msgHandler","exec","weight","worker","stdout","stderr","postMessage","bind","data","type","log","level","msg","hasher","then","onMessage","on","pipe","transform","releaseStdoutStream","stream","LogLevel","unpipe","releaseStderrStream","off","priority","buffer","value","id","toJSON","reset","undefined","constructor","getStartTargetId"],"mappings":";;;;+BA2CaA;;;eAAAA;;;iCA3CmB;4CACW;wBACH;2DAEzB;6DACE;0BACgB;6BAIa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAkC5C,uCACA;AAFK,MAAMA;IASX,IAAIC,SAAS;QACX,gCAAO,IAAI,EAAC;IACd;IAEA,IAAIC,SAAS;QACX,gCAAO,IAAI,EAAC;IACd;IAEA,IAAIC,kBAAkB;QACpB,OAAO,IAAI,CAACC,OAAO,CAACD,eAAe;IACrC;IAEA,IAAIA,gBAAgBA,eAAgC,EAAE;QACpD,IAAI,CAACC,OAAO,CAACD,eAAe,GAAGA;IACjC;IAEA,IAAIE,aAAa;QACf,OAAO,yBAAA,IAAI,EAAC,aAAY,aAAa,yBAAA,IAAI,EAAC,aAAY;IACxD;IAEA,IAAIC,UAAU;QACZ,OAAO,yBAAA,IAAI,EAAC,aAAY,aAAa,yBAAA,IAAI,EAAC,aAAY;IACxD;IAYAC,WAAW;uCACJ,SAAU;QACf,IAAI,CAACC,SAAS,GAAGC,QAAQC,MAAM;QAC/B,IAAI,CAACN,OAAO,CAACO,MAAM,CAACC,IAAI,CAAC,IAAI;YAAEC,QAAQ,IAAI,CAACA,MAAM;YAAEX,QAAQ;QAAS;IACvE;IAEAY,UAAU;uCACH,SAAU;QACf,IAAI,CAACV,OAAO,CAACO,MAAM,CAACC,IAAI,CAAC,IAAI;YAAEC,QAAQ,IAAI,CAACA,MAAM;YAAEX,QAAQ;YAAWa,UAAU,IAAI,CAACA,QAAQ;QAAC;IACjG;IAEAC,QAAQD,QAAgB,EAAE;QACxB,IAAI,IAAI,CAACb,MAAM,KAAK,WAAW;YAC7B,IAAI,CAACa,QAAQ,GAAGA;2CACX,SAAU;YACf,IAAI,CAACE,SAAS,GAAGR,QAAQC,MAAM;YAC/B,IAAI,CAAC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AAAA,YAAAA,KAAAA;aA0BmBX,UAAAA;uCAhCnB,SAAwB;aAExBI,YAA8B;YAAC;YAAG;SAAE;aACpCS,YAA8B;YAAC;YAAG;SAAE;aACpCE,WAA6B;YAAC;YAAG;SAAE;aAEnCJ,WAAW;QA2BT,IAAI,CAACF,MAAM,GAAGT,QAAQS,MAAM;QAE5B,IAAI,IAAI,CAACA,MAAM,CAAC+E,EAAE,KAAKK,IAAAA,6BAAgB,KAAI;2CACpC,SAAU;QACjB;QAEA,IAAI,CAAC7F,OAAO,CAACO,MAAM,CAACC,IAAI,CAAC,IAAI;YAAEC,QAAQ,IAAI,CAACA,MAAM;YAAEX,QAAQ,IAAI,CAACA,MAAM;QAAC;IAC1E;AAuNF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lage-run/scheduler",
3
- "version": "1.5.0",
3
+ "version": "1.5.2",
4
4
  "description": "Scheduler for Lage",
5
5
  "repository": {
6
6
  "type": "git",
@@ -19,7 +19,7 @@
19
19
  "dependencies": {
20
20
  "@lage-run/cache": "^1.3.11",
21
21
  "@lage-run/config": "^0.4.12",
22
- "@lage-run/hasher": "^1.6.9",
22
+ "@lage-run/hasher": "^1.7.0",
23
23
  "@lage-run/logger": "^1.3.1",
24
24
  "@lage-run/runners": "^1.2.1",
25
25
  "@lage-run/target-graph": "^0.11.1",