jabbink / PokemonGoBot

DEFUNCT - Bot that plays Pokemon Go
https://www.pogobot.club/
GNU General Public License v3.0
559 stars 232 forks source link

Bot only catching a few Pokémon #672

Closed kasagon closed 8 years ago

kasagon commented 8 years ago

Description: I got the bot running for a little bit more then a hour now, and it seems that the bot is ignoring the most of the Pokémon.

In the past hour the bot has caught 5 Pokémon, while the map (live map) is showing a lot more then that. I don't know if it is my settings or something else.

My settings: http://pastebin.com/83Tyw4qC

Steps to reproduce:

  1. Run the bot

Expected behavior: Catch more Pokémon instead of ignoring the most of them

Actual behavior: Catches 5 Pokemon in a hour, ignores the most Pokemon

Version: Commit 62e2fb1 I edited 2 files, but those are files from the web GUI ( #671 )

Operating System: Windows 10 PRO 64-bit

Java version:

C:\>java -version
java version "1.8.0_102"
Java(TM) SE Runtime Environment (build 1.8.0_102-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.102-b14, mixed mode)
Natedog2012 commented 8 years ago

Having the same issue with the alpha3.. caught 0 / 0 .. it skips almost every pokemon it comes near

SiriusCrypto commented 8 years ago

I dont see that it encounters any pokemon all i see is it keeps saying pausing to catch pokemon over and over without any result or anything else: (alpha 3)

31 Jul 02:49:33: Pausing to catch pokemon... 31 Jul 02:49:33: Dropped 3x ITEM_POKE_BALL 31 Jul 02:49:35: Dropped 1x ITEM_GREAT_BALL 31 Jul 02:49:36: Dropped 2x ITEM_RAZZ_BERRY 31 Jul 02:49:40: Pausing to catch pokemon... 31 Jul 02:49:46: Pausing to catch pokemon... 31 Jul 02:49:51: Pausing to catch pokemon... 31 Jul 02:49:56: Pausing to catch pokemon... 31 Jul 02:49:58: Destination reached. 31 Jul 02:50:00: Walking to (52.37023, 4.900303) in 100.36417700579715 steps. 31 Jul 02:50:05: Pausing to catch pokemon... 31 Jul 02:50:10: Pausing to catch pokemon... 31 Jul 02:50:16: Pausing to catch pokemon... 31 Jul 02:50:21: Pausing to catch pokemon... 31 Jul 02:50:25: Pausing to catch pokemon...

Also at the beginning i get an error (maybe this helps to figure out what the bug is)

31 Jul 02:53:42: Getting initial pokestops... 31 Jul 02:53:44: Got 568 pokestops 31 Jul 02:53:44: Running webserver on port 8473 31 Jul 02:53:45: Error running loop BotLoop! java.util.ConcurrentModificationException at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:901) at java.util.ArrayList$Itr.next(ArrayList.java:851) at ink.abb.pogo.scraper.tasks.ReleasePokemon.run(ReleasePokemon.kt:63) at ink.abb.pogo.scraper.Bot.task(Bot.kt:183) at ink.abb.pogo.scraper.Bot$start$4.invoke(Bot.kt:122) at ink.abb.pogo.scraper.Bot$start$4.invoke(Bot.kt:32) at ink.abb.pogo.scraper.Bot$runLoop$1.invoke(Bot.kt:145) at ink.abb.pogo.scraper.Bot$runLoop$1.invoke(Bot.kt:32) at kotlin.concurrent.ThreadsKt$thread$thread$1.run(Thread.kt:18) 31 Jul 02:53:46: Profile update: 678369 XP on LVL 24; 118369/150000 (78.91%) to LVL 25

kasagon commented 8 years ago

@Natedog2012 I am running Alpha3 as well, but with a few commits (3 or 4 I think)

It is running for 90 minutes now, 30 minutes after I made this post, and it still has caught 5 Pokemon

@SiriusCrypto I don't have that though, it only gives that message once in a few minutes or so.

Natedog2012 commented 8 years ago

Getting an error sometimes when it tries to catch pokemon as well...

30 Jul 18:10:38: Found pokemon DIGLETT 30 Jul 18:10:38: Encountered pokemon DIGLETT with CP 169 and IV 40% 30 Jul 18:10:38: Using desired_catch_probability_unwanted because CP < 500 and IV < 85% 30 Jul 18:10:38: Using ITEM_POKE_BALL; achieved catch probability: 0.35288644, desired: 0.0 30 Jul 18:10:39: Error running loop BotLoop! java.lang.NullPointerException at com.pokegoapi.api.map.pokemon.CatchResult.getStatus(CatchResult.java:45) at ink.abb.pogo.scraper.util.pokemon.CatchablePokemonKt.catch(CatchablePokemon.kt:45) at ink.abb.pogo.scraper.tasks.CatchOneNearbyPokemon.run(CatchOneNearbyPokemon.kt:62) at ink.abb.pogo.scraper.Bot.task(Bot.kt:201) at ink.abb.pogo.scraper.Bot$start$4.invoke(Bot.kt:123) at ink.abb.pogo.scraper.Bot$start$4.invoke(Bot.kt:34) at ink.abb.pogo.scraper.Bot$runLoop$1.invoke(Bot.kt:163) at ink.abb.pogo.scraper.Bot$runLoop$1.invoke(Bot.kt:34) at kotlin.concurrent.ThreadsKt$thread$thread$1.run(Thread.kt:18) 30 Jul 18:10:42: Getting map of (34.00972013343425, -118.49332248234569) 30 Jul 18:10:43: Found pokemon DIGLETT 30 Jul 18:10:43: Encountered pokemon DIGLETT with CP 169 and IV 40%

SiriusCrypto commented 8 years ago

Servers are having issues atm, could just be that? Or might have something to do with This commit by @pashorizer

celsian commented 8 years ago

The minimum scan speed has been changed by the API, gonna have to delve into the API code and change it before the bot will be effective again. Will likely have to reduce the walking speed as well.

HoneyWheat commented 8 years ago

Imho an important issue because stardust is the limiting ressource, you can't have enough of it.

Tried settings:

# desired probability to catch Pokemon with 1 throw desired_catch_probability=1

# desired probability to catch unwanted Pokemon (obligatory_transfer; low IV; low CP) # set to -1 to not attempt catching at all desired_catch_probability_unwanted=1

No effect!

GeitV commented 8 years ago

Yeah having the exact same log as Sirius, as of I get alot of "Pausing to catch pokemon..." but it doesn't pause it seems. I still have caught some pokemons but it seems sometimes the pausing doesn't work and it cannot catch the pokemon.

casper-gh commented 8 years ago

I'm getting very little to no pokemon at all, tested with walk speed from 1 to 30 but still the same

HoneyWheat commented 8 years ago

Snapshot: Bot is running for 30min in a city area full of Pokestops. Got only 400 startdust in 30min.

pashorizer commented 8 years ago

There is a new throttle from Niantic regarding the server response.

GeitV commented 8 years ago

I did my own fix for this, seems to work atm (not a good solution as it stops the program, but well works at the moment) I do not wanna push, as I hope someone gets better function, its just temporary. If anyone wants to fix this, check the image and you will understand what to do

https://gyazo.com/009994399be08acb56f65447e069ae6c

For me it seems to be able to catch again, but don't take this granted

casper-gh commented 8 years ago

actually increasing the move speed to 25+ will help catch more pokemon, not sure if i'll get banned

GeitV commented 8 years ago

25 m/s, that is 90km/h and you are able to catch? Whoa, I thought the limit was 20-25 km/h

pashorizer commented 8 years ago

Right now, even if you set the speed to 1000. It will not go that fast, because some API calls take a long time to answer so the bot blocks himself. This is going to be fixed with this https://github.com/jabbink/PokemonGoBot/pull/664 Then you can set a speed e.g. 5, 10, 15, 20 and it will go that fast and stop every 20 steps to check for pokemon around him. As a side note, I also tried to go with 25m/s on a throwaway account and it did not get banned. But highly risky. Choose on your own.

GeitV commented 8 years ago

Ok, thanks for heads-up :) Will try with higher speeds also

kasagon commented 8 years ago

Bot has been running for 11 hours. Caught 5 Pokemon in total, and got so many botloop and walkingloop errors that it only traveled ~1.7km in the last 9 hours.

qifbox commented 8 years ago

I changed settings to 1.5 m/s and started having more pokemons. But looping errors too..

Print

http://scr.hu/1pgo/6oszp

Error

31 jul 12:35:23: Found pokemon PIDGEY 31 jul 12:35:23: Encountered pokemon PIDGEY with CP 217 and IV 28% 31 jul 12:35:23: Using desired_catch_probability_unwanted because CP < -1 and IV < 80% 31 jul 12:35:23: Using ITEM_POKE_BALL; achieved catch probability: 0.40011334, desired: 0.0 31 jul 12:35:24: Error running loop BotLoop! com.pokegoapi.exceptions.RemoteServerException: Contents of buffer are null at com.pokegoapi.util.FutureWrapper.toBlocking(FutureWrapper.java:119) at com.pokegoapi.main.RequestHandler.sendServerRequests(RequestHandler.java:154) at com.pokegoapi.api.inventory.Inventories.updateInventories(Inventories.java:108) at com.pokegoapi.api.inventory.Inventories.updateInventories(Inventories.java:84) at com.pokegoapi.api.map.pokemon.CatchablePokemon$3.handle(CatchablePokemon.java:408) at com.pokegoapi.api.map.pokemon.CatchablePokemon$3.handle(CatchablePokemon.java:396) at com.pokegoapi.util.FutureWrapper.getResult(FutureWrapper.java:78) at com.pokegoapi.util.FutureWrapper.get(FutureWrapper.java:53) at com.pokegoapi.util.FutureWrapper.toBlocking(FutureWrapper.java:108) at com.pokegoapi.util.FutureWrapper.toBlocking(FutureWrapper.java:94) at com.pokegoapi.api.map.pokemon.CatchablePokemon.catchPokemon(CatchablePokemon.java:347) at ink.abb.pogo.scraper.util.pokemon.CatchablePokemonKt.catch(CatchablePokemon.kt:27) at ink.abb.pogo.scraper.util.pokemon.CatchablePokemonKt.catch(CatchablePokemon.kt:115) at ink.abb.pogo.scraper.util.pokemon.CatchablePokemonKt.catch(CatchablePokemon.kt:42) at ink.abb.pogo.scraper.tasks.CatchOneNearbyPokemon.run(CatchOneNearbyPokemon.kt:62) at ink.abb.pogo.scraper.Bot.task(Bot.kt:201) at ink.abb.pogo.scraper.Bot$start$4.invoke(Bot.kt:123) at ink.abb.pogo.scraper.Bot$start$4.invoke(Bot.kt:34) at ink.abb.pogo.scraper.Bot$runLoop$1.invoke(Bot.kt:163) at ink.abb.pogo.scraper.Bot$runLoop$1.invoke(Bot.kt:34) at kotlin.concurrent.ThreadsKt$thread$thread$1.run(Thread.kt:18) Caused by: com.google.protobuf.InvalidProtocolBufferException: Contents of buffer are null at com.pokegoapi.main.ServerRequest.getData(ServerRequest.java:78) at com.pokegoapi.main.RequestHandler.run(RequestHandler.java:292) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) 31 jul 12:35:27: Getting map of (38.70588197434313, -9.143618616274567) 31 jul 12:35:32: Getting map of (38.70585971939362, -9.14356553821557) 31 jul 12:35:37: Getting map of (38.70585992724561, -9.143601047507861) 31 jul 12:35:38: Profile update: 294075 XP on LVL 21; 34075/75000 (45,43%) to LVL 22 31 jul 12:35:38: XP gain: 1400 XP; Pokemon caught/transferred: 2/1; Items caught/dropped: 0/2; Pokebank 87/250; Stardust 3266; Inventory 267/350 com.pokegoapi.exceptions.RemoteServerException: Contents of buffer are null31 jul 12:35:39: Error running loop ProfileLoop!

    at com.pokegoapi.util.FutureWrapper.toBlocking(FutureWrapper.java:119)
    at com.pokegoapi.main.RequestHandler.sendServerRequests(RequestHandler.java:154)
    at com.pokegoapi.api.inventory.Inventories.updateInventories(Inventories.java:108)
    at com.pokegoapi.api.inventory.Inventories.updateInventories(Inventories.java:84)
    at com.pokegoapi.api.inventory.Hatchery.queryHatchedEggs(Hatchery.java:75)
    at ink.abb.pogo.scraper.tasks.HatchEggs.run(HatchEggs.kt:22)
    at ink.abb.pogo.scraper.Bot.task(Bot.kt:201)
    at ink.abb.pogo.scraper.Bot$start$3.invoke(Bot.kt:115)
    at ink.abb.pogo.scraper.Bot$start$3.invoke(Bot.kt:34)
    at ink.abb.pogo.scraper.Bot$runLoop$1.invoke(Bot.kt:163)
    at ink.abb.pogo.scraper.Bot$runLoop$1.invoke(Bot.kt:34)
    at kotlin.concurrent.ThreadsKt$thread$thread$1.run(Thread.kt:18)

Caused by: com.google.protobuf.InvalidProtocolBufferException: Contents of buffer are null at com.pokegoapi.main.ServerRequest.getData(ServerRequest.java:78) at com.pokegoapi.main.RequestHandler.run(RequestHandler.java:292) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) 31 jul 12:35:42: Getting map of (38.70591455035207, -9.143588184881898) 31 jul 12:35:43: Going to transfer PIDGEY with CP 217 and IV 28%; reason: CP < -1 and IV < 80%

kasagon commented 8 years ago

@pashorizer With #664 the bot ignored the first few encounters, but after that it encountered Pokémon again. But, the bot encounters those Pokémon really late, it has caught 5 Pokémon now, but haven't encountered one for a few minutes, but the bot is walking right now on a place where less to none Pokémon are, so that can be right.

I set a path for the bot that comes across some places with a lot of Pokémon (2+ in a range of 15 metres), but that path will take a while. So I am curious it will catch more Pokémon now.

d0tamon commented 8 years ago

Mine has a similar situation as well. and random BotLoops along the way

yashendra2797 commented 8 years ago

Yup. Same here. way less pokemons caught in same area as yesterday when I used Alpha 2

kasagon commented 8 years ago

@TheJ0k3r I was at the location there earlyer today, and there are a lot of Pokemon. I used @pashorizer fix, and it catches a lot more Pokemon.

vaneske commented 8 years ago

Confirmed. @pashorizer fix works.

langerhans commented 8 years ago

Closing as the latest release should fix this.

casper-gh commented 8 years ago

@vaneske what walk speed are you using?

vaneske commented 8 years ago

@casper-gh default speed of 2.8