deadbyte-mcp 0.15.51 → 0.15.53

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.
Files changed (48) hide show
  1. package/MANIFEST.SHA256 +47 -18
  2. package/PROVENANCE.json +27 -9
  3. package/README.txt +18 -18
  4. package/RELEASE.json +33 -6
  5. package/SBOM.cdx.json +2 -2
  6. package/TEST-MATRIX.json +32 -2
  7. package/bridge/src/remote-call-claims-r60.mjs +5 -0
  8. package/controller/deadbyte-process-policy.json +4 -4
  9. package/docs/R135-AUTONOMOUS-SCOPE.md +21 -0
  10. package/docs/R136-SCOPED-OBSERVER.md +21 -0
  11. package/docs/R137-DESKTOP-COMMANDER-FOUNDATION.md +31 -0
  12. package/docs/R138-COMMANDER-WORKFLOW.md +21 -0
  13. package/docs/R139-COMMANDER-ERGONOMICS.md +17 -0
  14. package/docs/THIRD-PARTY-DESKTOP-COMMANDER-MIT.md +27 -0
  15. package/package.json +1 -1
  16. package/src/autonomous-scope-r135.mjs +91 -0
  17. package/src/commander-config-recovery-r137.mjs +67 -0
  18. package/src/commander-extended-runtime.mjs +22 -5
  19. package/src/commander-external-process-r48.mjs +25 -3
  20. package/src/commander-large-text-r139.mjs +66 -0
  21. package/src/commander-wire-adapter-r47.mjs +63 -12
  22. package/src/deadbyte-cli.mjs +5 -1
  23. package/src/scoped-observer-launcher-r136.mjs +77 -0
  24. package/src/scoped-observer-worker-r136.mjs +65 -0
  25. package/src/version.mjs +1 -1
  26. package/test/commander-wire-contract-r47.test.mjs +8 -5
  27. package/test/r130-release-security-contract.test.mjs +8 -8
  28. package/test/r132-release-identity.test.mjs +9 -9
  29. package/test/r135-autonomous-scope.test.mjs +103 -0
  30. package/test/r136-scoped-command-rights.test.mjs +39 -0
  31. package/test/r136-scoped-observer.test.mjs +89 -0
  32. package/test/r137-commander-config-recovery.test.mjs +111 -0
  33. package/test/r137-commander-three-version-contract.test.mjs +56 -0
  34. package/test/r138-commander-process-pagination.test.mjs +42 -0
  35. package/test/r138-commander-session-list.test.mjs +24 -0
  36. package/test/r138-commander-stream-resume.test.mjs +50 -0
  37. package/test/r139-large-text-edit.test.mjs +51 -0
  38. package/test/r139-large-text-read.test.mjs +46 -0
  39. package/test/r139-process-start-preview.test.mjs +50 -0
  40. package/test/r139-search-partial.test.mjs +42 -0
  41. package/test/r140-large-text-integrity.test.mjs +68 -0
  42. package/test/r141-commander-tail-utf8.test.mjs +55 -0
  43. package/test/r141-real-windows-disk.test.mjs +71 -0
  44. package/test/r142-native-machinefs-authority.test.mjs +127 -0
  45. package/test/r144-claim-terminal-history.test.mjs +55 -0
  46. package/test/r144-controller-broad-roots-cleanup.test.mjs +54 -0
  47. package/test/r59-tool-surface-compat.test.mjs +1 -1
  48. package/test/r74-prepublish-contract.test.mjs +3 -3
@@ -0,0 +1,54 @@
1
+ import test from 'node:test';
2
+ import assert from 'node:assert/strict';
3
+ import {readFile,writeFile,mkdtemp,mkdir,rm,access} from 'node:fs/promises';
4
+ import {spawnSync} from 'node:child_process';
5
+ import {createHash} from 'node:crypto';
6
+ import os from 'node:os';
7
+ import path from 'node:path';
8
+
9
+ const q=x=>"'"+String(x).replaceAll("'","''")+"'";
10
+ const section=(src,start,end)=>{
11
+ const a=src.indexOf('function '+start+'('),b=src.indexOf('function '+end+'(',a);
12
+ assert.ok(a>=0&&b>a,start+' boundaries missing');
13
+ return src.slice(a,b);
14
+ };
15
+
16
+ test('R144 broad Coding roots with no leases permit isolated cleanup without changing grants',async()=>{
17
+ const home='C:/Users/DEADBYTE/.deadbyte-mcp';
18
+ const cfgRoot=path.join(home,'generations','v0.15.45-34aa8d1241cfb8bf-ga9de1c56d5e65fa4');
19
+ const tmp=await mkdtemp(path.join(os.tmpdir(),'r144-broad-policy-cleanup-'));
20
+ try{
21
+ const runtime=path.join(tmp,'runtime');await mkdir(runtime);
22
+ const coding=JSON.parse(await readFile(path.join(cfgRoot,'coding-policy.json'),'utf8'));
23
+ const autonomous=JSON.parse(await readFile(path.join(cfgRoot,'autonomous-policy.json'),'utf8'));
24
+ assert.equal(coding.roots.local_c.path,'C:\\');
25
+ assert.equal(coding.roots.local_d.path,'D:\\');
26
+ coding.lease_file=path.join(runtime,'coding-grant.json');
27
+ const codingFile=path.join(tmp,'coding.json');
28
+ await writeFile(codingFile,JSON.stringify(coding));
29
+ autonomous.lease_file=path.join(runtime,'autonomous-grant.json');
30
+ autonomous.coding_policy_sha256=createHash('sha256').update(await readFile(codingFile)).digest('hex');
31
+ const autonomousFile=path.join(tmp,'autonomous.json');
32
+ await writeFile(autonomousFile,JSON.stringify(autonomous));
33
+ const src=await readFile(new URL('../controller/deadbyte-controller.ps1',import.meta.url),'utf8');
34
+ const code=[
35
+ "$ErrorActionPreference='Stop';",'$RuntimeDir='+q(runtime)+';',
36
+ 'function Fail([string]$m){throw $m}',
37
+ 'function Invoke-AuthorityEpochCommand{throw "UNEXPECTED_EPOCH_MUTATION"}',
38
+ section(src,'Assert-PolicyRootsAvailable','Get-AuthorityEpochStatus'),
39
+ section(src,'Read-ControllerPolicySnapshot','Get-CodingPolicyMetadata'),
40
+ section(src,'Get-CodingPolicyMetadata','Get-CodingLeaseStatus'),
41
+ section(src,'Disarm-Coding','Show-CodingStatus'),
42
+ section(src,'Get-AutonomousRevocationLeaseFile','Show-AutonomousStatus'),
43
+ '$cfg=@{CodingPolicyFile='+q(codingFile)+';AutonomousPolicyFile='+q(autonomousFile)+'};',
44
+ 'Disarm-Coding $cfg; Disarm-Autonomous $cfg; Write-Output "R144_NO_GRANT_REVOKE_OK"'
45
+ ].join('\n');
46
+ const run=spawnSync('powershell.exe',['-NoLogo','-NoProfile','-NonInteractive','-Command',code],{
47
+ encoding:'utf8',timeout:30000,maxBuffer:1024*1024
48
+ });
49
+ assert.equal(run.status,0,run.stderr+'\n'+run.stdout);
50
+ assert.match(run.stdout,/R144_NO_GRANT_REVOKE_OK/);
51
+ for(const f of ['coding-grant.json','autonomous-grant.json'])
52
+ await assert.rejects(access(path.join(runtime,f)),{code:'ENOENT'});
53
+ }finally{await rm(tmp,{recursive:true,force:true});}
54
+ });
@@ -83,7 +83,7 @@ test('R72 compact baseline permits only R64 read offset and authorized coding-on
83
83
  assert.deepEqual(diff.added,[]);
84
84
  assert.deepEqual(diff.removed,[]);
85
85
  const packageVersion=JSON.parse(await readFile(path.join(repoRoot,'package.json'),'utf8')).version;
86
- if(['0.15.41','0.15.42','0.15.43','0.15.44','0.15.45','0.15.46','0.15.47','0.15.48','0.15.49','0.15.50','0.15.51'].includes(packageVersion)){
86
+ if(['0.15.41','0.15.42','0.15.43','0.15.44','0.15.45','0.15.46','0.15.47','0.15.48','0.15.49','0.15.50','0.15.51','0.15.52','0.15.53'].includes(packageVersion)){
87
87
  assert.deepEqual([...diff.schema_changed].sort(),['machine_fs','native_diff_preview']);
88
88
  assert.equal(diff.unchanged.length,41);
89
89
  const prior=baseline.tools.find(tool=>tool.name==='machine_fs');
@@ -20,9 +20,9 @@ test('R74 prepublish contract: positive path succeeds and verifies identities',
20
20
  assert.equal(result.checks.package_leak_check.ok, true);
21
21
  assert.equal(result.checks.no_self_referential_tarball_hash, true);
22
22
  assert.equal(result.identities.package_name, 'deadbyte-mcp');
23
- // This R74 component contract remains scoped to train R74, even when
24
- // the containing npm package is the R132 0.15.51 candidate.
25
- assert.equal(result.identities.package_version, '0.15.51');
23
+ // R74 component contract retains its train-specific source and predecessor assertions;
24
+ // the containing R144 package must report its actual immutable package version.
25
+ assert.equal(result.identities.package_version, '0.15.53');
26
26
  assert.equal(result.identities.target_train, 'R74');
27
27
  assert.equal(result.identities.published_source_predecessor, '0.15.46');
28
28
  assert.notEqual(result.identities.published_source_predecessor, result.identities.runtime_predecessor);