windows-development-sandbox 1.27.3 → 1.28.0

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 (68) hide show
  1. package/dist/bin/agent-sandbox.js +2 -2
  2. package/dist/bin/{chunk-RU7XRN62.js → chunk-CB44HTTN.js} +196 -75
  3. package/dist/bin/{chunk-FA5VWLP4.js → chunk-UZ5S3EMB.js} +1 -1
  4. package/dist/bin/{chunk-4M5SZZ5P.js → chunk-ZMZI3625.js} +1 -1
  5. package/dist/bin/claude-host.js +2 -2
  6. package/dist/bin/claude-sbx.js +2 -2
  7. package/dist/bin/codex-sbx.js +2 -2
  8. package/dist/bin/gemini-sbx.js +2 -2
  9. package/dist/bin/sandbox.js +2 -2
  10. package/dist/bin/sbx-hide.js +2 -2
  11. package/dist/bin/sbx-show.js +2 -2
  12. package/dist/core/schema/sandbox.js +1 -1
  13. package/dist/guest/daemon/heartbeat.js +1 -0
  14. package/dist/guest/governor/core.d.ts +53 -1
  15. package/dist/guest/governor/core.js +95 -1
  16. package/dist/guest/governor/decide.d.ts +4 -0
  17. package/dist/guest/governor/decide.js +2 -0
  18. package/dist/guest/governor/governor.js +23 -9
  19. package/dist/guest/toolchains/native/unreal.js +22 -3
  20. package/dist/guest/toolchains/runtimes.js +7 -6
  21. package/dist/host/life/crash-report.d.ts +4 -0
  22. package/dist/host/life/crash-report.js +30 -1
  23. package/dist/host/life/last-end.js +1 -0
  24. package/dist/host/tools/windows-terminal.d.ts +4 -1
  25. package/dist/host/tools/windows-terminal.js +25 -9
  26. package/dist/runtime/agent.js +5 -1
  27. package/dist/runtime/daemon.js +183 -70
  28. package/dist/runtime/db.js +5 -1
  29. package/dist/runtime/main.js +242 -56
  30. package/dist/runtime/netproxy.js +5 -1
  31. package/dist/runtime/tool.js +5 -1
  32. package/dist/runtime/view.js +125 -27
  33. package/dist/selftest/agent-paths.test.js +3 -1
  34. package/dist/selftest/channel.test.js +33 -0
  35. package/dist/selftest/heavy-load.test.js +116 -4
  36. package/dist/selftest/live-terminal.test.js +103 -0
  37. package/dist/selftest/personalization.test.js +2 -1
  38. package/dist/selftest/support/engine-golden.js +2 -0
  39. package/dist/shared/channel/schema.d.ts +2 -0
  40. package/dist/shared/channel/schema.js +4 -0
  41. package/dist/shared/memory/index.d.ts +1 -0
  42. package/dist/shared/memory/index.js +1 -0
  43. package/dist/shared/memory/policy.d.ts +12 -0
  44. package/dist/shared/memory/policy.js +4 -0
  45. package/dist/shared/memory/unreal-build.d.ts +2 -0
  46. package/dist/shared/memory/unreal-build.js +21 -0
  47. package/dist/shared/pty/clipboard-watch.d.ts +4 -0
  48. package/dist/shared/pty/clipboard-watch.js +40 -0
  49. package/dist/shared/pty/ctrl-c.d.ts +13 -7
  50. package/dist/shared/pty/ctrl-c.js +35 -19
  51. package/dist/shared/pty/index.d.ts +1 -0
  52. package/dist/shared/pty/index.js +1 -0
  53. package/dist/shared/pty/terminal.d.ts +1 -1
  54. package/dist/shared/pty/terminal.js +16 -13
  55. package/dist/shared/web/ctrl-c.d.ts +26 -0
  56. package/dist/shared/web/ctrl-c.js +64 -0
  57. package/dist/shared/web/index.d.ts +1 -0
  58. package/dist/shared/web/index.js +1 -0
  59. package/dist/web/index.html +1 -1
  60. package/dist/web/{main-NKM7ECSB.js → main-7NY4X6YU.js} +67 -67
  61. package/native/csharp/HcsHost/AssemblyInfo.cs +3 -3
  62. package/native/csharp/HostTools/AssemblyInfo.cs +3 -3
  63. package/native/csharp/StorageHelper/AssemblyInfo.cs +3 -3
  64. package/package.json +1 -1
  65. package/sandbox/csharp/ClipboardWatch.cs +59 -0
  66. package/sandbox/csharp/MemGov.cs +752 -7
  67. package/sandbox/scripts/watch-clipboard.ps1 +8 -0
  68. package/schemas/config.schema.json +1 -1
@@ -8,9 +8,9 @@ using System.Runtime.InteropServices;
8
8
  [assembly: AssemblyCompany("windows-development-sandbox (open source)")]
9
9
  [assembly: AssemblyProduct("Windows Development Sandbox")]
10
10
  [assembly: AssemblyCopyright("MIT License, windows-development-sandbox contributors")]
11
- [assembly: AssemblyVersion("1.27.3.0")]
12
- [assembly: AssemblyFileVersion("1.27.3.0")]
13
- [assembly: AssemblyInformationalVersion("1.27.3")]
11
+ [assembly: AssemblyVersion("1.28.0.0")]
12
+ [assembly: AssemblyFileVersion("1.28.0.0")]
13
+ [assembly: AssemblyInformationalVersion("1.28.0")]
14
14
  [assembly: ComVisible(false)]
15
15
  // computecore.dll and computestorage.dll are not KnownDLLs: load them from System32 only, never from the exe's folder.
16
16
  [assembly: DefaultDllImportSearchPaths(DllImportSearchPath.System32)]
@@ -8,7 +8,7 @@ using System.Runtime.InteropServices;
8
8
  [assembly: AssemblyCompany("windows-development-sandbox (open source)")]
9
9
  [assembly: AssemblyProduct("Windows Development Sandbox")]
10
10
  [assembly: AssemblyCopyright("MIT License, windows-development-sandbox contributors")]
11
- [assembly: AssemblyVersion("1.27.3.0")]
12
- [assembly: AssemblyFileVersion("1.27.3.0")]
13
- [assembly: AssemblyInformationalVersion("1.27.3")]
11
+ [assembly: AssemblyVersion("1.28.0.0")]
12
+ [assembly: AssemblyFileVersion("1.28.0.0")]
13
+ [assembly: AssemblyInformationalVersion("1.28.0")]
14
14
  [assembly: ComVisible(false)]
@@ -9,7 +9,7 @@ using System.Runtime.InteropServices;
9
9
  [assembly: AssemblyCompany("windows-development-sandbox (open source)")]
10
10
  [assembly: AssemblyProduct("Windows Development Sandbox")]
11
11
  [assembly: AssemblyCopyright("MIT License, windows-development-sandbox contributors")]
12
- [assembly: AssemblyVersion("1.27.3.0")]
13
- [assembly: AssemblyFileVersion("1.27.3.0")]
14
- [assembly: AssemblyInformationalVersion("1.27.3")]
12
+ [assembly: AssemblyVersion("1.28.0.0")]
13
+ [assembly: AssemblyFileVersion("1.28.0.0")]
14
+ [assembly: AssemblyInformationalVersion("1.28.0")]
15
15
  [assembly: ComVisible(false)]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "windows-development-sandbox",
3
- "version": "1.27.3",
3
+ "version": "1.28.0",
4
4
  "description": "A disposable Windows Sandbox for development, with or without an AI agent (Claude Code, Codex, Gemini, opencode, ...): the folder you run it from is the workspace, toolchains and databases for your project install themselves, and nothing else on your PC is reachable.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -0,0 +1,59 @@
1
+ // Reports each change of the clipboard on stdout until a parent process ends. Loaded by scripts\watch-clipboard.ps1 (Add-Type). C# 5.
2
+ using System;
3
+ using System.Runtime.InteropServices;
4
+ using System.Threading;
5
+
6
+ public static class SbxClipboardWatch
7
+ {
8
+ private const uint Synchronize = 0x00100000;
9
+ private const uint WaitObject0 = 0;
10
+ private const int PollMs = 150;
11
+
12
+ private static class NativeMethods
13
+ {
14
+ [DllImport("kernel32.dll", SetLastError = true)]
15
+ public static extern IntPtr OpenProcess(uint access, bool inherit, uint pid);
16
+
17
+ [DllImport("kernel32.dll", SetLastError = true)]
18
+ public static extern uint WaitForSingleObject(IntPtr handle, uint milliseconds);
19
+
20
+ [DllImport("kernel32.dll", SetLastError = true)]
21
+ public static extern bool CloseHandle(IntPtr handle);
22
+
23
+ [DllImport("user32.dll", SetLastError = true)]
24
+ public static extern uint GetClipboardSequenceNumber();
25
+ }
26
+
27
+ /// <summary>
28
+ /// Writes the line "changed" for every clipboard change, until process parentPid ends. 0 = the parent ended,
29
+ /// 2 = the parent could not be opened.
30
+ /// </summary>
31
+ public static int Run(uint parentPid)
32
+ {
33
+ IntPtr parent = NativeMethods.OpenProcess(Synchronize, false, parentPid);
34
+ if (parent == IntPtr.Zero)
35
+ {
36
+ return 2;
37
+ }
38
+ try
39
+ {
40
+ uint last = NativeMethods.GetClipboardSequenceNumber();
41
+ while (NativeMethods.WaitForSingleObject(parent, 0) != WaitObject0)
42
+ {
43
+ uint now = NativeMethods.GetClipboardSequenceNumber();
44
+ if (now != last)
45
+ {
46
+ last = now;
47
+ Console.Out.WriteLine("changed");
48
+ Console.Out.Flush();
49
+ }
50
+ Thread.Sleep(PollMs);
51
+ }
52
+ return 0;
53
+ }
54
+ finally
55
+ {
56
+ NativeMethods.CloseHandle(parent);
57
+ }
58
+ }
59
+ }