question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

has_next_page always returns False

See original GitHub issue

I am doing a simple test.

orders = shopify.Order.find()

this returns a list of 50 orders but if I call orders.has_next_page() this returns False.

The same thing happens if I do

orders = shopify.Order.find(limit=3)

orders.has_next_page() still returns False.

I am trying to retrieve a list of orders between two date by using created_at_min and created_at_max but I always have the same problem: orders.has_next_page() returns False no matter what.

Any idea on how to solve this? it is unusable for me like this. Many thanks for the help

Issue Analytics

  • State:open
  • Created 3 years ago
  • Comments:11 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
gioxc88commented, Dec 15, 2022

The problem is with the library. If I try to use shopify REST API directly I get the correct result.

Checking metadata provides the same result. No next page

1reaction
DougPlumleycommented, Jul 2, 2020

Just realized I didn’t set the API version on a new feature branch, this issue can be resolved with this snippet:

api_version = '2020-01'
shop_url = f"https://{os.environ['SHOPIFY_URL']}.myshopify.com/admin/api/{api_version}"
shopify.ShopifyResource.set_site(shop_url)
Read more comments on GitHub >

github_iconTop Results From Across the Web

Users pagination returns `hasNextPage: false` even ... - GitHub
Just gave this a shot locally on an installation of my own and hasNextPage always appears false for all requests I've tried (not...
Read more >
hasNextPage() always returns false on Dynamic Pages (Solved)
Hey there! Today I got a question here in the forums why hasNext() and hasNextPage() always returns false. I realized that it does...
Read more >
I cannot do loadMore because hasMore() returns false always ...
I cannot do loadMore because hasMore() returns false always even if hasNextPage is true? ... Why would my hasMore() return false when hasNextPage...
Read more >
Why is hasPreviousPage always false? - BigCommerce Support
When using `first: x, after: x`, `hasNextPage`will be expected to return true unless false, and the opposite is seen with `last: x, before:...
Read more >
Pagination - Developers | Samsara
hasNextPage: false ... This parameter allows you to limit the number of objects returned on each page ... It is important that you...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found