baseline not working
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 8.3k
- Forks
- 835
- Avg merge
- 5d 3h
- Merged PRs (30d)
- 1
Description
Is your feature request related to a problem? Please describe.
The baseline file generated by bandit uses relative paths as it should. This way the code can be moved to another location.
However bandit takes these paths relative to the current working folder. Bandit can therefore only be executed in the folder that it was in when the baseline was generated. This is very confusing. Using the baseline must be possible from any folder.
Describe the solution you'd like
The baseline file must work when bandit is executed from any folder.
Describe alternatives you've considered
This can be accomplished by taking the paths in the baseline relative to the folder holding the baseline in stead of the current working folder.
Additional context
bandit 1.7.0
python version = 3.7.7 (tags/v3.7.7:d7c567b08f, Mar 10 2020, 09:44:33) [MSC v.1900 32 bit (Intel)]
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue does not name a file or test. Start by locating Bandit's baseline loading and path-handling entry points, then reproduce running Bandit from a different working directory than the baseline file. Done means the same baseline works regardless of the current working folder, with coverage for that behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- security, tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100