Skip to content

Commit

Permalink
Ensure the requirements-frozen.txt file is deleted after it is read
Browse files Browse the repository at this point in the history
  • Loading branch information
nickmoreton committed Dec 19, 2024
1 parent 0f6cabd commit bb4115a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/check_local.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,11 @@ def check_local(path: str, report: bool) -> None:

# process the requirements-frozen.txt file as a FrozenParser object
# it's used to lookup the package name and version installed in the docker image
frozen = TextParser(pathlib.Path(repository_manager.get_repo_dir / "requirements-frozen.txt").absolute())
requirements_file = pathlib.Path(repository_manager.get_repo_dir / "requirements-frozen.txt").absolute()
frozen = TextParser(requirements_file)

# delete the requirements-frozen.txt file
requirements_file.unlink()

# process the pyproject.toml file as a TomlParser object
# it's used to lookup the package name and version specified in the pyproject.toml file
Expand Down

0 comments on commit bb4115a

Please sign in to comment.