PythonDataScienceHandbook icon indicating copy to clipboard operation
PythonDataScienceHandbook copied to clipboard

Update 03.10-Working-With-Strings.ipynb notebook to use local data dump of last known dump file.

Open andrewm4894 opened this issue 4 years ago • 0 comments

It seems like the data used in this notebook (pulled in via curl) has gone away (its just an empty file as their export process broke and they did not have time/resources to fix it).

http://openrecipes.s3.amazonaws.com/recipeitems-latest.json.gz

This issue seems to suggest that last known good dump is still available here: https://s3.amazonaws.com/openrecipes/20170107-061401-recipeitems.json.gz

I have added that gz file to the data repo and changed one or two cells to use that instead (also means user on windows don't need the gunzip cli which caused trouble for some students we have using this).

I have also added some strange handling i had to do for pd.read_json() relating to pandas 1.1.1 as per this SO using StringIO(). Not quite sure exactly the details here and is a chance this part is a little 'hacky'.

The changes i have made might not quite be what you might do yourself but i just wanted to get this notebook 'working' for a some students we have at Springboard who use this notebook as an exercise in part of the course.

So figured i may aswell make a PR in case useful to you or anyone else.

andrewm4894 avatar Sep 01 '20 11:09 andrewm4894