@prjct.app/pi-activity 0.2.1 → 0.2.2

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 (3) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/index.ts +10 -1
  3. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## [0.2.2](https://github.com/prjct-app/pi-activity/compare/v0.2.1...v0.2.2) (2026-09-22)
2
+
3
+ ### Bug Fixes
4
+
5
+ * pass the extension context through to the wrapped tool ([0061066](https://github.com/prjct-app/pi-activity/commit/0061066ac2393ee467ef6b15d1c6570a74a53301))
6
+
1
7
  ## [0.2.1](https://github.com/prjct-app/pi-activity/compare/v0.2.0...v0.2.1) (2026-09-10)
2
8
 
3
9
  ## [0.2.0](https://github.com/prjct-app/pi-activity/compare/v0.1.3...v0.2.0) (2026-09-10)
package/index.ts CHANGED
@@ -184,7 +184,16 @@ export default function activityMode(pi: ExtensionAPI) {
184
184
  name,
185
185
  renderShell: "self",
186
186
  async execute(toolCallId, params, signal, onUpdate, ctx) {
187
- return createTool(ctx.cwd).execute(toolCallId, params, signal, onUpdate);
187
+ // Pi supplies ExtensionContext as a fifth argument at runtime, although
188
+ // AgentTool's public execute type currently exposes only the first four.
189
+ const executeWithContext = createTool(ctx.cwd).execute as (
190
+ id: string,
191
+ input: Parameters<AgentTool<T, D>["execute"]>[1],
192
+ abortSignal: Parameters<AgentTool<T, D>["execute"]>[2],
193
+ update: Parameters<AgentTool<T, D>["execute"]>[3],
194
+ context: ExtensionContext,
195
+ ) => ReturnType<AgentTool<T, D>["execute"]>;
196
+ return executeWithContext(toolCallId, params, signal, onUpdate, ctx);
188
197
  },
189
198
  renderCall(args, theme, context) {
190
199
  const id = context.toolCallId || `${name}:render`;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prjct.app/pi-activity",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Keep PI Agent tool output readable with compact, expandable activity rows and summaries of actions, errors, and changed files.",
5
5
  "type": "module",
6
6
  "keywords": [