From d447f4cb9455db73fab6aa35639f3652eb5c8034 Mon Sep 17 00:00:00 2001 From: Nathan Woodburn Date: Tue, 10 Dec 2024 15:05:37 +1100 Subject: [PATCH] fix: Round defi in pie chart --- cache/1981e30de11cf0845e8b5affb4dc75e0.json | 2 +- cache/1ccff5c6f117409fea0c861aa44b8e62.json | 2 +- cache/29409a8a40dd2d547a7a44b8f6758f54.json | 2 +- cache/4104ed0427efe63d4ca0dead970a4391.json | 2 +- cache/46c1ec7f5edb30c070003dc54e072f41.json | 2 +- cache/598f5dbf97fb0d45cbc6e1a5b0a3b575.json | 2 +- cache/6cc6c6a0b2d0654f551d33209c1fd824.json | 2 +- cache/6eec370e2713cfc84c84e1080b8a191a.json | 2 +- cache/790b28a9a21cf694ad9577ef1072ac9e.json | 2 +- cache/a099e7e540e16a185b0279b9494e5099.json | 2 +- cache/a0ee60913ba556f39d128e7d7249e788.json | 2 +- cache/c652e896f57f598d23e3dbebdb815ef6.json | 2 +- cache/ccf2a009e56f1b05d471a55d9c9ea8ea.json | 2 +- cache/d4e81748ee91683b2c48adaa5cf95187.json | 2 +- server.py | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/cache/1981e30de11cf0845e8b5affb4dc75e0.json b/cache/1981e30de11cf0845e8b5affb4dc75e0.json index d41a24b..6248e29 100644 --- a/cache/1981e30de11cf0845e8b5affb4dc75e0.json +++ b/cache/1981e30de11cf0845e8b5affb4dc75e0.json @@ -1 +1 @@ -{"timestamp": 1733799272.475875, "result": 3736.24} \ No newline at end of file +{"timestamp": 1733802901.543576, "result": 3686.92} \ No newline at end of file diff --git a/cache/1ccff5c6f117409fea0c861aa44b8e62.json b/cache/1ccff5c6f117409fea0c861aa44b8e62.json index b32088b..8198a15 100644 --- a/cache/1ccff5c6f117409fea0c861aa44b8e62.json +++ b/cache/1ccff5c6f117409fea0c861aa44b8e62.json @@ -1 +1 @@ -{"timestamp": 1733799395.870956, "result": 1.003} \ No newline at end of file +{"timestamp": 1733803481.9402199, "result": 0.983585} \ No newline at end of file diff --git a/cache/29409a8a40dd2d547a7a44b8f6758f54.json b/cache/29409a8a40dd2d547a7a44b8f6758f54.json index 51ec562..0130dac 100644 --- a/cache/29409a8a40dd2d547a7a44b8f6758f54.json +++ b/cache/29409a8a40dd2d547a7a44b8f6758f54.json @@ -1 +1 @@ -{"timestamp": 1733799333.3207755, "result": 4.19} \ No newline at end of file +{"timestamp": 1733802965.079247, "result": 4.18} \ No newline at end of file diff --git a/cache/4104ed0427efe63d4ca0dead970a4391.json b/cache/4104ed0427efe63d4ca0dead970a4391.json index f2a7ba6..94695e1 100644 --- a/cache/4104ed0427efe63d4ca0dead970a4391.json +++ b/cache/4104ed0427efe63d4ca0dead970a4391.json @@ -1 +1 @@ -{"timestamp": 1733799270.0382683, "result": 229.01} \ No newline at end of file +{"timestamp": 1733802900.2143283, "result": 227.64} \ No newline at end of file diff --git a/cache/46c1ec7f5edb30c070003dc54e072f41.json b/cache/46c1ec7f5edb30c070003dc54e072f41.json index ed61687..e4460d3 100644 --- a/cache/46c1ec7f5edb30c070003dc54e072f41.json +++ b/cache/46c1ec7f5edb30c070003dc54e072f41.json @@ -1 +1 @@ -{"timestamp": 1733799334.021167, "result": 3.73} \ No newline at end of file +{"timestamp": 1733802949.2840338, "result": 3.7} \ No newline at end of file diff --git a/cache/598f5dbf97fb0d45cbc6e1a5b0a3b575.json b/cache/598f5dbf97fb0d45cbc6e1a5b0a3b575.json index f633583..ad53842 100644 --- a/cache/598f5dbf97fb0d45cbc6e1a5b0a3b575.json +++ b/cache/598f5dbf97fb0d45cbc6e1a5b0a3b575.json @@ -1 +1 @@ -{"timestamp": 1733799267.6918225, "result": 216.09} \ No newline at end of file +{"timestamp": 1733803481.5865438, "result": 214.86} \ No newline at end of file diff --git a/cache/6cc6c6a0b2d0654f551d33209c1fd824.json b/cache/6cc6c6a0b2d0654f551d33209c1fd824.json index c45abd8..7287874 100644 --- a/cache/6cc6c6a0b2d0654f551d33209c1fd824.json +++ b/cache/6cc6c6a0b2d0654f551d33209c1fd824.json @@ -1 +1 @@ -{"timestamp": 1733799334.533264, "result": 3.89} \ No newline at end of file +{"timestamp": 1733802950.081187, "result": 3.81} \ No newline at end of file diff --git a/cache/6eec370e2713cfc84c84e1080b8a191a.json b/cache/6eec370e2713cfc84c84e1080b8a191a.json index 44ceddc..c673103 100644 --- a/cache/6eec370e2713cfc84c84e1080b8a191a.json +++ b/cache/6eec370e2713cfc84c84e1080b8a191a.json @@ -1 +1 @@ -{"timestamp": 1733801798.1054318, "result": 503.668701194} \ No newline at end of file +{"timestamp": 1733803490.0428967, "result": 524.668701194} \ No newline at end of file diff --git a/cache/790b28a9a21cf694ad9577ef1072ac9e.json b/cache/790b28a9a21cf694ad9577ef1072ac9e.json index 27a7727..54ff805 100644 --- a/cache/790b28a9a21cf694ad9577ef1072ac9e.json +++ b/cache/790b28a9a21cf694ad9577ef1072ac9e.json @@ -1 +1 @@ -{"timestamp": 1733799267.2864535, "result": 0.034115022} \ No newline at end of file +{"timestamp": 1733803481.1301713, "result": 0.055522424} \ No newline at end of file diff --git a/cache/a099e7e540e16a185b0279b9494e5099.json b/cache/a099e7e540e16a185b0279b9494e5099.json index f5e9246..8da54c7 100644 --- a/cache/a099e7e540e16a185b0279b9494e5099.json +++ b/cache/a099e7e540e16a185b0279b9494e5099.json @@ -1 +1 @@ -{"timestamp": 1733799270.8399568, "result": 97397} \ No newline at end of file +{"timestamp": 1733802902.292282, "result": 96653} \ No newline at end of file diff --git a/cache/a0ee60913ba556f39d128e7d7249e788.json b/cache/a0ee60913ba556f39d128e7d7249e788.json index 07fd3a1..edf6545 100644 --- a/cache/a0ee60913ba556f39d128e7d7249e788.json +++ b/cache/a0ee60913ba556f39d128e7d7249e788.json @@ -1 +1 @@ -{"timestamp": 1733801769.2307105, "result": [{"mint": "3NZ9JMVBmGAqocybic2c7LQCJScmgsAZ6vQqTDzcqmJh", "balance": 0.00056828, "price": 97397, "value": 55.34876716, "name": "Wrapped BTC (Wormhole)", "symbol": "wbtc"}, {"mint": "27G8MtK7VtTcCHkpASjSDdkWWYfoqT6ggEuKidVJidD4", "balance": 19.88979, "price": 4.19, "value": 83.33822010000002, "name": "Jupiter Perpetuals Liquidity Provider Token", "symbol": "jlp"}, {"mint": "jupSoLaHXQiZZTSfEWMTRRgpnyFm8f6sZdosWBjx93v", "balance": 0.239815492, "price": 229.01, "value": 54.92014582292, "name": "Jupiter Staked SOL", "symbol": "jupsol"}, {"mint": "7vfCXTUXx5WJV5JADk17DUJ4ksgau7utNKj4b963voxs", "balance": 0.00255735, "price": 3736.24, "value": 9.554873363999999, "name": "Ethereum (Wormhole)", "symbol": "eth"}, {"mint": "9gP2kCy3wA1ctvYWQk75guqXuHfrEomqydHLtcTCqiLa", "balance": 0.03683279, "price": 677.73, "value": 24.9626867667, "name": "Binance Coin (Wormhole)", "symbol": "bnb"}, {"mint": "0x2::sui::SUI", "balance": 0.902850107, "price": 3.73, "value": 3.36763089911, "name": "Sui", "symbol": "sui"}, {"mint": "0x549e8b69270defbfafd4f94e17ec44cdbdd99820b33bda2278dea3b9a32d3f55::cert::CERT", "balance": 22.852920128, "price": 3.89, "value": 88.89785929792001, "name": "Volo Staked SUI", "symbol": "vsui"}]} \ No newline at end of file +{"timestamp": 1733803478.87206, "result": [{"mint": "27G8MtK7VtTcCHkpASjSDdkWWYfoqT6ggEuKidVJidD4", "balance": 19.88979, "price": 4.18, "value": 83.1393222, "name": "Jupiter Perpetuals Liquidity Provider Token", "symbol": "jlp"}, {"mint": "3NZ9JMVBmGAqocybic2c7LQCJScmgsAZ6vQqTDzcqmJh", "balance": 0.00056828, "price": 96653, "value": 54.92596684, "name": "Wrapped BTC (Wormhole)", "symbol": "wbtc"}, {"mint": "jupSoLaHXQiZZTSfEWMTRRgpnyFm8f6sZdosWBjx93v", "balance": 0.239815492, "price": 227.64, "value": 54.59159859888, "name": "Jupiter Staked SOL", "symbol": "jupsol"}, {"mint": "9gP2kCy3wA1ctvYWQk75guqXuHfrEomqydHLtcTCqiLa", "balance": 0.03683279, "price": 677.73, "value": 24.9626867667, "name": "Binance Coin (Wormhole)", "symbol": "bnb"}, {"mint": "7vfCXTUXx5WJV5JADk17DUJ4ksgau7utNKj4b963voxs", "balance": 0.00255735, "price": 3686.92, "value": 9.428744862, "name": "Ethereum (Wormhole)", "symbol": "eth"}, {"mint": "0x2::sui::SUI", "balance": 0.902850107, "price": 3.7, "value": 3.3405453959, "name": "Sui", "symbol": "sui"}, {"mint": "0x549e8b69270defbfafd4f94e17ec44cdbdd99820b33bda2278dea3b9a32d3f55::cert::CERT", "balance": 22.852920128, "price": 3.81, "value": 87.06962568768, "name": "Volo Staked SUI", "symbol": "vsui"}]} \ No newline at end of file diff --git a/cache/c652e896f57f598d23e3dbebdb815ef6.json b/cache/c652e896f57f598d23e3dbebdb815ef6.json index aaebc0c..8eeac8e 100644 --- a/cache/c652e896f57f598d23e3dbebdb815ef6.json +++ b/cache/c652e896f57f598d23e3dbebdb815ef6.json @@ -1 +1 @@ -{"timestamp": 1733801799.938006, "result": [{"mint": "0x2::sui::SUI", "balance": 0.902850107, "price": 3.73, "value": 3.36763089911, "name": "Sui", "symbol": "sui"}, {"mint": "0x549e8b69270defbfafd4f94e17ec44cdbdd99820b33bda2278dea3b9a32d3f55::cert::CERT", "balance": 22.852920128, "price": 3.89, "value": 88.89785929792001, "name": "Volo Staked SUI", "symbol": "vsui"}]} \ No newline at end of file +{"timestamp": 1733803493.5146375, "result": [{"mint": "0x2::sui::SUI", "balance": 0.902850107, "price": 3.7, "value": 3.3405453959, "name": "Sui", "symbol": "sui"}, {"mint": "0x549e8b69270defbfafd4f94e17ec44cdbdd99820b33bda2278dea3b9a32d3f55::cert::CERT", "balance": 22.852920128, "price": 3.81, "value": 87.06962568768, "name": "Volo Staked SUI", "symbol": "vsui"}]} \ No newline at end of file diff --git a/cache/ccf2a009e56f1b05d471a55d9c9ea8ea.json b/cache/ccf2a009e56f1b05d471a55d9c9ea8ea.json index 75a43f7..2706405 100644 --- a/cache/ccf2a009e56f1b05d471a55d9c9ea8ea.json +++ b/cache/ccf2a009e56f1b05d471a55d9c9ea8ea.json @@ -1 +1 @@ -{"timestamp": 1733801766.3602786, "result": 82.815227} \ No newline at end of file +{"timestamp": 1733803490.063623, "result": 82.815227} \ No newline at end of file diff --git a/cache/d4e81748ee91683b2c48adaa5cf95187.json b/cache/d4e81748ee91683b2c48adaa5cf95187.json index c23badc..599a2b6 100644 --- a/cache/d4e81748ee91683b2c48adaa5cf95187.json +++ b/cache/d4e81748ee91683b2c48adaa5cf95187.json @@ -1 +1 @@ -{"timestamp": 1733801788.785157, "result": [{"name": "Kamino USDC Lending", "description": "Kamino USDC Lending", "apy": 26.85, "url": "https://app.kamino.finance/lending/reserve/DxXdAyU3kCjnyggvHmY5nAwg5cRbbmdyX3npfDMjjMek/Ga4rZytCpq1unD4DbEJ5bkHeUz9g3oh9AAFEi6vSauXp", "value": 50.01, "updated": "1733790668", "initial": 50, "bought": "1733717057", "type": "Lending"}, {"name": "dYdX MegaVault", "description": "dYdX MegaVault", "apy": 46, "url": "https://dydx.trade/vault", "value": 23.43, "updated": "1733790645", "initial": 23, "bought": "1733300000", "type": "Lending"}]} \ No newline at end of file +{"timestamp": 1733803494.5449908, "result": [{"name": "Kamino USDC Lending", "description": "Kamino USDC Lending", "apy": 26.85, "url": "https://app.kamino.finance/lending/reserve/DxXdAyU3kCjnyggvHmY5nAwg5cRbbmdyX3npfDMjjMek/Ga4rZytCpq1unD4DbEJ5bkHeUz9g3oh9AAFEi6vSauXp", "value": 50.01, "updated": "1733790668", "initial": 50, "bought": "1733717057", "type": "Lending"}, {"name": "dYdX MegaVault", "description": "dYdX MegaVault", "apy": 55, "url": "https://dydx.trade/vault", "value": 44.45, "updated": "1733790645", "initial": 44, "bought": "1733300000", "type": "Lending"}]} \ No newline at end of file diff --git a/server.py b/server.py index e2d01d3..97d8130 100644 --- a/server.py +++ b/server.py @@ -597,7 +597,7 @@ def api_vault(): "description": other_investment_types[investment_type]["description"], "value": other_investment_types[investment_type]["value"], "amount": other_investment_types[investment_type]["amount"], - "tooltip": f"{other_investment_types[investment_type]['amount']} Positions (${other_investment_types[investment_type]['value']})" + "tooltip": f"{other_investment_types[investment_type]['amount']} Positions (${'{:.2f}'.format(other_investment_types[investment_type]['value'])})" }