Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A couple issued I noticed in API tutorial #212

Open
joshuamsmith opened this issue Sep 5, 2016 · 0 comments
Open

A couple issued I noticed in API tutorial #212

joshuamsmith opened this issue Sep 5, 2016 · 0 comments

Comments

@joshuamsmith
Copy link

Hello,

Really enjoying your tutorial! I wanted to reach out to point out a couple fixes that might help future readers from banging their heads on the keyboard:

adapted_price vs adjusted_price

on http://newcoder.io/api/part-3/ in the first section there is:

adapted_price = platform['adjusted_price']
but then you refer to variable adjusted_price a couple lines down. I think "adapted_price" is supposed to be "adjusted_price"

Endless loop

On page http://newcoder.io/api/part-1/ under the load_from_file method, the section you show to type out is not complete and has:

while not line.startswith("DATE "):
            pass

and leads to an endless loop, but looking in the completed source file it appears as:

            if not reached_dataset:
                if line.startswith("DATE "):
                    reached_dataset = True
                continue

403 forbidden with Giant Bomb

On api call was getting 403 errors until I added headers={'user-agent':'newcoder'} to the requests.get call

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant