@andersbakken/fisk 4.0.23 → 4.0.24

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": "@andersbakken/fisk",
3
- "version": "4.0.23",
3
+ "version": "4.0.24",
4
4
  "description": "Fisk, a distributed compile system",
5
5
  "scripts": {
6
6
  "lint": "eslint . --ext .ts",
@@ -54243,6 +54243,7 @@ server.on("listen", (app) => {
54243
54243
  setTimeout(() => process.exit(), 100);
54244
54244
  });
54245
54245
  app.post("/builder-command", (req, res) => {
54246
+ console.log("Got builder command", req.body);
54246
54247
  if (!req.body || !req.body.builder || !req.body.command) {
54247
54248
  res.sendStatus(404);
54248
54249
  return;
@@ -54259,14 +54260,19 @@ server.on("listen", (app) => {
54259
54260
  }
54260
54261
  }
54261
54262
  if (!found) {
54263
+ console.log("Didn't find builder", req.body);
54262
54264
  res.sendStatus(404);
54263
54265
  return;
54264
54266
  }
54265
54267
  let timedOut = false;
54266
54268
  const id = ++nextCommandId;
54267
- found.send({ type: "command", command: req.body.command, id });
54269
+ const cmd = { type: "command", command: req.body.command, id };
54270
+ console.log("Sending command to builder", found.ip, found.name, cmd);
54271
+ found.send(cmd);
54268
54272
  const onCommand = (message) => {
54269
- if (timedOut || !found) {
54273
+ assert__default["default"](found);
54274
+ if (timedOut) {
54275
+ console.log("Timed out already");
54270
54276
  return;
54271
54277
  }
54272
54278
  console.log("Got message from builder", found.ip, found.name, "\n", message);