Skip to content

Commit 68b43d8

Browse files
committed
TST: test_read_famafrench fails with HTTP 404
1 parent c740bb0 commit 68b43d8

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

doc/source/whatsnew/v0.17.0.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -327,3 +327,5 @@ Bug Fixes
327327
- Bug in ``Series.plot(kind='hist')`` Y Label not informative (:issue:`10485`)
328328

329329
- Bug in operator equal on Index not being consistent with Series (:issue:`9947`)
330+
331+
- Reading "famafrench" data via ``DataReader`` results in HTTP 404 error because of the website url is changed (:issue:`10591`).

pandas/io/data.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -504,7 +504,7 @@ def fetch_data(url, name):
504504

505505
def get_data_famafrench(name):
506506
# path of zip files
507-
zip_file_path = '{0}/{1}.zip'.format(_FAMAFRENCH_URL, name)
507+
zip_file_path = '{0}/{1}_TXT.zip'.format(_FAMAFRENCH_URL, name)
508508

509509
with urlopen(zip_file_path) as url:
510510
raw = url.read()

pandas/io/tests/test_data.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -481,8 +481,6 @@ def test_read_famafrench(self):
481481
for name in ("F-F_Research_Data_Factors",
482482
"F-F_Research_Data_Factors_weekly", "6_Portfolios_2x3",
483483
"F-F_ST_Reversal_Factor", "F-F_Momentum_Factor"):
484-
raise nose.SkipTest('getting 404 errors as of 7/15/15')
485-
486484
ff = DataReader(name, "famafrench")
487485
self.assertTrue(ff is not None)
488486
self.assertIsInstance(ff, dict)

0 commit comments

Comments
 (0)