Skip to content

Commit 10bc3f4

Browse files
committed
style: Add nosec comments to ignore bandit warnings
1 parent c0034e2 commit 10bc3f4

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

src/git_changelog/build.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import sys
44
from datetime import datetime
5-
from subprocess import check_output
5+
from subprocess import check_output # nosec
66

77
from .providers import GitHub, GitLab
88
from .style import AngularStyle, AtomStyle, BasicStyle, CommitStyle
@@ -205,7 +205,7 @@ def __init__(self, repository, provider=None, style=None):
205205

206206
def get_remote_url(self):
207207
git_url = (
208-
check_output(["git", "config", "--get", "remote.origin.url"], cwd=self.repository)
208+
check_output(["git", "config", "--get", "remote.origin.url"], cwd=self.repository) # nosec
209209
.decode("utf-8")
210210
.rstrip("\n")
211211
)
@@ -216,9 +216,9 @@ def get_remote_url(self):
216216
return git_url
217217

218218
def get_log(self):
219-
return check_output(["git", "log", "--date=unix", "--format=" + self.FORMAT], cwd=self.repository).decode(
220-
"utf-8"
221-
)
219+
return check_output(
220+
["git", "log", "--date=unix", "--format=" + self.FORMAT], cwd=self.repository # nosec
221+
).decode("utf-8")
222222

223223
def parse_commits(self):
224224
lines = self.raw_log.split("\n")

src/git_changelog/templates/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ def get_path():
99

1010

1111
def get_env(path):
12-
return Environment(loader=FileSystemLoader(path))
12+
return Environment(loader=FileSystemLoader(path)) # nosec
1313

1414

1515
def get_custom_template(path):

0 commit comments

Comments
 (0)