tradeblocks-mcp 3.0.0 → 3.0.1

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/manifest.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "manifest_version": "0.3",
3
3
  "name": "tradeblocks",
4
4
  "display_name": "TradeBlocks",
5
- "version": "3.0.0",
5
+ "version": "3.0.1",
6
6
  "description": "Options trading analysis - backtest stats, walk-forward analysis, Monte Carlo simulations, and risk metrics",
7
7
  "long_description": "TradeBlocks MCP server provides comprehensive options trading analysis capabilities. Import your trade logs and get detailed performance statistics, run walk-forward analysis to detect overfitting, perform Monte Carlo simulations for risk assessment, calculate optimal position sizing with Kelly criterion, and compare backtest results against actual trading performance. All analysis runs locally on your machine.",
8
8
  "author": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tradeblocks-mcp",
3
- "version": "3.0.0",
3
+ "version": "3.0.1",
4
4
  "description": "MCP server for options trade analysis",
5
5
  "author": "David Romeo <davidmromeo@gmail.com>",
6
6
  "type": "module",
package/server/index.js CHANGED
@@ -19714,9 +19714,21 @@ async function startTradeBlocksMcp(options = {}) {
19714
19714
  process.on("SIGINT", shutdown);
19715
19715
  process.on("SIGTERM", shutdown);
19716
19716
  }
19717
- var entrypoint = process.argv[1] ? path13.resolve(process.argv[1]) : "";
19718
- var currentFile = fileURLToPath(import.meta.url);
19719
- if (entrypoint === currentFile) {
19717
+ async function resolveEntrypointPath(filePath) {
19718
+ const resolved = path13.resolve(filePath);
19719
+ try {
19720
+ return await fs3.realpath(resolved);
19721
+ } catch {
19722
+ return resolved;
19723
+ }
19724
+ }
19725
+ async function isDirectEntrypoint() {
19726
+ if (!process.argv[1]) return false;
19727
+ const entrypoint = await resolveEntrypointPath(process.argv[1]);
19728
+ const currentFile = await resolveEntrypointPath(fileURLToPath(import.meta.url));
19729
+ return entrypoint === currentFile;
19730
+ }
19731
+ if (await isDirectEntrypoint()) {
19720
19732
  startTradeBlocksMcp().catch((error) => {
19721
19733
  console.error("Error:", error.message || error);
19722
19734
  process.exit(1);