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

ValueError: range() arg 3 must not be zero #1

Open
ZekiJohn opened this issue May 27, 2024 · 2 comments
Open

ValueError: range() arg 3 must not be zero #1

ZekiJohn opened this issue May 27, 2024 · 2 comments

Comments

@ZekiJohn
Copy link

I just run the example provided. didn't change anything but got this error

image

@Carnewal
Copy link

This happens because of the floor division to calculate the chunk_size returning 0 which is not valid

chunk_size = len(self.stargazers) // self.threads

To work around this you need to set threads to a value that would produce something > 1, for example

crawler = stargazerz.Crawler(threads=7, target="Frikallo/stargazerz")

@bakhirev
Copy link

It work for me too. May be add "threads=7" like default value?

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

3 participants