Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some trading pairs cannot be decoded #104

Open
miohtama opened this issue Jul 6, 2023 · 0 comments
Open

Some trading pairs cannot be decoded #104

miohtama opened this issue Jul 6, 2023 · 0 comments

Comments

@miohtama
Copy link
Contributor

miohtama commented Jul 6, 2023

Fixing pair decoding if there are NaN values from the server.

DataDecodeFailed: Could not decode trading pair data:
 {'address': '0x0d4a11d5eeaac28ec3f61d100daf4d40471f1852',
 'base_token_symbol': 'WETH',
 'buy_count_30d': 26040.0,
 'buy_count_all_time': 2556015.0,
 'buy_tax': 0.0,
 'buy_volume_30d': 41786724.0,
 'buy_volume_all_time': 19510417408.0,
 'chain_id': 1,
 'dex_type': 'uniswap_v2',
 'exchange_address': '0x5c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f',
 'exchange_id': 1,
 'exchange_slug': 'uniswap-v2',
 'fee': 30,
 'first_swap_at': nan,
 'first_swap_at_block_number': nan,
 'flag_blacklisted_manually': None,
 'flag_inactive': None,
 'flag_unknown_exchange': None,
 'flag_unsupported_quote_token': None,
 'last_swap_at': nan,
 'last_swap_at_block_number': nan,
 'pair_id': 239,
 'pair_slug': 'eth-usdt',
 'quote_token_symbol': 'USDT',
 'sell_count_30d': 20645.0,
 'sell_count_all_time': 2432864.0,
 'sell_tax': 0.0,
 'sell_volume_30d': 41309184.0,
 'sell_volume_all_time': 19360479232.0,
 'token0_address': '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2',
 'token0_decimals': 18,
 'token0_symbol': 'WETH',
 'token1_address': '0xdac17f958d2ee523a2206206994597c13d831ec7',
 'token1_decimals': 6,
 'token1_symbol': 'USDT',
 'transfer_tax': 0.0}
miohtama added a commit that referenced this issue Jul 6, 2023
- Workaround pair data issues when Parquest is interpreting some values as NaN when should be None
- Might be related to Parquest data format and somehow values get misinterpreted when written or read
- #104
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant