@warpmetrics/warp 0.0.13 → 0.0.15

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": "@warpmetrics/warp",
3
- "version": "0.0.13",
3
+ "version": "0.0.15",
4
4
  "description": "Measure your agents, not your LLM calls.",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
package/src/trace/call.js CHANGED
@@ -19,10 +19,6 @@ export function call(target, response, opts) {
19
19
  }
20
20
 
21
21
  const parentData = runRegistry.get(targetId) || groupRegistry.get(targetId);
22
- if (!parentData) {
23
- if (getConfig().debug) console.warn(`[warpmetrics] call() — target not in registry: ${targetId}`);
24
- return;
25
- }
26
22
 
27
23
  // Auto-extract _warpResponse if present (error case)
28
24
  const actualResponse = response?._warpResponse || response;
@@ -38,7 +34,7 @@ export function call(target, response, opts) {
38
34
 
39
35
  logCall(data);
40
36
  logLink({ parentId: targetId, childId: id, type: 'call' });
41
- parentData.calls.push(id);
37
+ if (parentData) parentData.calls.push(id);
42
38
 
43
39
  responseRegistry.delete(actualResponse);
44
40
  }
@@ -21,10 +21,6 @@ export function group(target, label, opts) {
21
21
  }
22
22
 
23
23
  const parentData = runRegistry.get(targetId) || groupRegistry.get(targetId);
24
- if (!parentData) {
25
- if (getConfig().debug) console.warn(`[warpmetrics] group() — target not in registry: ${targetId}`);
26
- return Object.freeze({ id: generateId('grp'), _type: 'group' });
27
- }
28
24
 
29
25
  const id = generateId('grp');
30
26
 
@@ -38,7 +34,7 @@ export function group(target, label, opts) {
38
34
  };
39
35
 
40
36
  groupRegistry.set(id, data);
41
- parentData.groups.push(id);
37
+ if (parentData) parentData.groups.push(id);
42
38
 
43
39
  logGroup(data);
44
40
  logLink({ parentId: targetId, childId: id, type: 'group' });