raystack / raystack/frontier

proposal: add more linters and fix existing issues

Open
#1,583 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Go
Stars
344
Forks
47
Avg merge
4d 4h
Merged PRs (30d)
26

Description

Summary

Add the following linters to improve code quality, security, and maintainability:

  • gocognit
  • gosec
  • staticcheck
  • errcheck

Currently, gosec is only using rules G201 and G202. Existing issues from other relevant rules also need to be identified and fixed.

Why this is useful

Adding these linters will help catch issues earlier in development and reduce the chances of bugs or security problems reaching production.

gocognit
  • Detects functions with high cognitive complexity
  • Helps keep code easier to read, review, test, and maintain
  • Encourages simpler control flow and clearer logic
gosec
  • Detects insecure coding patterns
  • Helps identify issues beyond G201 and G202
  • Improves security by catching risky patterns early in CI and local development
staticcheck
  • Finds correctness, performance, and code quality issues
  • Detects ineffective assignments, broken assumptions, deprecated usage, and other subtle problems
  • Improves overall reliability of the codebase
errcheck
  • Ensures returned errors are not ignored
  • Helps prevent silent failures and inconsistent behavior
  • Encourages explicit and reliable error handling

Expected benefits

  • Catch bugs earlier in CI
  • Improve security posture
  • Make the codebase easier to maintain and refactor
  • Standardize code quality checks across the repository

Scope

  • Add the new linters to the linting pipeline
  • Expand gosec coverage beyond G201 and G202
  • Fix the issues reported by the newly enabled checks

Notes

These linters will help make the code more secure and less complex to read.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the repository's linting pipeline configuration and running the existing checks to understand the current setup. Add gocognit, gosec, staticcheck, and errcheck, expand gosec beyond G201 and G202, then resolve the issues reported by the enabled checks.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
ci-cd, security, tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.