-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
from argparse_dataclass import dataclass
from argparse_dataclass import ArgumentParser
@dataclass
class SubOption:
a: int = 1
b: int = 2
@dataclass
class Options:
x: int = 42
y: bool = False
sub: SubOption = None
parser = ArgumentParser(Options)
x = parser.parse_args(['--sub', '1'])
print(x)
for example, how can I parse args to get a value for sub?
Metadata
Metadata
Assignees
Labels
No labels