Skip to content

Commit

Permalink
Remove type | type
Browse files Browse the repository at this point in the history
  • Loading branch information
janbridley committed May 22, 2024
1 parent 855f2c5 commit 60fcbe7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion parsnip/_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ def _str2num(val: str):
return float(val) if "." in val else int(val)


def _deg2rad(val: float | int):
def _deg2rad(val: float):
"""Convert a value in degrees to one in radians."""
return val * np.pi / 180
4 changes: 2 additions & 2 deletions parsnip/parse.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def read_table(
keep_original_key_order: bool = False,
cast_to_float: bool = False,
nondelimiting_whitespace_replacement: str = "_",
regex_filter: tuple | None = None,
regex_filter: tuple = None,
) -> np.ndarray:
r"""Extract data from a CIF file loop\_ table.
Expand Down Expand Up @@ -230,7 +230,7 @@ def _parsed_line_generator(filename, regexp):

def read_key_value_pairs(
filename: str,
keys: tuple | None = None,
keys: tuple = None,
only_read_numerics: bool = False,
):
"""Extract key-value pairs from a CIF file.
Expand Down

0 comments on commit 60fcbe7

Please sign in to comment.