Skip to content

Commit

Permalink
fix: type hint was wrong type in dx data generator
Browse files Browse the repository at this point in the history
Better type hinting support means this was now actually triggering an error. However, it is currently returning numpy types, which is a bug in core. Initial random.seed(seed) now prints this error, and is expected to be fixed in next release.

> DeprecationWarning: Seeding based on hashing is deprecated
since Python 3.9 and will be removed in a subsequent version. The only
supported seed types are: None, int, float, str, bytes, and bytearray.

See: deephaven/deephaven-core#4933
  • Loading branch information
dsmmcken committed Dec 11, 2023
1 parent 229280d commit 794748f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ def random_list_sym(seed: int) -> str:
def random_list_exchange(seed: int) -> str:
return random.choices(exchange, exchange_weights)[0]

def random_trade_size(rand: int) -> int:
def random_trade_size(rand: float) -> int:
"""
Random distribution of trade size, approximately mirroring market data
"""
Expand Down

0 comments on commit 794748f

Please sign in to comment.