Skip to main content
Question

Shopify - Suddenly not able to create products with metafields


gorazem
Varsity I
Forum|alt.badge.img

Hello,

While adding new products to Shopify(template items), we kept getting errors on some of the metafields syncing to Shopify.

We getting getting errors like:

Error on type : 'single_line_text_field' must be consistent with the definition's type: 'list.single_line_text_field'.;Error on type : 'single_line_text_field' must be consistent with the definition's type: 'multi_line_text_field'.;Error on type : 'single_line_text_field' must be consistent with the definition's type: 'metaobject_reference'.;

Existing products are syncing just fine(and their metafields), in fact I can copy the values from the non-working product and push a sync on an existing product and it sync just fine.But if I do the opposite and take the values from a working product and copy them to the non-working, it gives the same errors.

I also cloned one of the existing working template items(that i confirmed I could resync) and when I tried to sync the clone, I get the errors on the metafields again.

It really seems like something is broken when trying to set those metafields when they’re empty. Did the API update to graphQL and maybe something isn’t working the same?

9 replies

Samvel Petrosov
Jr Varsity II
Forum|alt.badge.img+3

Check the fields of that record for special characters line /n newline, etc. We have been receiving this error when the data in the fields was not corresponding to the ‘single_line_text_field’ type.


gorazem
Varsity I
Forum|alt.badge.img
  • Author
  • Varsity I
  • 46 replies
  • February 3, 2025
Samvel Petrosov wrote:

Check the fields of that record for special characters line /n newline, etc. We have been receiving this error when the data in the fields was not corresponding to the ‘single_line_text_field’ type.

We’ve tried swapping out the values from other products that are synced and still able to sync, and still getting the same error.

Most concerning, is I can clone a working, syncing product and when I try to sync the clone, it fails despite the original product working just fine.


Samvel Petrosov
Jr Varsity II
Forum|alt.badge.img+3
gorazem wrote:
Samvel Petrosov wrote:

Check the fields of that record for special characters line /n newline, etc. We have been receiving this error when the data in the fields was not corresponding to the ‘single_line_text_field’ type.

We’ve tried swapping out the values from other products that are synced and still able to sync, and still getting the same error.

Most concerning, is I can clone a working, syncing product and when I try to sync the clone, it fails despite the original product working just fine.

Have you changed any definitions/types of the metafields on Shopify side recently?


gorazem
Varsity I
Forum|alt.badge.img
  • Author
  • Varsity I
  • 46 replies
  • February 3, 2025
Samvel Petrosov wrote:
gorazem wrote:
Samvel Petrosov wrote:

Check the fields of that record for special characters line /n newline, etc. We have been receiving this error when the data in the fields was not corresponding to the ‘single_line_text_field’ type.

We’ve tried swapping out the values from other products that are synced and still able to sync, and still getting the same error.

Most concerning, is I can clone a working, syncing product and when I try to sync the clone, it fails despite the original product working just fine.

Have you changed any definitions/types of the metafields on Shopify side recently?

We have not, I confirmed the metafields are still the same namespace and key that is set on the export mapping.


gorazem
Varsity I
Forum|alt.badge.img
  • Author
  • Varsity I
  • 46 replies
  • February 3, 2025
Samvel Petrosov wrote:
gorazem wrote:
Samvel Petrosov wrote:

Check the fields of that record for special characters line /n newline, etc. We have been receiving this error when the data in the fields was not corresponding to the ‘single_line_text_field’ type.

We’ve tried swapping out the values from other products that are synced and still able to sync, and still getting the same error.

Most concerning, is I can clone a working, syncing product and when I try to sync the clone, it fails despite the original product working just fine.

Have you changed any definitions/types of the metafields on Shopify side recently?

For example:

Product 1 has metafield values. I can edit these values, prepare data and sync with no issue and metafield values update in Shopify as expected.

I can take product 1, copy/paste it to create a new product2

Product2 has the same exact values as product1, but when I sync product2, it fails and shows the error on type.


Samvel Petrosov
Jr Varsity II
Forum|alt.badge.img+3
gorazem wrote:
Samvel Petrosov wrote:
gorazem wrote:
Samvel Petrosov wrote:

Check the fields of that record for special characters line /n newline, etc. We have been receiving this error when the data in the fields was not corresponding to the ‘single_line_text_field’ type.

We’ve tried swapping out the values from other products that are synced and still able to sync, and still getting the same error.

Most concerning, is I can clone a working, syncing product and when I try to sync the clone, it fails despite the original product working just fine.

Have you changed any definitions/types of the metafields on Shopify side recently?

For example:

Product 1 has metafield values. I can edit these values, prepare data and sync with no issue and metafield values update in Shopify as expected.

I can take product 1, copy/paste it to create a new product2

Product2 has the same exact values as product1, but when I sync product2, it fails and shows the error on type.

I assume Product2 doesn’t exist in Shopify in this scenario. What happens if you create Product2 in both systems and then try to sync them? I feel like the issue is happening when Acumatica tries to create your metafields and it uses the ‘single_line_text_field’ type for it, while on Product1 you have metafield as ‘multi_line_text_field’


gorazem
Varsity I
Forum|alt.badge.img
  • Author
  • Varsity I
  • 46 replies
  • February 3, 2025
Samvel Petrosov wrote:
gorazem wrote:
Samvel Petrosov wrote:
gorazem wrote:
Samvel Petrosov wrote:

Check the fields of that record for special characters line /n newline, etc. We have been receiving this error when the data in the fields was not corresponding to the ‘single_line_text_field’ type.

We’ve tried swapping out the values from other products that are synced and still able to sync, and still getting the same error.

Most concerning, is I can clone a working, syncing product and when I try to sync the clone, it fails despite the original product working just fine.

Have you changed any definitions/types of the metafields on Shopify side recently?

For example:

Product 1 has metafield values. I can edit these values, prepare data and sync with no issue and metafield values update in Shopify as expected.

I can take product 1, copy/paste it to create a new product2

Product2 has the same exact values as product1, but when I sync product2, it fails and shows the error on type.

I assume Product2 doesn’t exist in Shopify in this scenario. What happens if you create Product2 in both systems and then try to sync them? I feel like the issue is happening when Acumatica tries to create your metafields and it uses the ‘single_line_text_field’ type for it, while on Product1 you have metafield as ‘multi_line_text_field’

I removed all the metafield values from product2, did the sync(which was successful)

I added back one of the metafield values from product1(a list of single line text):

["28 stain & finish options","Perfect in home storage","Stacks & expands","Ponderosa Pine, Knotty Alder or Premium Redwood","Made in the USA","Free shipping"]

and I got the same exact error again on product2:

 

Error on type : 'single_line_text_field' must be consistent with the definition's type: 'list.single_line_text_field'.;


I can also go to product1, and edit that metafield value to something like  ["28 stain & finish options","Perfect in home storage","Stacks & expands","Ponderosa Pine, Knotty Alder or Premium Redwood","Made in the USA","Free shipping",”TESTHERE”] and sync, which is also successful.


Forum|alt.badge.img
  • Jr Varsity III
  • 56 replies
  • February 3, 2025

I’ve been having the same exact issue and am actively troubleshooting this. I just recently found that when I’ve made sure the new Shopify category field is filled in and made it a category metafield, it has worked. Not sure yet if that has fixed everything, but that seems to be at least one of the issues. 


gorazem
Varsity I
Forum|alt.badge.img
  • Author
  • Varsity I
  • 46 replies
  • February 3, 2025
lawsont wrote:

I’ve been having the same exact issue and am actively troubleshooting this. I just recently found that when I’ve made sure the new Shopify category field is filled in and made it a category metafield, it has worked. Not sure yet if that has fixed everything, but that seems to be at least one of the issues. 

I think we are syncing a category ID to a shopify metafield, but I’m not sure if that’s what you’re talking about or what we use it for. The sync works if I remove any metafield values from the product on my end.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings