aboutcode-org / aboutcode-org/vulnerablecode

fix: Remove unnecessary f-string prefix in vulnrichment.py

Offen
#2,072 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
Python
Sterne
702
Forks
328
Ø Merge
3 T. 8 Std.
Gemergte PRs (30 T.)
3

Beschreibung

## Summary

The file [vulnerabilities/importers/vulnrichment.py](cci:7://file:///D:/Projects2.0/Gsoc/vulnerablecode/vulnerabilities/importers/vulnrichment.py:0:0-0:0) contains an f-string without any placeholders at line 32, which violates ruff rule F541.

## Problem

Using `f"..."` syntax without any `{variable}` placeholders inside is:
- Unnecessary overhead (f-strings are marginally slower than regular strings)
- Misleading to readers who expect interpolation
- A code quality issue flagged by linters

## Location

**File:** [vulnerabilities/importers/vulnrichment.py](cci:7://file:///D:/Projects2.0/Gsoc/vulnerablecode/vulnerabilities/importers/vulnrichment.py:0:0-0:0)
**Line:** 32
**Current code:**
```python
for file_path in base_path.glob(f"**/**/*.json"):

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.