Fixed #32355 -- Dropped support for Python 3.6 and 3.7

This commit is contained in:
Mariusz Felisiak 2021-01-19 08:35:16 +01:00 committed by Carlton Gibson
parent 9c6ba87692
commit ec0ff40631
33 changed files with 59 additions and 274 deletions

View file

@ -1,11 +1,9 @@
from django.core.management.base import BaseCommand
from django.utils.version import PY37
class Command(BaseCommand):
def add_arguments(self, parser):
kwargs = {'required': True} if PY37 else {}
subparsers = parser.add_subparsers(dest='subcommand', **kwargs)
subparsers = parser.add_subparsers(dest='subcommand', required=True)
parser_foo = subparsers.add_parser('foo')
parser_foo.add_argument('--bar')