mechanic-tasks icon indicating copy to clipboard operation
mechanic-tasks copied to clipboard

address deprecations in "Auto-fulfill items that don't require shipping"

Open isaacbowen opened this issue 2 years ago • 5 comments

https://tasks.mechanic.dev/auto-fulfill-items-that-dont-require-shipping

Screenshot 2023-07-11 at 3 37 35 PM

(notes below all describe what's available in 2023-04)

We need that requiresShipping field, and it turns out that it's available one level up on FulfillmentOrderLineItem.requiresShipping.

FulfillmentOrderLineItem doesn't have any references to the original product or variant (which - sigh - I understand but don't love), so I think this task will necessarily have to drop the "Ignore products with this tag" option.

isaacbowen avatar Jul 11 '23 20:07 isaacbowen

internal reference: https://secure.helpscout.net/conversation/2297032362/68809/

isaacbowen avatar Jul 11 '23 20:07 isaacbowen

Per https://shopifypartners.slack.com/archives/CB9K9FDTJ/p1674000985691099, Shopify has stated that they will provide a solution for looking up the source line item from the FOLI resource before the lineItem resource is fully deprecated in early 2024.

They said they would have more info prior to 2023-07 release, but so far they have only added the inventoryItemId to the FOLI, which can get the product/variant details in a roundabout way, BUT that doesn't help with things like line item custom attributes. I'll respond in that thread to see where their collective heads are at for resolving this as it affects quite a few tasks in the library.

tekhaus avatar Jul 11 '23 20:07 tekhaus

Getting lots of emails about this, hopefully Shopify provides a path soon :D

mattsodomsky avatar Nov 03 '23 17:11 mattsodomsky

#304 has updated the specific task that opened this PR to work around the deprecation. Since there is no deprecation deadline then I would still like to see what Shopify does (if anything) in the 2024-01 release to rectify this issue before updating all of the other affected tasks in mass.

tekhaus avatar Dec 01 '23 18:12 tekhaus

Update: Checked the 2024-01 API release, and nothing has changed in this regard. No link to the original order line item from the FOLI, but the lineItem resource is still there and no date has been set for deprecation resolution.

Makes one wonder if they will ever fully deprecate this resource. Would be nice to know, because then it could just be permanently suppressed.

tekhaus avatar Jan 02 '24 23:01 tekhaus

Update: 2024-07 API - a variant (and thus indirectly product) connection has now been added to the FOLI. 🎉

This covers a good deal of the usage found in the Library, but will still require updating of the affected tasks. This might be done in most cases without the extra inventory item query, however a new wrinkle is that there has been some shifting of variant fields to inventory items as well, so I'll just have dig in and see what all needs to be updated to stay current.

Also, the only thing not covered now from the line item deprecation aspect is any tasks (public library or custom) that need determinate access to the original line item (typically for line item custom attributes).

tekhaus avatar Jul 02 '24 05:07 tekhaus

@tekhaus You are incredible to me. Thank you. :)

isaacbowen avatar Jul 02 '24 12:07 isaacbowen

And after a review, the only task that actually was affected in the end by the FOLI mess was the original linked task that was already mitigated.

The variant / inventory field updates were handled in #378

tekhaus avatar Jul 19 '24 06:07 tekhaus