loop-task 2.1.7 → 2.1.8

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.
@@ -50,6 +50,8 @@ export class LoopController extends EventEmitter {
50
50
  return this._status;
51
51
  }
52
52
  start() {
53
+ if (this._status === "running")
54
+ return;
53
55
  this.skippedCount = 0;
54
56
  this.logStream?.end();
55
57
  this.abortController = new AbortController();
@@ -111,7 +113,6 @@ export class LoopController extends EventEmitter {
111
113
  this.sessionStartedAt = new Date().toISOString();
112
114
  this._resetSchedule = true;
113
115
  this._paused = false;
114
- this._status = "waiting";
115
116
  const phase = this.options.offset !== null
116
117
  ? this.options.offset
117
118
  : computePhase(this.id, this.options.interval);
@@ -122,6 +123,7 @@ export class LoopController extends EventEmitter {
122
123
  this.resumeResolve = null;
123
124
  }
124
125
  this.start();
126
+ this._status = "waiting";
125
127
  this.emit("resumed");
126
128
  return true;
127
129
  }
@@ -136,8 +138,8 @@ export class LoopController extends EventEmitter {
136
138
  if (needsStart) {
137
139
  this._stopAfterRun = true;
138
140
  this._paused = false;
139
- this._status = "running";
140
141
  this.start();
142
+ this._status = "running";
141
143
  }
142
144
  else {
143
145
  if (this._paused)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "loop-task",
3
- "version": "2.1.7",
3
+ "version": "2.1.8",
4
4
  "description": "Loop engineering toolkit. Run any command on a cadence, in the background, managed from a terminal board. Schedule tests, builds, syncs, or agent prompts.",
5
5
  "type": "module",
6
6
  "bin": {