Open carmelotony opened 4 years ago
Looks like with the last update of @ExpDev07 this package start return wrong data :(
@bkawakami @carmelotony Per JHU's recent announcement (the main data provider), they will:
If you specify csbs
as source you can retrieve US-specific data (including states and counties).
Relevant: https://github.com/ExpDev07/coronavirus-tracker-api/issues/161.
@bkawakami @carmelotony Per JHU's recent announcement (the main data provider), they will:
- Not provide data on recoveries.
- Drop province-level data and focus on countries as a whole.
If you specify
csbs
as source you can retrieve US-specific data (including states and counties).Relevant: ExpDev07/coronavirus-tracker-api#161.
Do I need to up date the package getting? Getting this error when passing csbs
init() got an unexpected keyword argument 'data_source'
Passed "csbs" instead of data_source = "csbs" and it made the connections... However, after trying to retrieve data got the following error...
Invalid URL 'csbs/v2/locations': No schema supplied. Perhaps you meant http://csbs/v2/locations?
The source needs to be passed as a query param. /v2/locations?source=csbs @carmelotony
@carmelotony the first argument it gets is the URL, that's why it tries to retrieve data from csbs/v2/locations
.
Try using COVID19(data_source="csbs")
instead. 🙂
@carmelotony the first argument it gets is the URL, that's why it tries to retrieve data from
csbs/v2/locations
.Try using
COVID19(data_source="csbs")
instead. 🙂
@Kamaropoulos
getting this error...
TypeError Traceback (most recent call last)
Probably need to update your deps.
@carmelotony the first argument it gets is the URL, that's why it tries to retrieve data from
csbs/v2/locations
. Try usingCOVID19(data_source="csbs")
instead. 🙂@Kamaropoulos
getting this error...
TypeError Traceback (most recent call last) in 1 #creat covid19 instance ----> 2 covid19 = COVID19Py.COVID19(data_source="csbs")
TypeError: init() got an unexpected keyword argument 'data_source'
Weird, I had it happen once while testing this out but now I can't reproduce it, it worked fine when I tried it again 🤔
@carmelotony the first argument it gets is the URL, that's why it tries to retrieve data from
csbs/v2/locations
. Try usingCOVID19(data_source="csbs")
instead. 🙂@Kamaropoulos getting this error... TypeError Traceback (most recent call last) in 1 #creat covid19 instance ----> 2 covid19 = COVID19Py.COVID19(data_source="csbs") TypeError: init() got an unexpected keyword argument 'data_source'
Weird, I had it happen once while testing this out but now I can't reproduce it, it worked fine when I tried it again 🤔
Just upgraded to version 0.3.0, but still the same error...
@carmelotony what's your platform and Python version?
@carmelotony what's your platform and Python version?
window 10 conda 3.8
Executing the following use to return timelines for all locations within the country 'US'.
get locations data
locations = covid19.getLocationByCountryCode("US", timelines = True)
Now it returns only 'US' totals without the 'province' data...
"[{'coordinates': {'latitude': '37.0902', 'longitude': '-95.7129'}, 'country': 'US', 'country_code': 'US', 'id': 225, 'last_updated': '2020-03-24T20:41:02.216348Z', 'latest': {'confirmed': 43847, 'deaths': 557, 'recovered': 0}, 'province': '', 'timelines': {'confirmed': {'latest': 43847, 'timeline': {'2020-01-22T00:00:00Z': 1, '2020-01-23T00:00:00Z': 1, '2020-01-24T00:00:00Z': 2,...."