Skip to content
This repository has been archived by the owner on Jan 8, 2023. It is now read-only.

Commit

Permalink
Remove use of deprecated distutils (#114)
Browse files Browse the repository at this point in the history
  • Loading branch information
ssbarnea authored Apr 1, 2022
1 parent 9377bff commit b95047c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/molecule_podman/driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@

from __future__ import absolute_import

import distutils.spawn
import os
import warnings
from shutil import which
from typing import Dict

from ansible_compat.ports import cache
Expand Down Expand Up @@ -170,7 +170,7 @@ def __init__(self, config=None):
def podman_cmd(self):
"""Lazily calculate the podman command."""
if not self._podman_cmd:
self._podman_cmd = distutils.spawn.find_executable(self.podman_exec)
self._podman_cmd = which(self.podman_exec)
if not self._podman_cmd:
msg = f"command not found in PATH {self.podman_exec}"
util.sysexit_with_message(msg)
Expand Down

0 comments on commit b95047c

Please sign in to comment.