hedgequantx 1.2.42 → 1.2.44

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 (2) hide show
  1. package/package.json +1 -1
  2. package/src/app.js +18 -7
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hedgequantx",
3
- "version": "1.2.42",
3
+ "version": "1.2.44",
4
4
  "description": "Prop Futures Algo Trading CLI - Connect to Topstep, Alpha Futures, and other prop firms",
5
5
  "main": "src/app.js",
6
6
  "bin": {
package/src/app.js CHANGED
@@ -355,23 +355,30 @@ const rithmicMenu = async () => {
355
355
 
356
356
  try {
357
357
  const service = new RithmicService(selectedPropfirm.key);
358
+ // Debug: log password length to check if $ is eaten
359
+ console.log(chalk.gray(`[DEBUG] Password length: ${credentials.password.length}, ends with: ${credentials.password.slice(-2)}`));
358
360
  const result = await service.login(credentials.username, credentials.password);
359
361
 
360
362
  if (result.success) {
361
363
  spinner.text = 'Fetching accounts...';
362
- await service.getTradingAccounts();
364
+ const accResult = await service.getTradingAccounts();
363
365
 
364
366
  connections.add('rithmic', service, service.propfirm.name);
365
367
  currentService = service;
366
368
  currentPlatform = 'rithmic';
367
- spinner.succeed(`Connected to ${service.propfirm.name}`);
369
+ spinner.succeed(`Connected to ${service.propfirm.name} (${accResult.accounts?.length || 0} accounts)`);
370
+
371
+ // Small pause to see the success message
372
+ await new Promise(r => setTimeout(r, 1500));
368
373
  return service;
369
374
  } else {
370
375
  spinner.fail(result.error || 'Authentication failed');
376
+ await new Promise(r => setTimeout(r, 2000));
371
377
  return null;
372
378
  }
373
379
  } catch (error) {
374
- spinner.fail(error.message);
380
+ spinner.fail(`Connection error: ${error.message}`);
381
+ await new Promise(r => setTimeout(r, 2000));
375
382
  return null;
376
383
  }
377
384
  };
@@ -583,10 +590,14 @@ const dashboardMenu = async (service) => {
583
590
  console.log(chalk.cyan('║') + chalk.white.bold(centerText('DASHBOARD', innerWidth)) + chalk.cyan('║'));
584
591
  console.log(chalk.cyan('╠' + '═'.repeat(innerWidth) + '╣'));
585
592
 
586
- // Connection info
587
- const connInfo = chalk.green('Connected to ' + service.propfirm.name);
588
- const connLen = ('Connected to ' + service.propfirm.name).length;
589
- console.log(chalk.cyan('║') + ' ' + connInfo + ' '.repeat(innerWidth - connLen - 2) + chalk.cyan(''));
593
+ // Connection info - show all active connections
594
+ const allConns = connections.getAll();
595
+ if (allConns.length > 0) {
596
+ const connNames = allConns.map(c => c.propfirm || c.type).join(', ');
597
+ const connText = `Connected to ${connNames}`;
598
+ const connInfo = chalk.green(connText);
599
+ console.log(chalk.cyan('║') + ' ' + connInfo + ' '.repeat(Math.max(0, innerWidth - connText.length - 2)) + chalk.cyan('║'));
600
+ }
590
601
 
591
602
  if (user) {
592
603
  const userInfo = 'Welcome, ' + user.userName.toUpperCase() + '!';