man-c / pycoingecko

Python wrapper for the CoinGecko API
MIT License
1.04k stars 268 forks source link

Twitter Followers and other community data retrning as 'None' #34

Closed topchatz closed 3 years ago

topchatz commented 3 years ago

Hi guys, love the wrapper.

I'm getting None back for some coins community data even though there is real data on the website.

Simplest example would be for Polkadot say.

dict = cg.get_coin_history_by_id('polkadot', '08-04-2021')['community_data']

I'm getting None for 'twitter_followers' , but if you check the website https://www.coingecko.com/en/coins/polkadot#social you see there is 275K.

Is there a way to get the actual followers instead of just None?

Cheers

man-c commented 3 years ago

Hi!

It seems to work fine for me.

>>> dict=cg.get_coin_history_by_id('polkadot', '08-04-2021')
>>> dict['community_data']['twitter_followers']
278390

All the community data it returns:

>>> dict['community_data']
{'facebook_likes': None, 'twitter_followers': 278390, 'reddit_average_posts_48h': 1.667, 
'reddit_average_comments_48h': 31.917, 'reddit_subscribers': 21154, 
'reddit_accounts_active_48h': '221.846153846154'}

Cheers!

man-c commented 3 years ago

I checked it again and still works fine for me, so I am closing the issue. Let me know if you still have same issue.

Cheers