@procedures/peer 0.3.0 → 0.5.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 (50) hide show
  1. package/CHANGELOG.md +50 -0
  2. package/dist/.tsbuildinfo +1 -1
  3. package/dist/connection/index.d.ts.map +1 -1
  4. package/dist/connection/index.js +4 -1
  5. package/dist/connection/index.js.map +1 -1
  6. package/dist/input-schemas.d.ts +5 -7
  7. package/dist/input-schemas.d.ts.map +1 -1
  8. package/dist/input-schemas.js +4 -15
  9. package/dist/input-schemas.js.map +1 -1
  10. package/dist/lockfile.d.ts +5 -2
  11. package/dist/lockfile.d.ts.map +1 -1
  12. package/dist/lockfile.js +5 -2
  13. package/dist/lockfile.js.map +1 -1
  14. package/dist/module.d.ts +2 -1
  15. package/dist/module.d.ts.map +1 -1
  16. package/dist/module.js +2 -7
  17. package/dist/module.js.map +1 -1
  18. package/dist/output-schemas.d.ts +1 -4
  19. package/dist/output-schemas.d.ts.map +1 -1
  20. package/dist/output-schemas.js +0 -23
  21. package/dist/output-schemas.js.map +1 -1
  22. package/dist/procedures/index.d.ts +0 -6
  23. package/dist/procedures/index.d.ts.map +1 -1
  24. package/dist/procedures/index.js +1 -3
  25. package/dist/procedures/index.js.map +1 -1
  26. package/dist/types.d.ts +0 -58
  27. package/dist/types.d.ts.map +1 -1
  28. package/package.json +3 -3
  29. package/src/connection/index.ts +3 -1
  30. package/src/input-schemas.ts +4 -27
  31. package/src/lockfile.ts +7 -3
  32. package/src/module.ts +2 -7
  33. package/src/output-schemas.ts +0 -29
  34. package/src/procedures/index.ts +1 -8
  35. package/src/types.ts +0 -76
  36. package/dist/procedures/server.start.d.ts +0 -14
  37. package/dist/procedures/server.start.d.ts.map +0 -1
  38. package/dist/procedures/server.start.js +0 -182
  39. package/dist/procedures/server.start.js.map +0 -1
  40. package/dist/procedures/server.status.d.ts +0 -13
  41. package/dist/procedures/server.status.d.ts.map +0 -1
  42. package/dist/procedures/server.status.js +0 -118
  43. package/dist/procedures/server.status.js.map +0 -1
  44. package/dist/procedures/server.stop.d.ts +0 -12
  45. package/dist/procedures/server.stop.d.ts.map +0 -1
  46. package/dist/procedures/server.stop.js +0 -98
  47. package/dist/procedures/server.stop.js.map +0 -1
  48. package/src/procedures/server.start.ts +0 -212
  49. package/src/procedures/server.status.ts +0 -141
  50. package/src/procedures/server.stop.ts +0 -123
package/CHANGELOG.md CHANGED
@@ -1,5 +1,55 @@
1
1
  # @procedures/peer
2
2
 
3
+ ## 0.5.0
4
+
5
+ ### Minor Changes
6
+
7
+ - a47bee6: The hosts can confine the file procedures to a root (roadmap R33).
8
+
9
+ - `confineFsProcedures(registry, root)` of `@procedures/fs` replaces the handler of each `fs.*` procedure of a registry with the handler of `createFsModule({ root })`. It adds no procedure. A nested `fs.*` call of another procedure is confined too. The root must be a folder that exists.
10
+ - `mark --fs-root <folder>` confines the `fs.*` procedures of each mode and host of `mark`: a command, the REPL, `--server`, `serve` and `mcp`. Give the flag before the command.
11
+ - A `mark` command uses a CLI server only when the server has the same root. The lockfile of `@procedures/peer` has the new field `fsRoot`, and `findServer()` compares it.
12
+ - `procedure-server --fs-root <folder>` and `mark serve --fs-root <folder>` confine the procedures of the server.
13
+ - The MCP server reads `MCP_FS_ROOT`, and `mark mcp` has the flag `--fs-root`. `fs` is not a tool namespace, so the tools do not change.
14
+ - A path outside the root gives `FORBIDDEN` with the reason `outside-root`. A procedure that reads files with `node:fs`, or that starts a program, is not confined.
15
+ - `@procedures/lib/cli-flags` has the global flags `--fs-root` and `--events`, and the field `repeatable`.
16
+
17
+ ### Patch Changes
18
+
19
+ - Updated dependencies [0f75644]
20
+ - Updated dependencies [09e5566]
21
+ - Updated dependencies [ab77f75]
22
+ - Updated dependencies [a47bee6]
23
+ - Updated dependencies [bc74091]
24
+ - @procedures/client@0.5.0
25
+
26
+ ## 0.4.0
27
+
28
+ ### Minor Changes
29
+
30
+ - d42d716: `server.start`, `server.stop` and `server.status` moved from `@procedures/peer` to `@procedures/server`, the package of the host. Their names, schemas and effects stay the same. They manage the background server of the `mark` CLI.
31
+
32
+ In this version, `@procedures/server` has a `./module` entry, a `./register` entry and the `client.procedures` field, so `mark server start`, `mark server stop` and `mark server status` keep working. The registry of `procedure-server` and `mark serve` has the module of the peer package and the module of the server package, as before.
33
+
34
+ The module of `@procedures/peer` does not register the three procedures any more, and `@procedures/peer/procedures` does not export them. The lockfiles stay in `@procedures/peer/lockfile`.
35
+
36
+ `connect()` of `@procedures/peer` takes `WebSocketTransport` from `@procedures/client/node`, not from the root of `@procedures/client`. Thus a peer connection in Node uses the `WebSocket` class of `ws`, and a drop ends the socket at once with `terminate()`.
37
+
38
+ ### Patch Changes
39
+
40
+ - Updated dependencies [d919678]
41
+ - Updated dependencies [057d69a]
42
+ - Updated dependencies [b2a1a1e]
43
+ - Updated dependencies [057d69a]
44
+ - Updated dependencies [057d69a]
45
+ - Updated dependencies [057d69a]
46
+ - Updated dependencies [057d69a]
47
+ - Updated dependencies [057d69a]
48
+ - Updated dependencies [afd6a19]
49
+ - Updated dependencies [057d69a]
50
+ - Updated dependencies [4e751da]
51
+ - @procedures/client@0.4.0
52
+
3
53
  ## 0.3.0
4
54
 
5
55
  ### Minor Changes