-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
get_posts() with limit #2269
Comments
Hey @BobikRekordik! I saw your issue when running into the same problem. I went a little bit inside the code and I believe it does not make sense to change the behave of I made a PR with the changes that worked here, you just need to use the new recommend function to get profile posts: Here it is a snippet code of how get some limiting amount of posts after this change from instaloader import Instaloader, Profile
USERNAME = "cachorroquentealex"
Instaloader = Instaloader()
profile = Profile.from_username(Instaloader.context, USERNAME)
Instaloader.download_profiles(profiles=[profile], max_count=2) # it will download only 2 posts |
Thanks, it's a good option, but the method downloads the whole page, I need it to return a List[] from these posts, there is a shortcode, id, description and others... example:
|
Hi. Make the get_posts() method accept the limit on the received data as an argument. There are pages with more than 100 thousand posts and it took me about an hour to do this.
I would like to get only the last n posts instead of all the posts by sending an argument.
posts = user.get_posts(50); #latest 50 posts only :)
The text was updated successfully, but these errors were encountered: