Skip to content

Commit 2b86f67

Browse files
authored
Merge pull request #670 from econdb/master
Correct EcondbReader's API URL format
2 parents 6a9068f + 19f7f40 commit 2b86f67

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

pandas_datareader/econdb.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
import requests
44
import pandas as pd
55

6-
76
from pandas_datareader.base import _BaseReader
87

98

@@ -17,10 +16,10 @@ class EcondbReader(_BaseReader):
1716
@property
1817
def url(self):
1918
"""API URL"""
20-
if not isinstance(self.symbols, string_types):
19+
if not isinstance(self.symbols, str):
2120
raise ValueError('data name must be string')
2221

23-
return ('{0}?{1}&format=json&page_size=500&expand=meta'
22+
return ('{0}?{1}&format=json&page_size=500&expand=both'
2423
.format(self._URL, self.symbols))
2524

2625
def read(self):

pandas_datareader/tests/test_econdb.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ def test_get_tourism(self):
4242
df = df.astype(np.float)
4343
jp = np.array([8351000, 6790000, 8611000, 6219000,
4444
8368000], dtype=float)
45-
us = np.array([175702309, 160507417, 164079732, 167600277,
46-
171320408], dtype=float)
45+
us = np.array([175702304, 160507424, 164079728, 167600272,
46+
171320416], dtype=float)
4747
index = pd.date_range('2008-01-01', '2012-01-01', freq='AS',
4848
name='TIME_PERIOD')
4949

0 commit comments

Comments
 (0)