Karan6124 commited on
Commit
2ab5afb
·
1 Parent(s): 49ee3b1

fix: resolve GraphQL Int overflow on large historical volumes

Browse files

- Change the olume type from int to loat in StockHistoryType and StockTickType in schema.py to prevent 32-bit signed integer serialization limits from throwing errors on large volume assets (e.g. BTC-USD max range).

Files changed (1) hide show
  1. backend/app/graphql/schema.py +2 -2
backend/app/graphql/schema.py CHANGED
@@ -58,13 +58,13 @@ class StockHistoryType:
58
  high: float
59
  low: float
60
  close: float
61
- volume: int
62
 
63
  @strawberry.type
64
  class StockTickType:
65
  ticker: str
66
  price: float
67
- volume: int
68
  timestamp: str
69
 
70
  @strawberry.type
 
58
  high: float
59
  low: float
60
  close: float
61
+ volume: float
62
 
63
  @strawberry.type
64
  class StockTickType:
65
  ticker: str
66
  price: float
67
+ volume: float
68
  timestamp: str
69
 
70
  @strawberry.type