Skip to content
This repository has been archived by the owner on Oct 15, 2024. It is now read-only.

Commit

Permalink
distutils removed from standard lib
Browse files Browse the repository at this point in the history
  • Loading branch information
chrstnbwnkl committed Jun 21, 2024
1 parent b21603b commit ce97cae
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion valhalla/valhalla_build_config.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,20 @@
#!/usr/bin/env python3
from argparse import ArgumentParser, ArgumentTypeError, ArgumentDefaultsHelpFormatter
from distutils.util import strtobool
import json
from typing import List, Union



def strtobool(value):
lower = str(value).lower()
if lower in {'y', 'yes', 't', 'true', 'on', '1'}:
return True
elif lower in {'n', 'no', 'f', 'false', 'off', '0'}:
return False
else:
raise ValueError('"{}" is not a valid bool value'.format(value))


class Optional:
def __init__(self, t=None):
self.type = t
Expand Down

0 comments on commit ce97cae

Please sign in to comment.