Skip to content

Commit 849bd30

Browse files
authored
Merge pull request #21 from ai-forever/lysenko_type
fix typehinting
2 parents 65e5ba7 + b60118f commit 849bd30

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

DPF/dataset_reader.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
)
1414

1515

16-
def help_reader(filesystem: FileSystem, required_columns: Optional[list[str]], path: str):
16+
def help_reader(filesystem: FileSystem, required_columns: Optional[List[str]], path: str):
1717
df = filesystem.read_dataframe(path)
1818

1919
if required_columns:

DPF/processors/processor.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ def to_sharded_files(
170170
max_files_in_shard: int = 1000,
171171
datafiles_ext: str = "csv",
172172
meta_columns: Optional[List[str]] = None,
173-
keys_mapping: Optional[dict[str, str]] = None,
173+
keys_mapping: Optional[Dict[str, str]] = None,
174174
workers: int = 8,
175175
pbar: bool = True
176176
):
@@ -196,7 +196,7 @@ def to_shards(
196196
datafiles_ext: str = "csv",
197197
archives_ext: Optional[str] = "tar",
198198
meta_columns: Optional[List[str]] = None,
199-
keys_mapping: Optional[dict[str, str]] = None,
199+
keys_mapping: Optional[Dict[str, str]] = None,
200200
workers: int = 8,
201201
pbar: bool = True
202202
):

DPF/processors/writers/sharded_files_writer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def __init__(
1818
self,
1919
filesystem: FileSystem,
2020
destination_dir: str,
21-
keys_mapping: Optional[dict[str, str]] = None,
21+
keys_mapping: Optional[Dict[str, str]] = None,
2222
max_files_in_shard: int = 1000,
2323
datafiles_ext: str = "csv",
2424
) -> None:

DPF/processors/writers/shards_writer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ def __init__(
2020
self,
2121
filesystem: FileSystem,
2222
destination_dir: str,
23-
keys_mapping: Optional[dict[str, str]] = None,
23+
keys_mapping: Optional[Dict[str, str]] = None,
2424
max_files_in_shard: Optional[int] = 1000,
2525
datafiles_ext: Optional[str] = "csv",
2626
archives_ext: Optional[str] = "tar",

0 commit comments

Comments
 (0)