This gem declare the harmonized_system_code as T.nilable(Integer), however, when I try to add the HS code using Shopify dashboard, it seems to be saved in String instead of Integer.
This raises type error when I try to get the hs code using using inventory_item.hs_code
For now I have to monkey patched it in order to retrieve the hs code
def harmonized_system_code
value = get_property("harmonized_system_code")
return value if value.nil?
value.to_s
end
So, I am wondering what is the correct type for harmonized_system_code? If it's a String, I am happy to open a PR to change the type declaration.
shopify_api version: 13.3.1
Ruby version: 3.0.6
Operating system: MacOS Ventura 13.2.1
Expected behavior
I am not sure if it's intended to be an Integer or it's a wrong type in the first place. But if the harmonized system code is indeed supposed to be an Integer, then I am expecting the harmonized system code should be saved as Integer.
Actual behavior
The harmonized system code is saved as String.
Steps to reproduce the problem
Create a new product with default variant on Shopify dashboard and set the HS Code
Issue summary
This gem declare the
harmonized_system_code
asT.nilable(Integer)
, however, when I try to add the HS code using Shopify dashboard, it seems to be saved in String instead of Integer.This raises type error when I try to get the hs code using using
inventory_item.hs_code
For now I have to monkey patched it in order to retrieve the hs code
So, I am wondering what is the correct type for
harmonized_system_code
? If it's a String, I am happy to open a PR to change the type declaration.shopify_api
version: 13.3.1Expected behavior
I am not sure if it's intended to be an Integer or it's a wrong type in the first place. But if the harmonized system code is indeed supposed to be an Integer, then I am expecting the harmonized system code should be saved as Integer.
Actual behavior
The harmonized system code is saved as String.
Steps to reproduce the problem
inventory_item.harmonized_system_code
, the type error like below should be raised