question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

default config file name

See original GitHub issue

Is your feature request related to a problem? Please describe. The doc say i should create a YAML config file, but not how to name it. https://bandit.readthedocs.io/en/latest/config.html

Describe the solution you’d like Please recommend a sane default name, so it is consistent in any project and can be found by CI etc.

I recommend using .bandit.yml because it is hidden on Linux, UNIX and macOS and has an extension.

Describe alternatives you’ve considered I don’t see any alternatives. Leaving it as is leads to chaos!

Additional context Codacy says: “You can also use custom .bandit or bandit.yml config file.” I have also seen bandit.yaml in earlier issues.

For a sane solution, i look what similar tools do.

Most .name for INI-style config or .name.yml for YAML config.

pylintrc or .pylintrc: https://pylint.readthedocs.io/en/latest/user_guide/run.html#command-line-options

.flake8

.pycodestyle or config in setup.cfg or tox.ini: http://pycodestyle.pycqa.org/en/latest/intro.html#configuration

.pydocstyle, .pydocstyle.ini, .pydocstylerc, .pydocstylerc.ini: http://www.pydocstyle.org/en/2.1.1/usage.html#configuration-files

.coveragerc

.travis.yml, .circleci, .github, .appveyor.yml

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:13
  • Comments:20 (8 by maintainers)

github_iconTop GitHub Comments

9reactions
bittnercommented, Mar 14, 2019

I’d prefer to see a [bandit] section read from my tox.ini file, as do other tools (like pytest, flake8, behave, etc.), which can help to reduce clutter in Python projects.

Also, the options available in a configuration file need to be fully documented, ideally also printed by the CLI --help option (or so). See also #396.

6reactions
jdrownecommented, Jan 26, 2021

Bump. As of this writing, documentation does not say the config file must be explicitly set via -c.

Read more comments on GitHub >

github_iconTop Results From Across the Web

What's the standard config file name and extension in Python?
Ok, I've asked around where I work and researched a little, and this is what I've come up with as suggestions: settings.
Read more >
git-config Documentation - Git
The file /etc/gitconfig can be used to store a system-wide default configuration. The configuration variables are used by both the Git plumbing and...
Read more >
Configuration file - Wikipedia
In computing, configuration files are files used to configure the parameters and initial settings for some computer programs.
Read more >
What is configuration file? | Definition from TechTarget
Configuration files go by many names. Plain text configuration files used in Linux environments have filename extensions such as .cnf, .conf, .cfg, .cf, ......
Read more >
Setting Defaults for I/O Driver Configuration File Name and Path
To set the default configuration file name and change the default path: · From the Options menu, choose Setup. The Setup dialog box...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found