mcporter-lanes
Give every Pi session a private MCPorter daemon lane.
Package details
Install mcporter-lanes from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:mcporter-lanes- Package
mcporter-lanes- Version
0.1.0- Published
- Jul 30, 2026
- Downloads
- not available
- Author
- max.engineer
- License
- MIT
- Types
- extension
- Size
- 18.7 KB
- Dependencies
- 0 dependencies · 1 peer
Pi manifest JSON
{
"extensions": [
"./index.ts"
]
}Security note
Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.
README
mcporter-lanes
A small Pi extension that gives every session its own private MCPorter daemon lane. Concurrent agents can use MCP servers without sharing — and fighting over — the same server processes.
I made this because I wanted to use safari-mcp across multiple Pi sessions and subagents, but the MCP clients kept stepping on one another.
Install
pi install npm:mcporter-lanes
Restart Pi after installing. That's it — there is no configuration.
The extension supports macOS and Linux. It deliberately blocks Bash calls if it cannot verify that Pi's local built-in Bash tool is active or cannot create a private runtime directory.
Subagents
Enable the extension in every subagent that uses MCPorter:
---
extensions: [mcporter-lanes]
---
This works with process-spawned and in-process subagents. Each runtime gets its own lane, while /reload keeps the current runtime's lane stable.
How it works
Before each local built-in Bash call, the extension injects a session-specific MCPORTER_DAEMON_DIR. Lanes live under a private, user-owned 0700 directory in /tmp; session identifiers are hashed rather than exposed in the path.
The environment change applies only to that Bash execution. It never mutates Pi's process-wide environment.
Development
npm install
npm run check
npm pack --dry-run
Pi loads the TypeScript source directly, so there is no build step.