modrzew / pokeminer

Pokemon location scraper
MIT License
220 stars 62 forks source link

How to use multiple worker.py instances to feed the same map? #271

Closed gatomiaurex closed 8 years ago

gatomiaurex commented 8 years ago

This may be a dumb question but I want to use multiple instances of worker.py to save workers that aren't being used, but I don't know how to tell the config.py that 1 is scanning one part of the map and the other instance the other.

leclaida commented 8 years ago

what? i'm not sure i understand. why can you not just do this as one instance?

gatomiaurex commented 8 years ago

I am sorry, English is not my primary language, this is what I am trying to do, running to "python worker.py" with different lat/long and feeding the data to the same map.

What I don't know is how to tell the second worker where to start and finish scanning in the config.py file.

untitled

leclaida commented 8 years ago

for the above example, use the DISABLE_WORKERS list to prevent them from scanning. i.e. put worker 4, worker 5, worker 6, etc. into that list.

if you want to "save workers", as in you don't have enough workers to cover the map, you can either:

a) just make more accounts b) put in dummy information for the disabled workers, since start_worker will not even attempt to login the account. you can pretty much put anything for worker 4's login info... same goes for all otehr disabled workers.

YonderGod commented 8 years ago

@leclaida You don't need to put dummy account info in anymore, it was updated to not skip accounts that aren't being used (idk how to explain this lol)

leclaida commented 8 years ago

@YonderGod you must be referencing this? https://github.com/modrzew/pokeminer/commit/f61ba4079d30647bd0f7aa00c590def6d563573c

cool, did not see that commit. thanks.

so yeah, ignore what i said earlier. it already automatically uses accounts only for active workers.