def METHOD_NAME(cls, _root, info: ResolveInfo, /, **data):
    errors: defaultdict[str, List[ValidationError]] = defaultdict(list)
    stocks = data["stocks"]
    sku = data.get("sku")
    variant_id = data.get("variant_id")
    validate_one_of_args_is_in_mutation("sku", sku, "variant_id", variant_id)
    if variant_id:
        variant = cls.get_node_or_error(info, variant_id, only_type=ProductVariant)
    if sku:
        variant = models.ProductVariant.objects.filter(sku=sku).first()
        if not variant:
            raise ValidationError(
                {
                    "sku": ValidationError(
                        f"Couldn't resolve to a node: {sku}", code="not_found"
                    )
                }
            )
    if stocks:
        warehouse_ids = [stock["warehouse"] for stock in stocks]
        cls.check_for_duplicates(warehouse_ids, errors)
        if errors:
            raise ValidationError(errors)
        warehouses = cls.get_nodes_or_error(
            warehouse_ids, "warehouse", only_type=Warehouse
        )
        manager = get_plugin_manager_promise(info.context).get()
        cls.update_or_create_variant_stocks(variant, stocks, warehouses, manager)
    StocksWithAvailableQuantityByProductVariantIdCountryCodeAndChannelLoader(
        info.context
    ).clear((variant.id, None, None))
    variant = ChannelContext(node=variant, channel_slug=None)
    return cls(product_variant=variant)