You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Static code analysis examines code without execution, identifying potential issues like bugs, security vulnerabilities, and style violations. It improves software quality by early issue detection, creating better maintainability, and providing enhanced security.
Each programming language has its own unique syntax and semantics. Therefore, effective static code analysis requires tools specifically designed for the language being analyzed. These tools leverage the language's specific characteristics to perform more in-depth and accurate analysis.
Existing static code analysis tools like SonarQube rely on these language-specific code analyzers to extract information and report issues.
This effort focuses on developing a Ballerina tool to perform static code analysis based on sets of rules and report analysis issues to various static code analysis platforms.
Implementations for static code analysis support for Ballerina have already been created in ballerina-scan-tool repository and changes are steadily being ported to static-code-analysis-tool
Several class-loader-related issues that prevent casting objects passed from Ballerina tools to compiler plugins have been addressed:
Identified and sent a PR to fix a workflow and test misconfigurations in the setup-ballerina action which prevents installation of the latest Ballerina version for Windows builds:
Demonstrations for creating a static analysis compiler plugin and a static code analysis platform plugin to extend the scan tools capabilities has been made.
The ruleKind attribute expected in the compiler plugins rules.json file has been changed to kind.
Description
Static code analysis examines code without execution, identifying potential issues like bugs, security vulnerabilities, and style violations. It improves software quality by early issue detection, creating better maintainability, and providing enhanced security.
Each programming language has its own unique syntax and semantics. Therefore, effective static code analysis requires tools specifically designed for the language being analyzed. These tools leverage the language's specific characteristics to perform more in-depth and accurate analysis.
Existing static code analysis tools like SonarQube rely on these language-specific code analyzers to extract information and report issues.
This effort focuses on developing a Ballerina tool to perform static code analysis based on sets of rules and report analysis issues to various static code analysis platforms.
Contains steps to Implement #42256
Describe your task(s)
Implementing a Ballerina static-code-analysis-tool
[Phase 1] Creating the core analyzer:
Implement core analyzer with analysis report generation. Tracked in Add core scan tool implementation static-code-analysis-tool#4
Implement HTML report generation. Tracked in Add HTML static code analysis report generation static-code-analysis-tool#9
Implement core rule: identify usage of checkpanic keyword. Tracked in Add core rule implementation for checkpanic static-code-analysis-tool#10
Implement
Scan.toml
based scan tool behavior configuration. Tracked in Add support for loading scan tool configuration files static-code-analysis-tool#11Scan.toml
file[Phase 2] Introduce extension points for the core analyzer
Implement extension for supporting additional analysis capabilities of scan tool via compiler plugins. Tracked in Add support for loading static analyzer plugins static-code-analysis-tool#15
Implement:
[Phase 3] Implement additional Ballerina rules
Implementing Ballerina analysis issues reporting support for SonarQube via creating the sonar-ballerina plugin:
Related area
-> Other Area
Related issue(s) (optional)
No response
Suggested label(s) (optional)
No response
Suggested assignee(s) (optional)
No response
The text was updated successfully, but these errors were encountered: