holosphere 1.3.0-alpha7 → 1.3.0-alpha9

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "holosphere",
3
- "version": "1.3.0-alpha7",
3
+ "version": "1.3.0-alpha9",
4
4
  "description": "Holonic Geospatial Communication Infrastructure",
5
5
  "main": "holosphere.js",
6
6
  "module": "holosphere.js",
package/utils.js CHANGED
@@ -84,7 +84,23 @@ export function subscribe(holoInstance, holon, lens, callback) {
84
84
  try {
85
85
  let parsed = await holoInstance.parse(data);
86
86
  if (parsed && holoInstance.isHologram(parsed)) {
87
+ const hologramSoul = parsed.soul;
87
88
  const resolved = await holoInstance.resolveHologram(parsed, { followHolograms: true });
89
+ if (resolved === null) {
90
+ // Emit the SAME janitor-parseable warning that
91
+ // `get`/`getAll` emit on an unresolved hologram. The
92
+ // live subscribe path is the dashboard's primary read
93
+ // channel; without this line a genuinely-dangling
94
+ // pointer (source tombstoned/deleted) re-fires here on
95
+ // every map update and is never garbage-collected.
96
+ // `resolveHologram`'s own "Could not resolve hologram
97
+ // soul" log carries only the SOURCE soul, not the
98
+ // LOCAL pointer (holon/lens/key) a cleaner needs to
99
+ // delete it — so a console-hook janitor can't act on
100
+ // it. Note we still pass `null` to the callback below
101
+ // (consumers treat it as "item absent", unchanged).
102
+ console.warn(`Hologram at ${holon}/${lens}/${key} did not resolve (soul=${hologramSoul}); skipping.`);
103
+ }
88
104
  if (resolved !== parsed) {
89
105
  parsed = resolved;
90
106
  }