CustomerAddress.all doesn't return results
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
Research direction
Start by reproducing the discrepancy between ShopifyAPI::CustomerAddress.all(customer_id: x) and ShopifyAPI::Customer.find(id: x).addresses using the reported private-app configuration and API version. Trace the CustomerAddress.all request and compare it with the customer addresses response; done means the collection returns the customer's existing addresses, with a regression test covering the case.
Written by the indexing model from the issue text.
Description
Issue summary
CustomerAddress.all doesn't return results, using Rest API with a private app.
Expected behavior
Returns list with customer's addresses.
Actual behavior
Returns empty list for a customer with an address.
Steps to reproduce the problem
- Create a customer with an address on Shopify.
- Initialise gem with private app config:
ShopifyAPI::Context.setup(
api_key: "",
host_name:"",
scope: "",
session_storage: ShopifyAPI::Auth::FileSessionStorage.new,
is_embedded: false,
is_private: true,
api_version: Rails.application.credentials.shopify.api_version!,
api_secret_key: Rails.application.credentials.shopify.password!,
private_shop: "#{Rails.application.credentials.shopify.shop_name!}.myshopify.com"
)
- Perform
ShopifyAPI::CustomerAddress.all(customer_id: x)and receive[] - Perform
ShopifyAPI::Customer.find(id: x).addressesand confirm the customer actually has an address.
Specifications
shopify_apiversion: 10.1.0- Shopify API version used: 2022-04
- Dominant language
- Ruby
- Stars
- 1.1k
- Forks
- 484
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Shopify/shopify-api-ruby
-
devtools-gardener
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Shopify/shopify-api-ruby#1456 · 3 reactions ·
-
devtools-gardener
Difficulty 3/5 1-2 days Newbie friendliness 67/100
Shopify/shopify-api-ruby#1461 ·
-
automated
Difficulty 4/5 3-5 days Newbie friendliness 48/100
Shopify/shopify-api-ruby#1460 ·
-
devtools-gardener
Difficulty 5/5 Over a week Newbie friendliness 35/100
Shopify/shopify-api-ruby#1455 ·
-
devtools-gardener
Difficulty 4/5 3-5 days Newbie friendliness 48/100
Shopify/shopify-api-ruby#1453 ·
All issues in Shopify/shopify-api-ruby
Similar issues
-
user-reported
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Kong/developer.konghq.com#7316 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
TheOdinProject/curriculum#31408 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
bensheldon/good_job#1816 · 5 comments ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
notch8/utk_knapsack#148 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 78/100
Homebrew/homebrew-cask#288729 · 1 comment ·