@twinsearth/w2m-dsh-plugin 0.4.6 → 0.4.7

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/CHANGELOG.md CHANGED
@@ -4,6 +4,27 @@ All notable changes to this project are documented here. The format follows
4
4
  [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project
5
5
  adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [0.4.7] — 2026-10-09
8
+
9
+ ### Fixed
10
+
11
+ * **The package root exported nothing, and the ecosystem checks the root.** `lib/index.js` was
12
+ deliberately documentation-only — the profile mounts `@twinsearth/w2m-dsh-plugin/tools` because
13
+ `cordis.patch.yml` names that subpath — so `import('@twinsearth/w2m-dsh-plugin')` returned
14
+ `Object.keys() === []` and `typeof apply === 'undefined'`. A plugin that mounts perfectly and
15
+ looks like an empty package to every tool that inspects it is a listing risk with no upside: the
16
+ DSH plugin listing requirements ask for a package that "exports an `apply(ctx)` module", and a
17
+ missing root export is one of the most common reasons a submission is refused. The root now
18
+ re-exports `apply`, `inject` and the test helper from `./tools.js` — one implementation, two
19
+ entry points — and `test/tools.test.mjs` asserts it, so it cannot silently regress.
20
+
21
+ ### Notes
22
+
23
+ * Nothing about the mounted plugin changed: the patch still names the subpath rather than relying on
24
+ the "root is the plugin" convention, which is what keeps the eight tools from being registered
25
+ twice.
26
+ * `tools.test.mjs`: 83 pass, 0 fail.
27
+
7
28
  ## [0.4.6] — 2026-10-09
8
29
 
9
30
  ### Added
package/lib/index.js CHANGED
@@ -1,13 +1,24 @@
1
1
  /**
2
- * Intentionally empty plugin entry point.
2
+ * Package root entry.
3
3
  *
4
- * The profile mounts this package's `tools` subpath -- named explicitly by
5
- * `cordis.patch.yml`'s insert entry -- so that reading the profile tells you
6
- * which module of the package becomes the plugin, instead of relying on a
7
- * "root export is the plugin" convention.
4
+ * TWO READERS, ONE EXPORT LIST
8
5
  *
9
- * This file exists only so the manifest never points at a path that does not
10
- * resolve. All real behaviour lives in `../src/plugin/tools.mjs`, re-exported
11
- * through `./tools.js`.
6
+ * `cordis.patch.yml` names the `tools` subpath explicitly, and that stays true: mounting this
7
+ * profile reads the patch, sees `@twinsearth/w2m-dsh-plugin/tools`, and loads `./tools.js`. Nothing
8
+ * about the mounted plugin changes because of this file.
9
+ *
10
+ * But the root entry is what everything else looks at. The DSH plugin listing requirements -- and
11
+ * the marketplace checklists that copy them -- ask for a package that "exports an `apply(ctx)`
12
+ * module", and a package that does not is one of the most common reasons a submission is refused.
13
+ * This file used to be documentation only, so importing the package root yielded **no exports at
14
+ * all** (`Object.keys() === []`): a plugin that works perfectly when mounted by its patch and looks
15
+ * like an empty package to every tool that inspects it. That is a bad trade for one re-export line.
16
+ *
17
+ * WHY NOT MOVE THE PLUGIN HERE
18
+ *
19
+ * Re-exporting is not relocating: `./tools.js` stays the single definition, so there is still
20
+ * exactly one implementation of the plugin surface to keep in sync. Mounting *both* this entry and
21
+ * the subpath would register the eight tools twice, which is why the patch keeps naming the subpath
22
+ * instead of falling back to the "the root is the plugin" convention.
12
23
  */
13
- export {};
24
+ export { apply, inject, resetDefineToolCacheForTests } from './tools.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twinsearth/w2m-dsh-plugin",
3
- "version": "0.4.6",
3
+ "version": "0.4.7",
4
4
  "description": "DSH: Windows2MacOS — drive the same project on online Windows and macOS machines from one DeepSeek account, across networks and regions. P2P hole punching is the default path (relay + shared server as rendezvous, ledger and fallback), with a bundled STUN responder, Tailscale/public-VPS/tunnel shapes, Rabbit relay + per-machine Localside + eight DSH tools (replicate / split), nine aggregate verdicts and signed requests.",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",
@@ -110,7 +110,7 @@ const MAX_STAGES = 16;
110
110
  * `package.json` during `scripts/pack.mjs` rather than hand-maintained, and `W2M_PLUGIN_VERSION`
111
111
  * overrides it at runtime for tests and packagers.
112
112
  */
113
- const PLUGIN_VERSION = '0.4.6';
113
+ const PLUGIN_VERSION = '0.4.7';
114
114
 
115
115
  /** How long any single HTTP call may take before it is aborted, in milliseconds. */
116
116
  const DEFAULT_REQUEST_TIMEOUT_MS = 15_000;