Api gets stuck at cp.catchPokemon(pokeball)
The latest commit sometimes gets stuck at cp.catchPokemon(pokeball). Can't seem to track down the cause. it just hangs at catchPokemon(pokeball) function. I went back to previous commit dad8a4a, and it doesn't have the problem.
on the very very latest commits? #404 #405
Thanks! You guys are so fast! Love it. I see there are more commits.
I just pulled down commit 82fefdb62fce9aaaf80ca26e97640dc4f416f73a. Testing now. I'll report back.
On 7/31/2016 1:37 PM, Grover-c13 wrote:
on the very very latest commits? #404 https://github.com/Grover-c13/PokeGOAPI-Java/pull/404 #405 https://github.com/Grover-c13/PokeGOAPI-Java/pull/405
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Grover-c13/PokeGOAPI-Java/issues/406#issuecomment-236444517, or mute the thread https://github.com/notifications/unsubscribe-auth/ALDSxzmHFAC2x9WS-JgVczHGaK4z968Pks5qbN1ngaJpZM4JZFGg.
Also having the same issue with latest commit 82fefdb
I'm on commit 82fefdb62fce9aaaf80ca26e97640dc4f416f73a.
This one seems to get stuck less, but still get stuck on once in a while.
result = cp.catchPokemon(pokeball);
On 7/31/2016 4:23 PM, a4andy wrote:
Also having the same issue with latest commit 82fefdb https://github.com/Grover-c13/PokeGOAPI-Java/commit/82fefdb62fce9aaaf80ca26e97640dc4f416f73a
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Grover-c13/PokeGOAPI-Java/issues/406#issuecomment-236454330, or mute the thread https://github.com/notifications/unsubscribe-auth/ALDSx4uVII0X6-TQSGwFkQTIss1DYqqAks5qbQQogaJpZM4JZFGg.
I have been testing it for a while, and it definitely gets stuck at cp.catchPokemon(pokeball);. Not all the time, but once in a while. Also, after you catch all the pokemons in catchablePokemon, and refresh the following in the same spot, catchablePokemon = map.getCatchablePokemon(); size = catchablePokemon.size(); It sometimes returns 1, and when you try to catch, nothing's there. It happens enough that I think something weird is happening in the queue. Also, the cpu usage is pretty high. None of these issues happen in the previous commits before sync future. I went back and check. Could you investigate what might cause these after the commit dad8a4a? Thank you as always!
I just pulled commit 4f85be14c63d5329e2a7edf283e2aa96c984bf07. This one sometimes goes into infinite loop where catchablePokemon.size() is always 1, and there's nothing to encounter.
Apparently pokemon that you already caught still remains in go.getMap().getCatchablePokemon(). Then the cp.encounterPokemon().getStatus() returns ENCOUNTER_ALREADY_HAPPENED. Is there way to remove caught pokemons from the getCatchablePokemon()? Or, should I keep refreshing getCatchablePokemon() and ignore ENCOUNTER_ALREADY_HAPPENED?
Weird, thought i had fixed that issue
are you 100% sure you have pulled?
I'm pretty sure. I just ran git-rev-parse, and it says I'm on 4f85be1.
Here's my code and result in case I missed something.
while (true) {
List
Commit cca2a1cf still has this problem.
Why it should"t?
After catching all the pokemons in catchablePokemon, shouldn't go.getMap().getCatchablePokemon().size() report 0 unless there's new pokemon?
yes it should, unless the cache timer had expired between the catch and the getCatchablePokemon
Application is getting stuck with this output: CatchPokemon [02:56:09] MAGIKARP Catch Result
Related Code:
context.setConsoleString("CatchPokemon", "[" + new SimpleDateFormat("HH:mm:ss").format(new Date()) + "] " + target.getPokemonId() + " Catch Result");
CatchResult catchResult = target.catchPokemon(pokeball);
context.setConsoleString("CatchPokemon", "[" + new SimpleDateFormat("HH:mm:ss").format(new Date()) + "] " + target.getPokemonId() + " After Catch Result");
Is this related? Encountered PIDGEY: ENCOUNTER_SUCCESS A/CatchablePokemon: Got an error or unrecognized catch attempt A/CatchablePokemon: Proto:CatchResult(captureAward=null, response=null, status=CATCH_ERROR, failed=true) Attempt to catch: CATCH_ERROR
issue is much more detailed on #446