Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Different check profiles/configuration for different parts a repository #5

Closed
clebergnu opened this issue Feb 20, 2024 · 1 comment
Closed
Assignees

Comments

@clebergnu
Copy link
Contributor

For some projects, it may be undesirable to have a single configuration being applied to the entire code base.

Using the autils repository as an example, APIs in the utility modules that will be made public should require docstrings for the module, methods and functions. This is unfair to ask for the modules/classes/methods/functions that implement tests for a given module, as it would require too much boilerplate code just to conform with a lint check.

The idea here is to allow the static-checks to map a pattern or glob to a given configuration. For instance:

  • autils/*: default_config/pylintrc
  • tests/*: default_config/pylintrc_tests

The check-lint script should have the ability to look into the parent repository and look for the mapping. Example:

 [autils] $ ls -la1
 ...
 autils
 tests
 static-checks
 .avocado_static_checks.conf
 ...

With .avocado_static_checks.conf containing something like:

[lint]
autils: default_config/pylintrc
tests: default_config/pylintrc_tests

In the absence of such a config file, check-lint should apply a reasonable action, using the default config on all Python files.

@mr-avocado mr-avocado bot moved this to Triage in Default project Feb 20, 2024
@richtja richtja moved this from Triage to Short Term (Current Q) Backlog in Default project Feb 20, 2024
@richtja richtja assigned richtja and harvey0100 and unassigned richtja May 15, 2024
@richtja
Copy link
Contributor

richtja commented Sep 2, 2024

Resolved in #8

@richtja richtja closed this as completed Sep 2, 2024
@github-project-automation github-project-automation bot moved this from Short Term (Current Q) Backlog to Done 108 in Default project Sep 2, 2024
@richtja richtja moved this from Done 108 to Done 107 in Default project Sep 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done 109
Development

No branches or pull requests

3 participants