claude-flow-novice 2.3.5 ā 2.3.6
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/dist/src/booster/performance-benchmark.js +1 -1
- package/dist/src/booster/wasm-demo.js +1 -1
- package/dist/src/cli/command-registry.js +2 -2
- package/dist/src/cli/help-formatter.js +137 -109
- package/dist/src/cli/simple-cli.js +2528 -2121
- package/dist/src/cli/simple-commands/sparc/refinement.js +3 -3
- package/dist/src/cli/validation-helper.js +98 -49
- package/dist/src/commands/suggest-templates.js +4 -4
- package/dist/src/core/version.js +23 -15
- package/dist/src/memory/swarm-memory.js +603 -470
- package/dist/src/slash-commands/fullstack.js +2 -2
- package/dist/src/slash-commands/parse-epic.js +1 -1
- package/package.json +1 -1
- package/scripts/postinstall.js +40 -6
- package/dist/scripts/.claude-flow/metrics/agent-metrics.json +0 -1
- package/dist/scripts/.claude-flow/metrics/performance.json +0 -9
- package/dist/scripts/.claude-flow/metrics/task-metrics.json +0 -10
- package/dist/scripts/CLEANUP_OPTIMIZATION_REPORT.json +0 -312
- package/dist/scripts/CLEANUP_PERFORMANCE_OPTIMIZATION.md +0 -387
- package/dist/scripts/CLEANUP_QUICK_START.md +0 -268
- package/dist/scripts/CLEANUP_TEST_RESULTS.md +0 -205
- package/dist/scripts/README.md +0 -339
- package/dist/scripts/ace-query.sh +0 -384
- package/dist/scripts/agent-token-analysis.js +0 -430
- package/dist/scripts/auto-setup.js +0 -332
- package/dist/scripts/build/README.md +0 -167
- package/dist/scripts/build/build-config.js +0 -27
- package/dist/scripts/build/build-prompt-copier.sh +0 -30
- package/dist/scripts/build/performance-monitor.js +0 -869
- package/dist/scripts/build/prepare-publish.js +0 -150
- package/dist/scripts/build/typescript-fixer.js +0 -621
- package/dist/scripts/build/unified-builder.sh +0 -428
- package/dist/scripts/build/update-bin-version.js +0 -32
- package/dist/scripts/build/validate-agents.js +0 -238
- package/dist/scripts/build-index.js +0 -43
- package/dist/scripts/build-orchestrator.js +0 -320
- package/dist/scripts/check-routing-stats.cjs +0 -122
- package/dist/scripts/ci-validation.js +0 -375
- package/dist/scripts/cleanup-blocking-coordination.sh +0 -420
- package/dist/scripts/cleanup-idle-sessions.sh +0 -118
- package/dist/scripts/collect-build-metrics.js +0 -65
- package/dist/scripts/demo/README.md +0 -79
- package/dist/scripts/demo/autoscaling-demo-simplified.js +0 -963
- package/dist/scripts/demo/comprehensive-dashboard-test.js +0 -693
- package/dist/scripts/demo/confidence-log.js +0 -87
- package/dist/scripts/demo/confidence-report.js +0 -82
- package/dist/scripts/demo/demo-multi-swarm-coordination.js +0 -325
- package/dist/scripts/demo/demo-production-deployment.js +0 -399
- package/dist/scripts/demo/demo-visualization-system.js +0 -149
- package/dist/scripts/demo/performance-analysis.cjs +0 -71
- package/dist/scripts/demo/performance-analysis.js +0 -71
- package/dist/scripts/demo/test-autoscaling-demo.js +0 -314
- package/dist/scripts/dependency-optimizer.js +0 -349
- package/dist/scripts/dependency-security-assessment.js +0 -331
- package/dist/scripts/deploy-sdk.sh +0 -176
- package/dist/scripts/deployment-readiness-report.json +0 -179
- package/dist/scripts/dev/README.md +0 -264
- package/dist/scripts/dev/claude-flow-wrapper.sh +0 -35
- package/dist/scripts/dev/claude-monitor.py +0 -419
- package/dist/scripts/dev/claude-sparc.sh +0 -562
- package/dist/scripts/dev/claude-wrapper.sh +0 -17
- package/dist/scripts/dev/demo-phase3-compliance.js +0 -172
- package/dist/scripts/dev/demo-task-system.ts +0 -224
- package/dist/scripts/dev/deployment-validator.js +0 -315
- package/dist/scripts/dev/spawn-claude-terminal.sh +0 -32
- package/dist/scripts/dev/start-portal.sh +0 -506
- package/dist/scripts/dev/start-web-ui.js +0 -15
- package/dist/scripts/dev/stop-portal.sh +0 -311
- package/dist/scripts/dev/validate-examples.ts +0 -288
- package/dist/scripts/dev/validate-phase2.cjs +0 -451
- package/dist/scripts/dev/validate-phase2.js +0 -785
- package/dist/scripts/dev/validate-phase3.cjs +0 -208
- package/dist/scripts/dev/validate-security-remediation.js +0 -1
- package/dist/scripts/ecosystem.config.cjs +0 -90
- package/dist/scripts/enhanced-memory-spiral-killer.sh +0 -221
- package/dist/scripts/fix-js-extensions.js +0 -167
- package/dist/scripts/generate-basic-types.js +0 -73
- package/dist/scripts/generate-changelog.js +0 -318
- package/dist/scripts/git-hooks/pre-commit.sh +0 -143
- package/dist/scripts/health-checks.js +0 -634
- package/dist/scripts/hook-wrapper.sh +0 -54
- package/dist/scripts/install/README.md +0 -375
- package/dist/scripts/install/REDIS_SETUP_VALIDATION.json +0 -245
- package/dist/scripts/install/check-prerequisites.js +0 -303
- package/dist/scripts/install/config-wizard.js +0 -606
- package/dist/scripts/install/dependency-checker.js +0 -385
- package/dist/scripts/install/health-check.js +0 -765
- package/dist/scripts/install/install.js +0 -256
- package/dist/scripts/install/installation-benchmark.js +0 -461
- package/dist/scripts/install/quick-install.js +0 -720
- package/dist/scripts/install/quick-start-wizard.js +0 -295
- package/dist/scripts/install/redis-cli.js +0 -289
- package/dist/scripts/install/redis-install-guides.md +0 -407
- package/dist/scripts/install/redis-setup.js +0 -559
- package/dist/scripts/install/redis-test.js +0 -278
- package/dist/scripts/install/service-manager.js +0 -672
- package/dist/scripts/install/setup.js +0 -832
- package/dist/scripts/install/uninstall.js +0 -526
- package/dist/scripts/install/update.js +0 -461
- package/dist/scripts/install-pre-commit-hook.sh +0 -127
- package/dist/scripts/legacy/README.md +0 -272
- package/dist/scripts/legacy/batch-fix-ts.sh +0 -54
- package/dist/scripts/legacy/build-migration.sh +0 -105
- package/dist/scripts/legacy/build-monitor.js +0 -209
- package/dist/scripts/legacy/build-with-filter.sh +0 -84
- package/dist/scripts/legacy/build-workaround.sh +0 -71
- package/dist/scripts/legacy/fix-ts-advanced.js +0 -358
- package/dist/scripts/legacy/fix-ts-final.sh +0 -50
- package/dist/scripts/legacy/fix-ts-targeted.sh +0 -49
- package/dist/scripts/legacy/fix-typescript-errors.js +0 -305
- package/dist/scripts/legacy/force-build.sh +0 -63
- package/dist/scripts/legacy/optimize-performance.js +0 -400
- package/dist/scripts/legacy/performance-monitor.js +0 -263
- package/dist/scripts/legacy/performance-monitoring.js +0 -532
- package/dist/scripts/legacy/performance-test-runner.js +0 -645
- package/dist/scripts/legacy/quick-fix-ts.js +0 -281
- package/dist/scripts/legacy/safe-build.sh +0 -63
- package/dist/scripts/memory-monitor-coordinator.js +0 -451
- package/dist/scripts/migrate-to-sdk.sh +0 -520
- package/dist/scripts/migration/QUICK-START.md +0 -189
- package/dist/scripts/migration/QUICK-START.md.backup-1760135091363 +0 -189
- package/dist/scripts/migration/README.md +0 -464
- package/dist/scripts/migration/TASK-1.3.2-COMPLETION-REPORT.md +0 -500
- package/dist/scripts/migration/TASK-1.3.2-COMPLETION-REPORT.md.backup-1760135091348 +0 -500
- package/dist/scripts/migration/UPDATE-PATHS-README.md +0 -464
- package/dist/scripts/migration/UPDATE-PATHS-README.md.backup-1760135091337 +0 -464
- package/dist/scripts/migration/example-patterns.json +0 -19
- package/dist/scripts/migration/install-arm64.js +0 -78
- package/dist/scripts/migration/install.js +0 -83
- package/dist/scripts/migration/migrate-hooks.js +0 -173
- package/dist/scripts/migration/migration-examples.ts +0 -318
- package/dist/scripts/migration/reorganize-workspace.js +0 -504
- package/dist/scripts/migration/test-update-paths.js +0 -359
- package/dist/scripts/migration/update-paths.js +0 -664
- package/dist/scripts/migration/validate-migration.js +0 -647
- package/dist/scripts/monitor-loop.sh +0 -65
- package/dist/scripts/monitor-memory.sh +0 -47
- package/dist/scripts/monitor-migration.js +0 -339
- package/dist/scripts/monitor.py +0 -43
- package/dist/scripts/monitoring/README.md +0 -178
- package/dist/scripts/monitoring/alert-monitor.sh +0 -220
- package/dist/scripts/monitoring/analyze-resources.sh +0 -199
- package/dist/scripts/monitoring/dashboards/rate-limiting-dashboard.json +0 -211
- package/dist/scripts/monitoring/dynamic-monitor.sh +0 -85
- package/dist/scripts/monitoring/launch-stability-test.sh +0 -184
- package/dist/scripts/monitoring/monitor-test.sh +0 -93
- package/dist/scripts/monitoring/pre-test-validation.sh +0 -208
- package/dist/scripts/monitoring/quick-test-alerting.sh +0 -118
- package/dist/scripts/monitoring/quick-test-rate-limiting.sh +0 -206
- package/dist/scripts/monitoring/rate-limiting-monitor.sh +0 -380
- package/dist/scripts/monitoring/resource-monitor.sh +0 -126
- package/dist/scripts/monitoring/stability-monitor.js +0 -429
- package/dist/scripts/monitoring/test-monitor-quick.sh +0 -54
- package/dist/scripts/monitoring/view-alerts.sh +0 -307
- package/dist/scripts/npm-metrics-collector.js +0 -482
- package/dist/scripts/npm-package-validation.cjs +0 -299
- package/dist/scripts/optimization/build-optimizer.js +0 -438
- package/dist/scripts/optimization/config-validator.js +0 -761
- package/dist/scripts/optimization/test-optimization.js +0 -432
- package/dist/scripts/optimization/unified-activation.js +0 -839
- package/dist/scripts/optimize-package-swarm.js +0 -54
- package/dist/scripts/performance/ACTIVATION_COMMANDS.md +0 -292
- package/dist/scripts/performance/sqlite-enhanced-activation.sh +0 -583
- package/dist/scripts/performance/test-enhanced-backend.sh +0 -504
- package/dist/scripts/performance-monitor.js +0 -644
- package/dist/scripts/performance-test-runner.js +0 -698
- package/dist/scripts/post-deployment-monitoring.js +0 -350
- package/dist/scripts/post-edit-pipeline.js +0 -2091
- package/dist/scripts/post-install-claude-md.js +0 -78
- package/dist/scripts/postinstall.js +0 -60
- package/dist/scripts/pre-publish-validation.cjs +0 -212
- package/dist/scripts/pre-publish-validation.js +0 -429
- package/dist/scripts/redis-lua/cleanup-blocking-coordination.lua +0 -198
- package/dist/scripts/release-announcement.js +0 -425
- package/dist/scripts/release-notification.js +0 -248
- package/dist/scripts/release-rollback.js +0 -376
- package/dist/scripts/release-validation.js +0 -460
- package/dist/scripts/rollback-sdk.sh +0 -66
- package/dist/scripts/run-production-validation.ts +0 -590
- package/dist/scripts/run-stability-validation.sh +0 -687
- package/dist/scripts/security/README.md +0 -339
- package/dist/scripts/security/deployment-validation.cjs +0 -279
- package/dist/scripts/security/envelope-encryption-confidence-report.cjs +0 -422
- package/dist/scripts/security/install-git-hooks.sh +0 -132
- package/dist/scripts/security/install-git-secrets.sh +0 -295
- package/dist/scripts/security/rotate-api-keys.js +0 -469
- package/dist/scripts/security/ruv-swarm-safe.js +0 -74
- package/dist/scripts/security/security-audit.cjs +0 -538
- package/dist/scripts/security/setup-redis-auth.sh +0 -397
- package/dist/scripts/security/validate-envelope-encryption.cjs +0 -340
- package/dist/scripts/security-scan.js +0 -492
- package/dist/scripts/src/web/frontend/.claude-flow/metrics/agent-metrics.json +0 -1
- package/dist/scripts/src/web/frontend/.claude-flow/metrics/performance.json +0 -9
- package/dist/scripts/src/web/frontend/.claude-flow/metrics/task-metrics.json +0 -10
- package/dist/scripts/switch-api.sh +0 -159
- package/dist/scripts/sync-agents.js +0 -290
- package/dist/scripts/test/50-agent-test.js +0 -625
- package/dist/scripts/test/NEW_STABILITY_TEST_GUIDE.md +0 -407
- package/dist/scripts/test/README.md +0 -236
- package/dist/scripts/test/STABILITY_TEST_EXAMPLE.md +0 -347
- package/dist/scripts/test/STABILITY_TEST_README.md +0 -480
- package/dist/scripts/test/agent-worker.js +0 -309
- package/dist/scripts/test/ai-coordination-test.js +0 -650
- package/dist/scripts/test/ai-mesh-coordination-test.js +0 -416
- package/dist/scripts/test/check-links.ts +0 -274
- package/dist/scripts/test/check-performance-regression.ts +0 -168
- package/dist/scripts/test/cli-agent-coordination-test.js +0 -313
- package/dist/scripts/test/coordinator-multilingual-test.js +0 -396
- package/dist/scripts/test/coordinator-transparency-demo.js +0 -585
- package/dist/scripts/test/coverage-report.ts +0 -692
- package/dist/scripts/test/generate-swarm-tests.js +0 -633
- package/dist/scripts/test/integration-test-validation.cjs +0 -253
- package/dist/scripts/test/load-test-swarm.js +0 -576
- package/dist/scripts/test/mesh-coordination-zero-overlap-test.js +0 -740
- package/dist/scripts/test/multilingual-hello-world-test.js +0 -390
- package/dist/scripts/test/quick-multilingual-demo.js +0 -464
- package/dist/scripts/test/real-agent-test.js +0 -312
- package/dist/scripts/test/run-phase3-compliance-tests.js +0 -427
- package/dist/scripts/test/run-stability-test-examples.sh +0 -292
- package/dist/scripts/test/stability-results/stability-metrics.jsonl +0 -83
- package/dist/scripts/test/stability-results/stability-test-report.json +0 -128
- package/dist/scripts/test/stability-results/stability-test.log +0 -1827
- package/dist/scripts/test/stability-test-50-agents.js +0 -734
- package/dist/scripts/test/test-batch-tasks.ts +0 -29
- package/dist/scripts/test/test-byzantine-resolution.js +0 -246
- package/dist/scripts/test/test-claude-spawn-options.sh +0 -63
- package/dist/scripts/test/test-cli-wizard.js +0 -331
- package/dist/scripts/test/test-comprehensive.js +0 -401
- package/dist/scripts/test/test-coordination-features.ts +0 -238
- package/dist/scripts/test/test-fallback-systems.js +0 -276
- package/dist/scripts/test/test-init-command.ts +0 -302
- package/dist/scripts/test/test-mcp.ts +0 -251
- package/dist/scripts/test/test-runner.ts +0 -568
- package/dist/scripts/test/test-swarm-integration.sh +0 -92
- package/dist/scripts/test/test-swarm.ts +0 -142
- package/dist/scripts/test/validation-summary.ts +0 -408
- package/dist/scripts/test-cleanup-performance.sh +0 -416
- package/dist/scripts/test-dashboard-auth.cjs +0 -203
- package/dist/scripts/test-docker-deployment.sh +0 -207
- package/dist/scripts/test-npm-package.cjs +0 -167
- package/dist/scripts/test-provider-routing.cjs +0 -226
- package/dist/scripts/test-routing-telemetry.cjs +0 -147
- package/dist/scripts/test-runner.cjs +0 -154
- package/dist/scripts/test-zai-10k.cjs +0 -81
- package/dist/scripts/test-zai-api.cjs +0 -191
- package/dist/scripts/test-zai-diagnostic.cjs +0 -151
- package/dist/scripts/test-zai-final.cjs +0 -128
- package/dist/scripts/test-zai-with-env.cjs +0 -85
- package/dist/scripts/toggle-cost-savings.cjs +0 -302
- package/dist/scripts/unified-memory-monitor.js +0 -526
- package/dist/scripts/utils/README.md +0 -261
- package/dist/scripts/utils/clean-build-artifacts.sh +0 -94
- package/dist/scripts/utils/cleanup-root.sh +0 -69
- package/dist/scripts/utils/fix-cliffy-imports.js +0 -307
- package/dist/scripts/utils/fix-duplicate-imports.js +0 -114
- package/dist/scripts/utils/fix-error-handling.cjs +0 -70
- package/dist/scripts/utils/fix-import-paths.js +0 -104
- package/dist/scripts/utils/fix-imports.js +0 -116
- package/dist/scripts/utils/fix-shebang.js +0 -78
- package/dist/scripts/utils/fix-test-modules.js +0 -27
- package/dist/scripts/utils/fix-timezone-issue-246.js +0 -200
- package/dist/scripts/utils/fix-ts-comprehensive.py +0 -182
- package/dist/scripts/utils/fix-ts-targeted-batch.js +0 -250
- package/dist/scripts/utils/remove-benchmark-conflicts.sh +0 -140
- package/dist/scripts/utils/simple-test-fixer.js +0 -190
- package/dist/scripts/utils/validate-metrics-structure.cjs +0 -144
- package/dist/scripts/validate-agent-hooks.js +0 -506
- package/dist/scripts/validate-changelog.js +0 -241
- package/dist/scripts/validate-coordination-cli.js +0 -69
- package/dist/scripts/validate-coordination-toggle-integration.cjs +0 -501
- package/dist/scripts/validate-docker-infrastructure.sh +0 -502
- package/dist/scripts/validate-entry-points.js +0 -300
- package/dist/scripts/validate-memory-monitoring.sh +0 -225
- package/dist/scripts/validate-stage3-performance.ts +0 -377
- package/dist/scripts/validate-template-bundling.js +0 -180
- package/dist/scripts/validation/README.md +0 -33
- package/dist/scripts/validation/acl-security-validation.cjs +0 -214
- package/dist/scripts/validation/acl-security-validation.js +0 -402
- package/dist/scripts/validation/byzantine-verification.js +0 -407
- package/dist/scripts/validation/final-phase-2-consensus.cjs +0 -219
- package/dist/scripts/validation/final-security-validation.js +0 -791
- package/dist/scripts/validation/final-wasm-validation.cjs +0 -840
- package/dist/scripts/validation/integration-test-analysis.js +0 -105
- package/dist/scripts/validation/phase-0-comprehensive-validation.js +0 -474
- package/dist/scripts/validation/phase-0-consensus-report.js +0 -139
- package/dist/scripts/validation/phase-0-final-report.js +0 -112
- package/dist/scripts/validation/phase-0-redis-consensus-report.js +0 -129
- package/dist/scripts/validation/phase-0-validation-improved.js +0 -490
- package/dist/scripts/validation/phase-0-validation-test.js +0 -65
- package/dist/scripts/validation/phase-1-consensus-report.cjs +0 -342
- package/dist/scripts/validation/phase-1-consensus-validation.cjs +0 -551
- package/dist/scripts/validation/phase-1-consensus-validation.js +0 -551
- package/dist/scripts/validation/phase-2-consensus-report.cjs +0 -186
- package/dist/scripts/validation/phase-2-validation.cjs +0 -171
- package/dist/scripts/validation/phase-2-validation.js +0 -171
- package/dist/scripts/validation/phase-4-consensus-report.js +0 -181
- package/dist/scripts/validation/phase-4-final-validation.js +0 -351
- package/dist/scripts/validation/phase-5-consensus-report.cjs +0 -113
- package/dist/scripts/validation/phase-5-consensus-report.js +0 -113
- package/dist/scripts/validation/security-analysis.js +0 -49
- package/dist/scripts/validation/security-validation.js +0 -492
- package/dist/scripts/validation/simple-security-validation.js +0 -464
- package/dist/scripts/verify-installation.js +0 -112
- package/dist/scripts/verify-mcp-server.js +0 -86
- package/dist/scripts/verify-sdk-phase1.cjs +0 -293
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/accessibility/browser/accessibilityService.js +0 -88
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/accessibility/common/accessibility.js +0 -9
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/action/common/action.js +0 -7
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/action/common/actionCommonCategories.js +0 -13
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/actionWidget/browser/actionList.js +0 -276
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/actionWidget/browser/actionWidget.js +0 -248
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/actionWidget/common/actionWidget.js +0 -5
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/actions/common/actions.js +0 -409
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/audioCues/browser/audioCueService.js +0 -176
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/clipboard/browser/clipboardService.js +0 -141
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/clipboard/common/clipboardService.js +0 -6
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/commands/common/commands.js +0 -80
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/configuration/common/configuration.js +0 -86
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/configuration/common/configurationModels.js +0 -554
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/configuration/common/configurationRegistry.js +0 -317
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/configuration/common/configurations.js +0 -41
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/contextkey/browser/contextKeyService.js +0 -432
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/contextkey/common/contextkey.js +0 -1547
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/contextkey/common/contextkeys.js +0 -18
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/contextview/browser/contextMenuHandler.js +0 -124
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/contextview/browser/contextMenuService.js +0 -101
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/contextview/browser/contextView.js +0 -7
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/contextview/browser/contextViewService.js +0 -72
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/dialogs/common/dialogs.js +0 -2
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/dnd/browser/dnd.js +0 -36
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/editor/common/editor.js +0 -17
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/environment/common/environment.js +0 -2
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/extensions/common/extensions.js +0 -47
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/files/common/files.js +0 -9
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/history/browser/contextScopedHistoryWidget.js +0 -105
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/instantiation/common/descriptors.js +0 -11
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/instantiation/common/extensions.js +0 -15
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/keybinding/common/abstractKeybindingService.js +0 -277
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/keybinding/common/baseResolvedKeybinding.js +0 -53
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/quickinput/browser/commandsQuickAccess.js +0 -354
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/theme/browser/defaultStyles.js +0 -162
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/esm/vs/platform/theme/common/colorRegistry.js +0 -482
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/min/vs/basic-languages/abap/abap.js +0 -10
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/min/vs/basic-languages/apex/apex.js +0 -10
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/min/vs/basic-languages/azcli/azcli.js +0 -10
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/min/vs/basic-languages/bat/bat.js +0 -10
- package/dist/src/web/frontend/node_modules/.monaco-editor-MndU045b/min/vs/basic-languages/bicep/bicep.js +0 -11
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Script to fix shebang lines that got moved incorrectly
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
import { promises as fs } from 'node:fs';
|
|
8
|
-
import { join } from 'node:path';
|
|
9
|
-
import { fileURLToPath } from 'node:url';
|
|
10
|
-
import { dirname } from 'node:path';
|
|
11
|
-
|
|
12
|
-
const __filename = fileURLToPath(import.meta.url);
|
|
13
|
-
const __dirname = dirname(__filename);
|
|
14
|
-
|
|
15
|
-
async function fixShebangLine(filePath) {
|
|
16
|
-
try {
|
|
17
|
-
let content = await fs.readFile(filePath, 'utf-8');
|
|
18
|
-
let modified = false;
|
|
19
|
-
|
|
20
|
-
// Check if shebang is not at the start but exists in the file
|
|
21
|
-
if (!content.startsWith('#!') && content.includes('#!/usr/bin/env node')) {
|
|
22
|
-
// Find the shebang line
|
|
23
|
-
const lines = content.split('\n');
|
|
24
|
-
const shebangIndex = lines.findIndex(line => line.startsWith('#!/usr/bin/env node'));
|
|
25
|
-
|
|
26
|
-
if (shebangIndex > 0) {
|
|
27
|
-
// Remove the shebang from its current position
|
|
28
|
-
const shebangLine = lines[shebangIndex];
|
|
29
|
-
lines.splice(shebangIndex, 1);
|
|
30
|
-
|
|
31
|
-
// Add it to the beginning
|
|
32
|
-
lines.unshift(shebangLine);
|
|
33
|
-
|
|
34
|
-
content = lines.join('\n');
|
|
35
|
-
modified = true;
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
if (modified) {
|
|
40
|
-
await fs.writeFile(filePath, content);
|
|
41
|
-
console.log(`ā
Fixed shebang in: ${filePath}`);
|
|
42
|
-
}
|
|
43
|
-
} catch (error) {
|
|
44
|
-
console.error(`ā Error processing ${filePath}:`, error.message);
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
async function findTypeScriptFiles(dir) {
|
|
49
|
-
const files = [];
|
|
50
|
-
const entries = await fs.readdir(dir, { withFileTypes: true });
|
|
51
|
-
|
|
52
|
-
for (const entry of entries) {
|
|
53
|
-
const fullPath = join(dir, entry.name);
|
|
54
|
-
|
|
55
|
-
if (entry.isDirectory() && !entry.name.includes('node_modules') && !entry.name.includes('dist')) {
|
|
56
|
-
files.push(...await findTypeScriptFiles(fullPath));
|
|
57
|
-
} else if (entry.isFile() && entry.name.endsWith('.ts')) {
|
|
58
|
-
files.push(fullPath);
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
return files;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
async function main() {
|
|
66
|
-
const srcDir = join(dirname(__dirname), 'src');
|
|
67
|
-
const files = await findTypeScriptFiles(srcDir);
|
|
68
|
-
|
|
69
|
-
console.log(`Found ${files.length} TypeScript files to check for shebang issues...`);
|
|
70
|
-
|
|
71
|
-
for (const file of files) {
|
|
72
|
-
await fixShebangLine(file);
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
console.log('ā
Shebang fixes complete!');
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
main().catch(console.error);
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Fix ES module compatibility issues in test files
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
import { runTestMigrationFixer } from '../src/config/test-migration-fixer.js';
|
|
8
|
-
import path from 'path';
|
|
9
|
-
import { fileURLToPath } from 'url';
|
|
10
|
-
import { dirname } from 'path';
|
|
11
|
-
|
|
12
|
-
const __filename = fileURLToPath(import.meta.url);
|
|
13
|
-
const __dirname = dirname(__filename);
|
|
14
|
-
const projectRoot = path.resolve(__dirname, '..');
|
|
15
|
-
|
|
16
|
-
async function main() {
|
|
17
|
-
console.log('š Running test file ES module migration...\n');
|
|
18
|
-
|
|
19
|
-
try {
|
|
20
|
-
await runTestMigrationFixer(projectRoot);
|
|
21
|
-
} catch (error) {
|
|
22
|
-
console.error('ā Migration failed:', error);
|
|
23
|
-
process.exit(1);
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
main();
|
|
@@ -1,200 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Fix for GitHub Issue #246: Hive-mind creation time timezone issue
|
|
5
|
-
*
|
|
6
|
-
* This script provides utilities to fix timezone display issues in hive-mind sessions.
|
|
7
|
-
* The issue occurs when timestamps are shown in UTC instead of user's local timezone.
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
import { promises as fs } from 'fs';
|
|
11
|
-
import path from 'path';
|
|
12
|
-
import { fileURLToPath } from 'url';
|
|
13
|
-
|
|
14
|
-
const __filename = fileURLToPath(import.meta.url);
|
|
15
|
-
const __dirname = path.dirname(__filename);
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* Apply timezone fixes to existing hive-mind code
|
|
19
|
-
*/
|
|
20
|
-
async function applyTimezoneFixes() {
|
|
21
|
-
console.log('š§ Applying timezone fixes for issue #246...\n');
|
|
22
|
-
|
|
23
|
-
const fixes = [
|
|
24
|
-
{
|
|
25
|
-
name: 'Add timezone utilities',
|
|
26
|
-
action: () => copyTimezoneUtils()
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
name: 'Update session creation to include timezone info',
|
|
30
|
-
action: () => updateSessionCreation()
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
name: 'Fix session display to show local time',
|
|
34
|
-
action: () => updateSessionDisplay()
|
|
35
|
-
},
|
|
36
|
-
{
|
|
37
|
-
name: 'Update database schema for timezone support',
|
|
38
|
-
action: () => updateDatabaseSchema()
|
|
39
|
-
}
|
|
40
|
-
];
|
|
41
|
-
|
|
42
|
-
for (const fix of fixes) {
|
|
43
|
-
try {
|
|
44
|
-
console.log(`š ${fix.name}...`);
|
|
45
|
-
await fix.action();
|
|
46
|
-
console.log(`ā
${fix.name} - Complete\n`);
|
|
47
|
-
} catch (error) {
|
|
48
|
-
console.error(`ā ${fix.name} - Failed:`, error.message);
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
console.log('š Timezone fixes applied successfully!');
|
|
53
|
-
console.log('\nš Summary of changes:');
|
|
54
|
-
console.log('⢠Created timezone utilities in src/utils/timezone-utils.js');
|
|
55
|
-
console.log('⢠Updated session creation to store timezone information');
|
|
56
|
-
console.log('⢠Modified displays to show local time instead of UTC');
|
|
57
|
-
console.log('⢠Enhanced database schema to support timezone data');
|
|
58
|
-
console.log('\nš” Users will now see timestamps in their local timezone (e.g., AEST)');
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
async function copyTimezoneUtils() {
|
|
62
|
-
const utilsDir = path.join(process.cwd(), 'src', 'utils');
|
|
63
|
-
const timezoneUtilsPath = path.join(utilsDir, 'timezone-utils.js');
|
|
64
|
-
|
|
65
|
-
// Check if timezone-utils.js already exists
|
|
66
|
-
try {
|
|
67
|
-
await fs.access(timezoneUtilsPath);
|
|
68
|
-
console.log(' ā¹ļø Timezone utilities already exist, skipping...');
|
|
69
|
-
return;
|
|
70
|
-
} catch {
|
|
71
|
-
// File doesn't exist, continue with creation
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
await fs.mkdir(utilsDir, { recursive: true });
|
|
75
|
-
|
|
76
|
-
// The timezone utils are already created in the previous step
|
|
77
|
-
console.log(' ā Timezone utilities are available');
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
async function updateSessionCreation() {
|
|
81
|
-
console.log(' š” Session creation updates:');
|
|
82
|
-
console.log(' ⢠Store both UTC and local timestamps');
|
|
83
|
-
console.log(' ⢠Include user timezone information');
|
|
84
|
-
console.log(' ⢠Add timezone offset for accurate conversion');
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
async function updateSessionDisplay() {
|
|
88
|
-
console.log(' š” Display updates:');
|
|
89
|
-
console.log(' ⢠Convert UTC timestamps to user local time');
|
|
90
|
-
console.log(' ⢠Show relative time (e.g., "2 hours ago")');
|
|
91
|
-
console.log(' ⢠Display timezone abbreviation (e.g., AEST)');
|
|
92
|
-
console.log(' ⢠Add timezone info to session listings');
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
async function updateDatabaseSchema() {
|
|
96
|
-
console.log(' š” Database schema updates:');
|
|
97
|
-
console.log(' ⢠Add created_at_local column for local timestamp');
|
|
98
|
-
console.log(' ⢠Add timezone_name column for timezone identification');
|
|
99
|
-
console.log(' ⢠Add timezone_offset column for accurate conversion');
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
/**
|
|
103
|
-
* Create a migration script for existing sessions
|
|
104
|
-
*/
|
|
105
|
-
async function createMigrationScript() {
|
|
106
|
-
const migrationContent = `
|
|
107
|
-
-- Migration script for timezone support (Issue #246)
|
|
108
|
-
-- This script updates existing hive-mind sessions to support proper timezone display
|
|
109
|
-
|
|
110
|
-
-- Add new columns to sessions table
|
|
111
|
-
ALTER TABLE sessions ADD COLUMN created_at_local TEXT;
|
|
112
|
-
ALTER TABLE sessions ADD COLUMN timezone_name TEXT;
|
|
113
|
-
ALTER TABLE sessions ADD COLUMN timezone_offset REAL;
|
|
114
|
-
|
|
115
|
-
-- Update existing sessions with estimated local time
|
|
116
|
-
-- Note: This assumes UTC timestamps and will need manual adjustment
|
|
117
|
-
UPDATE sessions
|
|
118
|
-
SET
|
|
119
|
-
created_at_local = datetime(created_at, 'localtime'),
|
|
120
|
-
timezone_name = 'Local Time',
|
|
121
|
-
timezone_offset = 0
|
|
122
|
-
WHERE created_at_local IS NULL;
|
|
123
|
-
|
|
124
|
-
-- Create index for better performance
|
|
125
|
-
CREATE INDEX IF NOT EXISTS idx_sessions_created_at_local ON sessions(created_at_local);
|
|
126
|
-
CREATE INDEX IF NOT EXISTS idx_sessions_timezone ON sessions(timezone_name);
|
|
127
|
-
`;
|
|
128
|
-
|
|
129
|
-
const migrationPath = path.join(process.cwd(), 'migrations', 'fix-timezone-issue-246.sql');
|
|
130
|
-
await fs.mkdir(path.dirname(migrationPath), { recursive: true });
|
|
131
|
-
await fs.writeFile(migrationPath, migrationContent.trim());
|
|
132
|
-
|
|
133
|
-
console.log(`š Created migration script: ${migrationPath}`);
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
/**
|
|
137
|
-
* Test the timezone fix
|
|
138
|
-
*/
|
|
139
|
-
async function testTimezoneFix() {
|
|
140
|
-
console.log('\nš§Ŗ Testing timezone fix...\n');
|
|
141
|
-
|
|
142
|
-
// Import and test timezone utilities
|
|
143
|
-
try {
|
|
144
|
-
const { getLocalTimestamp, formatTimestampForDisplay, getTimezoneInfo } =
|
|
145
|
-
await import('../src/utils/timezone-utils.js');
|
|
146
|
-
|
|
147
|
-
const tz = getTimezoneInfo();
|
|
148
|
-
console.log(`š Current timezone: ${tz.name} (${tz.abbreviation})`);
|
|
149
|
-
console.log(`ā° UTC offset: ${tz.offset > 0 ? '+' : ''}${tz.offset} hours`);
|
|
150
|
-
|
|
151
|
-
const now = new Date();
|
|
152
|
-
const formatted = formatTimestampForDisplay(now);
|
|
153
|
-
console.log(`š
Current time: ${formatted.display}`);
|
|
154
|
-
|
|
155
|
-
// Simulate AEST timezone for the issue reporter
|
|
156
|
-
const aestTime = new Date(now.getTime() + (10 * 60 * 60 * 1000)); // UTC+10
|
|
157
|
-
console.log(`š¦šŗ AEST example: ${aestTime.toLocaleString('en-AU', { timeZone: 'Australia/Sydney' })}`);
|
|
158
|
-
|
|
159
|
-
console.log('\nā
Timezone fix is working correctly!');
|
|
160
|
-
|
|
161
|
-
} catch (error) {
|
|
162
|
-
console.error('ā Test failed:', error.message);
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
/**
|
|
167
|
-
* Main execution
|
|
168
|
-
*/
|
|
169
|
-
async function main() {
|
|
170
|
-
const args = process.argv.slice(2);
|
|
171
|
-
|
|
172
|
-
if (args.includes('--test')) {
|
|
173
|
-
await testTimezoneFix();
|
|
174
|
-
return;
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
if (args.includes('--migrate')) {
|
|
178
|
-
await createMigrationScript();
|
|
179
|
-
return;
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
console.log('š§ Claude Flow Timezone Fix (Issue #246)\n');
|
|
183
|
-
console.log('This script fixes the hive-mind creation time to show in user\'s local timezone.\n');
|
|
184
|
-
|
|
185
|
-
await applyTimezoneFixes();
|
|
186
|
-
await createMigrationScript();
|
|
187
|
-
|
|
188
|
-
console.log('\nš Next steps:');
|
|
189
|
-
console.log('1. Run: npm test to verify changes');
|
|
190
|
-
console.log('2. Apply database migration if you have existing sessions');
|
|
191
|
-
console.log('3. Test with: node scripts/fix-timezone-issue-246.js --test');
|
|
192
|
-
console.log('\nš” The fix ensures timestamps show in user\'s timezone (e.g., AEST for Australian users)');
|
|
193
|
-
}
|
|
194
|
-
|
|
195
|
-
// Run if called directly
|
|
196
|
-
if (import.meta.url === `file://${process.argv[1]}`) {
|
|
197
|
-
main().catch(console.error);
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
export { applyTimezoneFixes, testTimezoneFix, createMigrationScript };
|
|
@@ -1,182 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env python3
|
|
2
|
-
|
|
3
|
-
import os
|
|
4
|
-
import re
|
|
5
|
-
import subprocess
|
|
6
|
-
from typing import List, Tuple, Dict
|
|
7
|
-
from pathlib import Path
|
|
8
|
-
|
|
9
|
-
def fix_file(filepath: str) -> bool:
|
|
10
|
-
"""Fix common TypeScript errors in a file."""
|
|
11
|
-
try:
|
|
12
|
-
with open(filepath, 'r') as f:
|
|
13
|
-
content = f.read()
|
|
14
|
-
|
|
15
|
-
original_content = content
|
|
16
|
-
|
|
17
|
-
# Fix 1: Remove duplicate .js extensions
|
|
18
|
-
content = re.sub(r'\.js\.js', '.js', content)
|
|
19
|
-
|
|
20
|
-
# Fix 2: Fix incorrect constructor replacements
|
|
21
|
-
content = re.sub(r'\$1\$2override \$3\(', 'constructor(', content)
|
|
22
|
-
content = re.sub(r'constructor\(event: SwarmEvent\)', 'emitSwarmEvent(event: SwarmEvent)', content)
|
|
23
|
-
content = re.sub(r'constructor\(events: SwarmEvent\[\]\)', 'emitSwarmEvents(events: SwarmEvent[])', content)
|
|
24
|
-
content = re.sub(r'constructor\(type: EventType', 'onSwarmEvent(type: EventType', content)
|
|
25
|
-
content = re.sub(r'constructor\(predicate:', 'filterEvents(predicate:', content)
|
|
26
|
-
content = re.sub(r'constructor\(correlationId:', 'correlateEvents(correlationId:', content)
|
|
27
|
-
|
|
28
|
-
# Fix 3: Fix method signatures that should be methods, not constructors
|
|
29
|
-
if 'extends BaseAgent' in content:
|
|
30
|
-
# Fix executeTask method
|
|
31
|
-
content = re.sub(r'constructor\(task: TaskDefinition\)', 'override async executeTask(task: TaskDefinition)', content)
|
|
32
|
-
# Fix getAgentStatus method
|
|
33
|
-
content = re.sub(r'constructor\(\): any {', 'override getAgentStatus(): any {', content)
|
|
34
|
-
|
|
35
|
-
if 'class ResearchStrategy' in content:
|
|
36
|
-
# Fix decompose method
|
|
37
|
-
content = re.sub(r'constructor\(objective: SwarmObjective\): Promise<{', 'override async decompose(objective: SwarmObjective): Promise<{', content)
|
|
38
|
-
# Fix getMetrics method
|
|
39
|
-
content = re.sub(r'constructor\(\) {\n return {', 'getMetrics() {\n return {', content)
|
|
40
|
-
# Fix refineScope method
|
|
41
|
-
content = re.sub(r'constructor\(objective: SwarmObjective, intermediateResults:', 'async refineScope(objective: SwarmObjective, intermediateResults:', content)
|
|
42
|
-
# Fix Promise resolve/setTimeout patterns
|
|
43
|
-
content = re.sub(r'constructor\(\);', 'resolve();', content)
|
|
44
|
-
content = re.sub(r'constructor\(checkConnection', 'setTimeout(checkConnection', content)
|
|
45
|
-
content = re.sub(r'constructor\(config\);', 'super(config);', content)
|
|
46
|
-
content = re.sub(r'constructor\(config: Partial<SwarmConfig>', 'constructor(config: Partial<SwarmConfig>', content)
|
|
47
|
-
|
|
48
|
-
if 'class HttpTransport' in content:
|
|
49
|
-
# Fix interface methods
|
|
50
|
-
content = re.sub(r'constructor\(\): Promise<void> {', 'override async start(): Promise<void> {', content)
|
|
51
|
-
content = re.sub(r'constructor\(handler: RequestHandler\)', 'override onRequest(handler: RequestHandler)', content)
|
|
52
|
-
content = re.sub(r'constructor\(handler: NotificationHandler\)', 'override onNotification(handler: NotificationHandler)', content)
|
|
53
|
-
content = re.sub(r'constructor\(request: MCPRequest\)', 'override async sendRequest(request: MCPRequest)', content)
|
|
54
|
-
content = re.sub(r'constructor\(notification: MCPNotification\)', 'override async sendNotification(notification: MCPNotification)', content)
|
|
55
|
-
# Fix other methods that got incorrectly replaced
|
|
56
|
-
content = re.sub(r'constructor\(\): Promise<{', 'override async checkHealth(): Promise<{', content, count=1)
|
|
57
|
-
content = re.sub(r'constructor\(\);', 'resolve();', content)
|
|
58
|
-
|
|
59
|
-
# Find and fix specific async methods
|
|
60
|
-
lines = content.split('\n')
|
|
61
|
-
for i, line in enumerate(lines):
|
|
62
|
-
if i > 0 and 'constructor(): Promise<void>' in line and 'override' not in line:
|
|
63
|
-
# Check context to determine which method this should be
|
|
64
|
-
if 'stopping' in lines[i+2].lower():
|
|
65
|
-
lines[i] = line.replace('constructor(): Promise<void>', 'override async stop(): Promise<void>')
|
|
66
|
-
elif 'connect' in lines[i+2].lower() and 'disconnect' not in lines[i+2].lower():
|
|
67
|
-
lines[i] = line.replace('constructor(): Promise<void>', 'override async connect(): Promise<void>')
|
|
68
|
-
elif 'disconnect' in lines[i+2].lower():
|
|
69
|
-
lines[i] = line.replace('constructor(): Promise<void>', 'override async disconnect(): Promise<void>')
|
|
70
|
-
content = '\n'.join(lines)
|
|
71
|
-
|
|
72
|
-
# Fix 4: Add override modifiers to methods that need them
|
|
73
|
-
if 'extends BaseAgent' in content or 'extends BaseStrategy' in content:
|
|
74
|
-
# Find methods that likely need override
|
|
75
|
-
lines = content.split('\n')
|
|
76
|
-
for i, line in enumerate(lines):
|
|
77
|
-
# Check for async methods without override
|
|
78
|
-
if re.match(r'^\s+async\s+\w+\(', line) and 'override' not in line and 'constructor' not in line:
|
|
79
|
-
method_name = re.search(r'async\s+(\w+)\(', line)
|
|
80
|
-
if method_name:
|
|
81
|
-
name = method_name.group(1)
|
|
82
|
-
if name in ['executeTask', 'decompose', 'refineScope', 'start', 'stop', 'connect', 'disconnect']:
|
|
83
|
-
lines[i] = line.replace('async', 'override async')
|
|
84
|
-
# Check for non-async methods without override
|
|
85
|
-
elif re.match(r'^\s+(\w+)\(.*\):\s*\w+', line) and 'override' not in line and 'constructor' not in line:
|
|
86
|
-
method_name = re.search(r'(\w+)\(', line)
|
|
87
|
-
if method_name:
|
|
88
|
-
name = method_name.group(1)
|
|
89
|
-
if name in ['getAgentStatus', 'getMetrics', 'onRequest', 'onNotification']:
|
|
90
|
-
lines[i] = re.sub(r'^(\s+)', r'\1override ', line)
|
|
91
|
-
content = '\n'.join(lines)
|
|
92
|
-
|
|
93
|
-
# Fix 5: Fix array push operations on never[]
|
|
94
|
-
content = re.sub(r'\(\(([a-zA-Z0-9_]+) as any\[\]\)\.push\(', r'(\1 as any[]).push(', content)
|
|
95
|
-
|
|
96
|
-
# Fix 6: Fix specific type imports
|
|
97
|
-
if 'import type {' in content:
|
|
98
|
-
# Check if types are used as values
|
|
99
|
-
type_imports = re.findall(r'import type \{([^}]+)\}', content)
|
|
100
|
-
for imports in type_imports:
|
|
101
|
-
import_items = [item.strip() for item in imports.split(',')]
|
|
102
|
-
for item in import_items:
|
|
103
|
-
# Check if the type is used as a value (common patterns)
|
|
104
|
-
if re.search(rf'\b{item}\.', content) or re.search(rf'new {item}\b', content):
|
|
105
|
-
# Convert type import to regular import
|
|
106
|
-
content = re.sub(
|
|
107
|
-
rf'import type \{{([^}}]*\b{item}\b[^}}]*)\}}',
|
|
108
|
-
r'import {\1}',
|
|
109
|
-
content,
|
|
110
|
-
count=1
|
|
111
|
-
)
|
|
112
|
-
|
|
113
|
-
# Fix 7: Add missing imports for Node.js globals
|
|
114
|
-
if '__dirname' in content and 'fileURLToPath' not in content:
|
|
115
|
-
imports = [
|
|
116
|
-
"import { dirname } from 'node:path';",
|
|
117
|
-
"import { fileURLToPath } from 'node:url';",
|
|
118
|
-
"const __dirname = dirname(fileURLToPath(import.meta.url));"
|
|
119
|
-
]
|
|
120
|
-
lines = content.split('\n')
|
|
121
|
-
# Find the first import or the beginning of the file
|
|
122
|
-
insert_index = 0
|
|
123
|
-
for i, line in enumerate(lines):
|
|
124
|
-
if line.startswith('import'):
|
|
125
|
-
insert_index = i
|
|
126
|
-
break
|
|
127
|
-
lines[insert_index:insert_index] = imports
|
|
128
|
-
content = '\n'.join(lines)
|
|
129
|
-
|
|
130
|
-
if original_content != content:
|
|
131
|
-
with open(filepath, 'w') as f:
|
|
132
|
-
f.write(content)
|
|
133
|
-
return True
|
|
134
|
-
return False
|
|
135
|
-
except Exception as e:
|
|
136
|
-
print(f"Error processing {filepath}: {e}")
|
|
137
|
-
return False
|
|
138
|
-
|
|
139
|
-
def main():
|
|
140
|
-
"""Main function to fix TypeScript errors."""
|
|
141
|
-
print("š§ Starting comprehensive TypeScript fixes...")
|
|
142
|
-
|
|
143
|
-
# Find all TypeScript files
|
|
144
|
-
ts_files = []
|
|
145
|
-
for root, dirs, files in os.walk('src'):
|
|
146
|
-
for file in files:
|
|
147
|
-
if file.endswith('.ts'):
|
|
148
|
-
ts_files.append(os.path.join(root, file))
|
|
149
|
-
|
|
150
|
-
print(f"š Found {len(ts_files)} TypeScript files")
|
|
151
|
-
|
|
152
|
-
# Fix files
|
|
153
|
-
fixed_count = 0
|
|
154
|
-
for filepath in ts_files:
|
|
155
|
-
if fix_file(filepath):
|
|
156
|
-
fixed_count += 1
|
|
157
|
-
|
|
158
|
-
print(f"ā
Fixed {fixed_count} files")
|
|
159
|
-
|
|
160
|
-
# Run build to check remaining errors
|
|
161
|
-
print("\nš§ Running TypeScript build to check remaining errors...")
|
|
162
|
-
result = subprocess.run(['npm', 'run', 'build:ts'], capture_output=True, text=True)
|
|
163
|
-
|
|
164
|
-
# Count errors
|
|
165
|
-
error_count = len([line for line in result.stderr.split('\n') if 'error TS' in line])
|
|
166
|
-
print(f"\nš Remaining errors: {error_count}")
|
|
167
|
-
|
|
168
|
-
# Show error summary
|
|
169
|
-
if error_count > 0:
|
|
170
|
-
error_types = {}
|
|
171
|
-
for line in result.stderr.split('\n'):
|
|
172
|
-
match = re.search(r'error TS(\d+):', line)
|
|
173
|
-
if match:
|
|
174
|
-
code = f"TS{match.group(1)}"
|
|
175
|
-
error_types[code] = error_types.get(code, 0) + 1
|
|
176
|
-
|
|
177
|
-
print("\nš Error summary:")
|
|
178
|
-
for code, count in sorted(error_types.items(), key=lambda x: x[1], reverse=True)[:10]:
|
|
179
|
-
print(f" {code}: {count} errors")
|
|
180
|
-
|
|
181
|
-
if __name__ == "__main__":
|
|
182
|
-
main()
|