Skip to content
This repository has been archived by the owner on Dec 15, 2018. It is now read-only.

Session invalidated, response code 100 #188

Closed
n2o opened this issue Feb 28, 2017 · 5 comments
Closed

Session invalidated, response code 100 #188

n2o opened this issue Feb 28, 2017 · 5 comments

Comments

@n2o
Copy link

n2o commented Feb 28, 2017

Since a few days I am experiencing an issue when using the latest version of pgoapi. I try to login, provide some longitude and latitude and I am getting an error 100:


from pgoapi.pgoapi import PGoApi
pokeapi = PGoApi()

[...]

    try:
        logged_in = pokeapi.login(service, login_name, password,
                                  lat=51.227741, lng=6.773456, app_simulation=True)
    except AuthException as e:
        return jsonify({'status': 'error',
                        'message': e.__str__()})

    if not logged_in:
        return jsonify({'status': 'error',
                        'message': 'Failed to login. If the Pokemon GO Servers are online, your credentials may be wrong.'})
    else:
        return jsonify({'status': 'ok'})

This appears to be successful. If I then create a request, e.g.:

    req = pokeapi.create_request()
    req.get_inventory()
    response_dict = req.call()

then my response_dict looks like this:

{'request_id': 4614933524804272132, 'responses': {}, 'status_code': 100}

Do you have any advices how I can proceed and where this bugs comes from? Thanks for your help!

Related: https://www.reddit.com/r/pokemongodev/comments/5w3x36/question_api_returns_status_code_100_session/

@n2o n2o changed the title Session invaliadated, response code 100 Session invalidated, response code 100 Feb 28, 2017
@n2o
Copy link
Author

n2o commented Feb 28, 2017

Just saw, that #177 fixes the issue. Would appreciate it if you could accept this pull request.

@n2o n2o closed this as completed Feb 28, 2017
@nullpixel
Copy link
Contributor

Reviewing the PR now 👍

@Ephemerality
Copy link
Contributor

Ephemerality commented Feb 28, 2017

This issue occurs when using the master branch (old uk25), using the develop branch fixes it. We should consider merging develop in soon, I guess.

@NHellFire
Copy link

The develop branch does not fix it. I'm trying cf158ee, same result.

{'status_code': 100, 'responses': {}, 'request_id': 559709164373278725L}

My test code:

from pgoapi import pgoapi
pokeapi = pgoapi.PGoApi()
pokeapi.set_position(52, 0, 10)
pokeapi.login("ptc", "myusername", "mypassword")
req = pokeapi.create_request()
req.get_inventory()
response_dict = req.call()
print response_dict

@Ephemerality
Copy link
Contributor

See the comments on #185. Until the 0.45api is fixed (either through experimenting or Niantic re-enabling it), you need to use a Bossland hash key.

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

No branches or pull requests

4 participants