Browse Source

Try #2 in codacy ai reviewer

Signed-off-by: Robin Getz <rgetz503@gmail.com>
chirpmodem-v8.0.0
Robin Getz 2 months ago
parent
commit
8b2895a350
No known key found for this signature in database
GPG Key ID: 51C7231FFED0E060
  1. 16
      .codacy/instructions/review.md

16
.codacy/instructions/review.md

@ -12,10 +12,15 @@ Cover:
- **Relevant code structure**: Identify the classes, interfaces, directories, message types, queues, build files, generated code, or other components that matter to the PR. Do not describe unrelated parts of the repository. - **Relevant code structure**: Identify the classes, interfaces, directories, message types, queues, build files, generated code, or other components that matter to the PR. Do not describe unrelated parts of the repository.
- **Inheritance and existing infrastructure**: Before reporting missing functionality in a derived class, inspect its base classes and inherited methods, slots, signals, constructors, and established initialization paths. Do not request derived-class implementations when the required behavior is already provided by inherited code.
- **Relevant dependencies and tooling**: Mention Qt, CMake, external libraries, hardware APIs, generated code, CI, static analysis, sanitizers, or other tooling only when relevant to the PR. - **Relevant dependencies and tooling**: Mention Qt, CMake, external libraries, hardware APIs, generated code, CI, static analysis, sanitizers, or other tooling only when relevant to the PR.
- **Testing and validation**: Describe appropriate validation for the actual changes. Directed manual testing using SDRangel, relevant features, devices, or hardware is valid. Do not suggest automated checks such as compilation, CI, cppcheck, Coverity, OpenGrep, or sanitizers. - **Testing and validation**: SDRangel does not have an established unit-test or automated regression-test framework for its DSP, device, channel, feature, or GUI code. Do not request, recommend, or criticize a PR for missing unit tests, regression tests, test fixtures, or new test infrastructure. Do not turn manual validation requirements into requests to write automated tests. Compilation, CI, cppcheck, Coverity, OpenGrep, sanitizers, and similar automated checks are not testing recommendations for the PR review. Instead, identify appropriate directed manual validation for the actual changes, using SDRangel, relevant features, devices, signal sources, hardware, WebAPI, or existing operational workflows as appropriate. Manual test scenarios are valid review guidance; requests to implement those scenarios as automated tests are not.
Do not assume unit tests are required. SDRangel does not have an established general unit-testing practice. Prefer the project's existing validation methods, including directed manual testing where appropriate.
- **Testing expectations**: Review whether the changed behavior can be meaningfully validated through the project's existing manual testing practices. The absence of an automated test framework is not a deficiency and must not be presented as a reason to add one. When validation is relevant, describe the concrete manual scenario to perform rather than suggesting automated test development.
- **No automated-test recommendations**: Never add a “Test suggestions” section recommending unit tests, regression tests, automated verification, test harnesses, or new testing infrastructure for SDRangel source changes. If validation is appropriate, describe the concrete **manual test scenario** the contributor or reviewer should perform instead. For example, say “Manually verify VHF DSC demodulation with 1300/2100 Hz tones” rather than “Unit test VHF DSC demodulation.” Do not convert each manual validation scenario into a separate automated-test recommendation.
- **Relevant conventions and pitfalls**: Identify established SDRangel conventions and concrete risks relevant to the changed code, such as thread/lifetime races, message ownership, queue handling, startup/shutdown ordering, Qt ownership, DSP/device lifecycle, settings serialization, API compatibility, generated code, or CMake dependencies. Only include issues relevant to the PR. - **Relevant conventions and pitfalls**: Identify established SDRangel conventions and concrete risks relevant to the changed code, such as thread/lifetime races, message ownership, queue handling, startup/shutdown ordering, Qt ownership, DSP/device lifecycle, settings serialization, API compatibility, generated code, or CMake dependencies. Only include issues relevant to the PR.
@ -25,15 +30,20 @@ Cover:
- **Generated and third-party code**: Identify generated, vendored, or externally maintained code relevant to the PR. Do not apply normal SDRangel source-review expectations to such code unless the PR intentionally modifies or integrates it. - **Generated and third-party code**: Identify generated, vendored, or externally maintained code relevant to the PR. Do not apply normal SDRangel source-review expectations to such code unless the PR intentionally modifies or integrates it.
- **Out of scope**: Identify things the reviewer should not flag for this PR. Do not request unrelated refactoring, broad modernization, new abstractions, architectural redesign, or generic best-practice changes. Do not flag missing unit tests when they are not an established requirement for the affected code. - **Out of scope**: Do not request unrelated refactoring, broad modernization, new abstractions, architectural redesign, new automated tests, new test infrastructure, or generic best-practice changes. Do not flag missing unit or regression tests when they are not an established requirement for the affected code.
Rules:
Rules: Rules:
- Output only the Markdown content, with no preamble or explanation. - Output only the Markdown content, with no preamble or explanation.
- Be concise. Every line should earn its place. - Be concise. Every line should earn its place.
- Prefer concrete, actionable findings tied to changed code over speculative concerns or hypothetical future problems. - Prefer concrete, actionable findings tied to changed code over speculative concerns or hypothetical future problems.
- Use short sections and bullets. - Use short sections and bullets.
- Make the result specific to reviewing this PR, not a generic SDRangel architecture document. - Make the result specific to reviewing this PR, not a generic SDRangel architecture document.
- Before reporting a defect involving an existing class, method, or API, inspect its implementation and relevant callers when necessary to establish its actual behavior. Follow relevant ownership, lifetime, locking, cleanup, synchronization, inheritance, virtual methods, signals, slots, and initialization paths outside the diff. Do not infer behavior or missing functionality from method names, types, or changed code alone.
- Review changed code in the context of the actual repository implementation, including code outside the PR when it defines the behavior of changed code. Use that code to determine whether the PR introduces a defect, but do not report unrelated pre-existing issues.
- Base statements on actual repository code, documentation, and established project practices. - Base statements on actual repository code, documentation, and established project practices.
- Do not invent requirements or impose generic software-engineering practices. - Do not invent requirements or impose generic software-engineering practices.
- Do not recommend or request automated tests, unit tests, regression tests, test harnesses, or new test infrastructure. SDRangel does not have an automated test framework, and the absence of one is not a defect or a review finding.
- Never add a generic “Test suggestions” section solely because a PR lacks automated tests.
- Omit sections that are not relevant to the PR. - Omit sections that are not relevant to the PR.
- When code and documentation disagree, do not assume the code is wrong. Treat the discrepancy as a documentation issue unless there is independent evidence of a code defect. - When code and documentation disagree, do not assume the code is wrong. Treat the discrepancy as a documentation issue unless there is independent evidence of a code defect.

Loading…
Cancel
Save