diff --git a/CHANGELOG.md b/CHANGELOG.md index e4fa5543..be629287 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to GoSQLX will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.10.3] - 2026-03-14 — LSP --stdio compatibility + +### Fixed +- Accept --stdio flag in gosqlx lsp command (required by vscode-languageclient) +- Allow empty executablePath in config validation (uses bundled binary fallback) + ## [1.10.2] - 2026-03-14 — VS Code Extension Fix ### Fixed diff --git a/cmd/gosqlx/cmd/doc.go b/cmd/gosqlx/cmd/doc.go index f972fca6..86a281c0 100644 --- a/cmd/gosqlx/cmd/doc.go +++ b/cmd/gosqlx/cmd/doc.go @@ -341,7 +341,7 @@ // // Version information: // -// Version = "1.10.2" - Current CLI version +// Version = "1.10.3" - Current CLI version // // # Dependencies // diff --git a/cmd/gosqlx/cmd/root.go b/cmd/gosqlx/cmd/root.go index bfc79a24..273aa2cf 100644 --- a/cmd/gosqlx/cmd/root.go +++ b/cmd/gosqlx/cmd/root.go @@ -28,12 +28,12 @@ import ( // This version tracks feature releases and compatibility. // Format: MAJOR.MINOR.PATCH (Semantic Versioning 2.0.0) // -// Version 1.10.2 includes: +// Version 1.10.3 includes: // - MCP Server: All GoSQLX SQL capabilities as Model Context Protocol tools over streamable HTTP // - 7 MCP tools: validate_sql, format_sql, parse_sql, extract_metadata, security_scan, lint_sql, analyze_sql // - Optional bearer token auth via GOSQLX_MCP_AUTH_TOKEN // - Go minimum bumped to 1.23.0 (required by mark3labs/mcp-go) -var Version = "1.10.2" +var Version = "1.10.3" var ( // verbose enables detailed output for debugging and troubleshooting. @@ -121,7 +121,7 @@ Key features: • CI/CD integration with proper exit codes Performance: 1.5M+ operations/second sustained, 1.97M peak. 100-1000x faster than competitors.`, - Version: "1.10.2", + Version: "1.10.3", } // Execute adds all child commands to the root command and sets flags appropriately. diff --git a/cmd/gosqlx/doc.go b/cmd/gosqlx/doc.go index eca1fb73..abba80a9 100644 --- a/cmd/gosqlx/doc.go +++ b/cmd/gosqlx/doc.go @@ -24,7 +24,7 @@ // // # Version // -// Current version: 1.10.2 +// Current version: 1.10.3 // // # Architecture // diff --git a/cmd/gosqlx/internal/lspcmd/lsp.go b/cmd/gosqlx/internal/lspcmd/lsp.go index 0942f780..77258096 100644 --- a/cmd/gosqlx/internal/lspcmd/lsp.go +++ b/cmd/gosqlx/internal/lspcmd/lsp.go @@ -28,6 +28,7 @@ import ( var ( lspLogFile string + lspStdio bool ) // NewCmd returns the lsp cobra.Command. @@ -77,6 +78,7 @@ Emacs Integration (lsp-mode): } cmd.Flags().StringVar(&lspLogFile, "log", "", "Log file path (optional, for debugging)") + cmd.Flags().BoolVar(&lspStdio, "stdio", false, "Use stdio transport (default, accepted for compatibility with vscode-languageclient)") return cmd } diff --git a/doc.go b/doc.go index 1046ba8a..3d868534 100644 --- a/doc.go +++ b/doc.go @@ -16,7 +16,7 @@ // zero-copy tokenization and comprehensive object pooling. It offers enterprise-grade SQL lexing, // parsing, and AST generation with support for multiple SQL dialects and advanced SQL features. // -// GoSQLX v1.10.2 includes both a powerful Go SDK and a high-performance CLI tool for SQL processing, +// GoSQLX v1.10.3 includes both a powerful Go SDK and a high-performance CLI tool for SQL processing, // validated for production deployment with race-free concurrent operation and extensive real-world testing. // // Production Status: VALIDATED FOR PRODUCTION DEPLOYMENT (v1.6.0+) @@ -278,7 +278,7 @@ // // # Version History // -// v1.10.2: VS Code Marketplace publishing with bundled platform-specific binaries +// v1.10.3: VS Code Marketplace publishing with bundled platform-specific binaries // v1.10.0: MCP Server — all SQL tools as Model Context Protocol tools over streamable HTTP // v1.9.0: SQLite PRAGMA, tautology detection, 19 post-UAT fixes // v1.8.0: Multi-dialect engine, query transforms, WASM playground, AST-to-SQL roundtrip diff --git a/llms.txt b/llms.txt index c909b53a..5e30cd10 100644 --- a/llms.txt +++ b/llms.txt @@ -7,7 +7,7 @@ recursive-descent parsing, and AST generation with comprehensive object pooling. PostgreSQL, MySQL, SQL Server, Oracle, SQLite, and Snowflake dialects, and ships a full-featured CLI tool (`gosqlx`) for validation, formatting, linting, and security analysis. Apache-2.0 licensed. -Current stable version: v1.10.2 (2026-03-13) +Current stable version: v1.10.3 (2026-03-13) ## Core API diff --git a/performance_baselines.json b/performance_baselines.json index 650b7941..04f29917 100644 --- a/performance_baselines.json +++ b/performance_baselines.json @@ -1,5 +1,5 @@ { - "version": "1.10.2", + "version": "1.10.3", "updated": "2026-03-13", "baselines": { "SimpleSelect": { diff --git a/pkg/gosqlx/gosqlx.go b/pkg/gosqlx/gosqlx.go index e5ac934f..6d383843 100644 --- a/pkg/gosqlx/gosqlx.go +++ b/pkg/gosqlx/gosqlx.go @@ -28,7 +28,7 @@ import ( ) // Version is the current GoSQLX library version. -const Version = "1.10.2" +const Version = "1.10.3" // Parse tokenizes and parses SQL in one call, returning an Abstract Syntax Tree (AST). // diff --git a/pkg/mcp/server.go b/pkg/mcp/server.go index 394cdfce..2768f0d0 100644 --- a/pkg/mcp/server.go +++ b/pkg/mcp/server.go @@ -35,7 +35,7 @@ func New(cfg *Config) *Server { s := &Server{cfg: cfg} s.mcpSrv = mcpserver.NewMCPServer( "gosqlx-mcp", - "1.10.2", + "1.10.3", mcpserver.WithToolCapabilities(false), ) s.registerTools() diff --git a/vscode-extension/CHANGELOG.md b/vscode-extension/CHANGELOG.md index f933eeab..38cc2515 100644 --- a/vscode-extension/CHANGELOG.md +++ b/vscode-extension/CHANGELOG.md @@ -2,6 +2,12 @@ All notable changes to the "GoSQLX" extension will be documented in this file. +## [1.10.3] - 2026-03-14 + +### Fixed +- LSP server now accepts --stdio flag from vscode-languageclient +- Empty executablePath no longer triggers validation warning + ## [1.10.2] - 2026-03-14 ### Fixed diff --git a/vscode-extension/package-lock.json b/vscode-extension/package-lock.json index 4d39d8b3..60db52dc 100644 --- a/vscode-extension/package-lock.json +++ b/vscode-extension/package-lock.json @@ -1,6 +1,6 @@ { "name": "gosqlx", - "version": "1.10.2", + "version": "1.10.3", "lockfileVersion": 3, "requires": true, "packages": { diff --git a/vscode-extension/package.json b/vscode-extension/package.json index 16aec729..e07e96cd 100644 --- a/vscode-extension/package.json +++ b/vscode-extension/package.json @@ -2,7 +2,7 @@ "name": "gosqlx", "displayName": "GoSQLX", "description": "High-performance SQL parsing, validation, formatting, and analysis powered by GoSQLX", - "version": "1.10.2", + "version": "1.10.3", "publisher": "ajitpratap0", "license": "Apache-2.0", "repository": { diff --git a/vscode-extension/src/test/unit/commands.test.ts b/vscode-extension/src/test/unit/commands.test.ts index 38e509f7..59ae4905 100644 --- a/vscode-extension/src/test/unit/commands.test.ts +++ b/vscode-extension/src/test/unit/commands.test.ts @@ -357,8 +357,8 @@ function validateDialect(dialect: string): ValidationResult { } function validateExecutablePath(path: string): ValidationResult { - if (!path || path.trim().length === 0) { - return { valid: false, message: 'Executable path cannot be empty' }; + if (typeof path !== 'string') { + return { valid: false, message: 'Executable path must be a string' }; } return { valid: true }; } diff --git a/vscode-extension/src/test/unit/validation.test.ts b/vscode-extension/src/test/unit/validation.test.ts index 63ca2d3e..d783981d 100644 --- a/vscode-extension/src/test/unit/validation.test.ts +++ b/vscode-extension/src/test/unit/validation.test.ts @@ -226,10 +226,9 @@ suite('Executable Path Validation Edge Cases', () => { assert.strictEqual(result.valid, true); }); - test('should reject empty string', () => { + test('should accept empty string (uses bundled binary or PATH fallback)', () => { const result = validateExecutablePath(''); - assert.strictEqual(result.valid, false); - assert.ok(result.message?.includes('empty')); + assert.strictEqual(result.valid, true); }); test('should reject whitespace-only string', () => { @@ -637,12 +636,9 @@ function validateExecutablePath(execPath: unknown): ValidationResult { const trimmed = execPath.trim(); + // Empty string is valid — means "use bundled binary or PATH fallback" if (trimmed.length === 0) { - return { - valid: false, - message: 'Executable path cannot be empty', - suggestion: 'Set to "gosqlx" to use PATH lookup' - }; + return { valid: true }; } if (trimmed.includes(' ') || trimmed.includes('\n') || trimmed.includes('\t')) { diff --git a/vscode-extension/src/utils/validation.ts b/vscode-extension/src/utils/validation.ts index 43970ddc..16412827 100644 --- a/vscode-extension/src/utils/validation.ts +++ b/vscode-extension/src/utils/validation.ts @@ -89,12 +89,9 @@ export function validateExecutablePath(execPath: unknown): ValidationResult { const trimmed = execPath.trim(); + // Empty string is valid — means "use bundled binary or PATH fallback" if (trimmed.length === 0) { - return { - valid: false, - message: 'Executable path cannot be empty', - suggestion: 'Set to "gosqlx" to use PATH lookup, or provide full path' - }; + return { valid: true }; } // Check for suspicious characters that might indicate a typo