feat: update error handling to use %w for wrapping errors in multiple files#39
Merged
feat: update error handling to use %w for wrapping errors in multiple files#39
Conversation
…ple files Signed-off-by: CFC4N <cfc4n.cs@gmail.com>
…stency Signed-off-by: CFC4N <cfc4n.cs@gmail.com>
… files Signed-off-by: CFC4N <cfc4n.cs@gmail.com>
…owser_debugger.go Signed-off-by: CFC4N <cfc4n.cs@gmail.com>
…or improved clarity Signed-off-by: CFC4N <cfc4n.cs@gmail.com>
…arity in multiple files Signed-off-by: CFC4N <cfc4n.cs@gmail.com>
…arity in root.go, server.go, and server_test.go Signed-off-by: CFC4N <cfc4n.cs@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces several changes to improve code quality, enhance maintainability, and update dependencies across multiple files. Key updates include upgrading the
golangci-lintaction version, adopting modern Go conventions (e.g., replacinginterface{}withany), improving error handling, and refining configurations for linters and formatting tools.Dependency Updates:
.github/workflows/go-test.yml: Upgradedgolangci-lint-actionfrom versionv6tov8for better compatibility and features. Updated linter arguments to specifyversion: v2.1.Code Quality Improvements:
cli/cmd/config.go,cli/cmd/root.go,client/client.go,pkg/config/config.go: Replacedinterface{}withanyacross multiple files to align with modern Go conventions. Improved error messages by using%wfor wrapping errors instead of%v. [1] [2] [3] [4] [5]Configuration Enhancements:
.golangci.yml: Added a detailed configuration file forgolangci-lint, enabling specific linters (errcheck,staticcheck,errorlint) and excluding irrelevant paths likedist/anddocs/. Introduced custom formatter settings forgofmtandgoimports.Bug Fixes:
pkg/server/server.go: Fixed incorrect variable usage (%minstead of%s) in logging statements for the SSE server. Ensured proper handling of server configurations and logging.Code Organization:
cli/cmd/client.go,cli/cmd/config.go,cli/cmd/root.go, etc.): Reorganized import statements for better readability and consistency by grouping standard library, third-party, and project-specific imports. [1] [2] [3]