@meldocio/mcp-stdio-proxy 1.0.10 → 1.0.11

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/bin/cli.js CHANGED
@@ -265,7 +265,7 @@ function showUsageHints() {
265
265
  /**
266
266
  * Main CLI handler
267
267
  */
268
- function main() {
268
+ async function main() {
269
269
  const args = process.argv.slice(2);
270
270
 
271
271
  if (args.length === 0) {
@@ -282,9 +282,9 @@ function main() {
282
282
  handleHelp();
283
283
  } else if (command === 'auth') {
284
284
  if (subcommand === 'login') {
285
- handleAuthLogin();
285
+ await handleAuthLogin();
286
286
  } else if (subcommand === 'status') {
287
- handleAuthStatus();
287
+ await handleAuthStatus();
288
288
  } else if (subcommand === 'logout') {
289
289
  handleAuthLogout();
290
290
  } else {
@@ -299,7 +299,7 @@ function main() {
299
299
  } else if (subcommand === 'get-workspace') {
300
300
  handleConfigGetWorkspace();
301
301
  } else if (subcommand === 'list-workspaces') {
302
- handleConfigListWorkspaces();
302
+ await handleConfigListWorkspaces();
303
303
  } else {
304
304
  logger.error(`Unknown config command: ${subcommand}`);
305
305
  console.log('\n' + logger.label('Usage:'));
@@ -315,7 +315,10 @@ function main() {
315
315
 
316
316
  // Run main when this file is required (called from main proxy)
317
317
  // main() will handle commands and exit, so this is safe to call
318
- main();
318
+ main().catch((error) => {
319
+ logger.error(`Unexpected error: ${error.message}`);
320
+ process.exit(1);
321
+ });
319
322
 
320
323
  module.exports = {
321
324
  handleAuthLogin,
@@ -12,8 +12,8 @@ const args = process.argv.slice(2);
12
12
  if (args.length > 0 && (args[0] === 'auth' || args[0] === 'config')) {
13
13
  // Handle CLI commands - cli.js will handle and exit
14
14
  require('./cli');
15
- // cli.js should have exited, but if not, exit here
16
- process.exit(0);
15
+ // Don't exit here - cli.js will handle process.exit() after async operations complete
16
+ return;
17
17
  }
18
18
 
19
19
  // Get package info - try multiple paths for different installation scenarios
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meldocio/mcp-stdio-proxy",
3
- "version": "1.0.10",
3
+ "version": "1.0.11",
4
4
  "description": "MCP stdio proxy for meldoc - connects Claude Desktop to meldoc MCP API",
5
5
  "bin": {
6
6
  "meldoc-mcp": "bin/meldoc-mcp-proxy.js"