@ai-ecoverse/slicc-kernel 1.93.0 → 1.93.1

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.
@@ -4018,7 +4018,7 @@ var KERNEL_VERSION, OS_RELEASE;
4018
4018
  var init_version = __esm({
4019
4019
  "src/version.ts"() {
4020
4020
  "use strict";
4021
- KERNEL_VERSION = true ? "1.93.0" : "0.0.0-dev";
4021
+ KERNEL_VERSION = true ? "1.93.1" : "0.0.0-dev";
4022
4022
  OS_RELEASE = "6.0.0-slicc";
4023
4023
  }
4024
4024
  });
package/dist/node.js CHANGED
@@ -10500,7 +10500,7 @@ function mountTable(mounts = []) {
10500
10500
  }
10501
10501
 
10502
10502
  // src/version.ts
10503
- var KERNEL_VERSION = true ? "1.93.0" : "0.0.0-dev";
10503
+ var KERNEL_VERSION = true ? "1.93.1" : "0.0.0-dev";
10504
10504
  var OS_RELEASE = "6.0.0-slicc";
10505
10505
  function procVersion() {
10506
10506
  return `Linux version ${OS_RELEASE} (slicc-kernel ${KERNEL_VERSION}) #1 SMP PREEMPT_DYNAMIC
@@ -19047,6 +19047,9 @@ var Launcher = class {
19047
19047
  hostname;
19048
19048
  watchers = new FsWatchers();
19049
19049
  pnpmHome;
19050
+ pnpmChain;
19051
+ pnpmMade;
19052
+ pnpmEpoch = 0;
19050
19053
  mounts;
19051
19054
  createDriverWorker;
19052
19055
  media;
@@ -19097,7 +19100,10 @@ var Launcher = class {
19097
19100
  this.mounts = new MountTable({
19098
19101
  open: (type, spec) => this.driver(type, spec),
19099
19102
  busy: (target) => [...this.openFiles].some((nodes) => nodes.holds(target)) || heldUnder(this.held, target),
19100
- changed: this.watchers.changed.bind(this.watchers),
19103
+ changed: (...paths) => {
19104
+ if (paths.some((path) => this.pnpmChain.has(path))) this.pnpmStale();
19105
+ this.watchers.changed(...paths);
19106
+ },
19101
19107
  owners: this.owners
19102
19108
  });
19103
19109
  this.mounted = this.mounts.wrap(options.fs);
@@ -19110,6 +19116,7 @@ var Launcher = class {
19110
19116
  this.fstabRetries = options.fstabRetries ?? FSTAB_RETRIES;
19111
19117
  this.processMounts = options.processMounts ?? true;
19112
19118
  this.pnpmHome = options.env?.PNPM_HOME ?? SYSTEM_PNPM_HOME;
19119
+ this.pnpmChain = new Set(chain(normalizePath(this.pnpmHome)));
19113
19120
  this.modulesDir = options.modules ?? "/node_modules";
19114
19121
  this.appended = appendedRoots(options.commands);
19115
19122
  this.cdp = new CdpHosts(options.cdp);
@@ -19716,6 +19723,7 @@ var Launcher = class {
19716
19723
  delete env[TICKET_ENV];
19717
19724
  env.HOSTNAME = this.hostname;
19718
19725
  let program;
19726
+ await this.pnpmReady();
19719
19727
  try {
19720
19728
  const caller = { pid: req.ppid ?? 0, uid: req.cred.euid, tag: req.tag };
19721
19729
  if (this.integrity) await this.checkedSources(planned, caller);
@@ -20360,8 +20368,7 @@ var Launcher = class {
20360
20368
  this.fs
20361
20369
  );
20362
20370
  void this.unlinked.sweep(entry.target);
20363
- if (this.pnpmHome.startsWith(`${entry.target.replace(/\/$/, "")}/`))
20364
- await this.provisionPnpmHome();
20371
+ this.pnpmStale();
20365
20372
  return entry;
20366
20373
  }
20367
20374
  async ownTmp() {
@@ -20409,8 +20416,18 @@ var Launcher = class {
20409
20416
  if (path === "/") return path;
20410
20417
  return joinName(await realDir(this.base, parentOf(path)), baseName(path));
20411
20418
  }
20412
- async provisionPnpmHome() {
20413
- await this.base.mkdir(this.pnpmHome, { recursive: true }).catch(() => void 0);
20419
+ pnpmReady() {
20420
+ if (this.pnpmMade !== void 0) return this.pnpmMade;
20421
+ const epoch = this.pnpmEpoch;
20422
+ const made2 = this.base.mkdir(this.pnpmHome, { recursive: true }).then(() => this.owners ? this.stampLayout() : void 0).catch(() => {
20423
+ if (this.pnpmEpoch === epoch) this.pnpmMade = void 0;
20424
+ });
20425
+ this.pnpmMade = made2;
20426
+ return made2;
20427
+ }
20428
+ pnpmStale() {
20429
+ this.pnpmEpoch++;
20430
+ this.pnpmMade = void 0;
20414
20431
  }
20415
20432
  mountedBy(spec, cred) {
20416
20433
  if (!this.owners || cred.euid === 0 && cred.egid === 0) return spec;
@@ -20444,6 +20461,7 @@ var Launcher = class {
20444
20461
  umount(target, detach = false) {
20445
20462
  const at = normalizePath(target);
20446
20463
  this.mounts.umount(at, detach);
20464
+ this.pnpmStale();
20447
20465
  if (!detach) return;
20448
20466
  for (const nodes of this.openFiles) nodes.revoke(at);
20449
20467
  for (const holds of this.held) holds.revoke(at);
@@ -20509,7 +20527,7 @@ var Launcher = class {
20509
20527
  await this.resolvePrefixes();
20510
20528
  for (const dir of SHARED_DIRS) await this.base.mkdir(dir, { recursive: true });
20511
20529
  if (this.owners) await this.ownTmp();
20512
- await this.provisionPnpmHome();
20530
+ await this.pnpmReady();
20513
20531
  await this.users.ensure();
20514
20532
  if (this.owners) await this.stampLayout();
20515
20533
  if (this.owners) await this.sudoer.provision();