Skip to content

Commit

Permalink
add type annotation to utility functions
Browse files Browse the repository at this point in the history
  • Loading branch information
bernt-matthias committed Feb 19, 2024
1 parent 09a5732 commit 73708f9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/galaxy/util/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1139,7 +1139,7 @@ def commaify(amount):
return commaify(new)


def trailing_zeros_to_powerof10(amount):
def trailing_zeros_to_powerof10(amount: int):
"""
>>> trailing_zeros_to_powerof10(23000)
'23000'
Expand Down Expand Up @@ -1168,7 +1168,7 @@ def trailing_zeros_to_powerof10(amount):
return f"{amount[: i+1]}\u22C510^{zeros}"


def roundify(amount, sfs=2):
def roundify(amount: int, sfs: int = 2):
"""
Take a number and round it to 'sfs' significant figures.
Expand Down

0 comments on commit 73708f9

Please sign in to comment.