API error trying to create return with cancelled items on order

I am trying to create return through the GraphQL API. The only thing different about this order is 2 of the 4 items have been cancelled. When I try and create a return with one of the good items, I get the following error:

{“errors”:[{“message”:“Invalid Line item 534944306, warehouse Primary. It must belong to the same warehouse 11932, [NAME REDADCTED].”,“operation”:“return_create”,“field”:“return_create”,“request_id”:“60f1d1d2513219c080991280”,“code”:9}],“data”:{“return_create”:null}}

Is this a known bug?

Hi,
The line item in our data says that the warehouse (for that line item )is Primary, but that sku does not reside in the Primary warehouse.
Have you tried the same thing in the UI? Does it give an error?