Skip to content

Commit

Permalink
Replace logger.warn w/ logger.warning (#476)
Browse files Browse the repository at this point in the history
* Ruff corrections G010

* Correct comment

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
zklaus and pre-commit-ci[bot] committed Jun 11, 2024
1 parent ae01d70 commit 3d5c620
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion conda_libmamba_solver/conda_build_exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@ def __init__(self, matchspecs=None, explanation=None, *args, **kwargs):
def __str__(self) -> str:
msg = self.message
if not self.explanation:
# print simple message in log.warn() calls
# print simple message in log.warning() calls
return msg
return "\n".join([msg, self.explanation])
4 changes: 3 additions & 1 deletion conda_libmamba_solver/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,9 @@ def _json_path_to_repo_info(
solv_stat = None

if solv_stat is None and json_stat is None:
log.warn("No repodata found for channel %s. Solve will fail.", channel.canonical_name)
log.warning(
"No repodata found for channel %s. Solve will fail.", channel.canonical_name
)
return
if solv_stat is None:
path_to_use = json_path
Expand Down
2 changes: 1 addition & 1 deletion conda_libmamba_solver/solver.py
Original file line number Diff line number Diff line change
Expand Up @@ -829,7 +829,7 @@ def _export_solved_records(
out_state.records.pop(name, None)
break
else:
log.warn("Tried to unlink %s but it is not installed or manageable?", filename)
log.warning("Tried to unlink %s but it is not installed or manageable?", filename)

for_conda_build = self._called_from_conda_build()
for channel, filename, json_payload in to_link:
Expand Down

0 comments on commit 3d5c620

Please sign in to comment.