Unable to do click at a particular (x,y) of a control in windows test


I am working on a Windows test automation. I was using appium-java-client 7.5.1 and appium version 1.22. and selenium libraries version 3.14
I want to click at a particular (x,y) coordinate within a control bounds. I am using below code for this:

Actions action = new Actions(driver);
action.moveToElement(element, x, y).click().perform();

Here x and y are the x-axis and y-axis coordinates within the element where I want to click.

This code was working fine till appium-java-client version 7.5.1. But It is giving below error after I upgraded appium-java-client to 8.1.1 and selenium libraries to version 4.2.1

2022-08-29 15:08:21:051 [HTTP] --> POST /wd/hub/session/35d76e73-3aa5-44b6-b197-c38df6ae1848/actions
2022-08-29 15:08:21:052 [HTTP] {“actions”:[{“id”:“default mouse”,“type”:“pointer”,“parameters”:{“pointerType”:“mouse”},“actions”:[{“duration”:100,“x”:30,“y”:14,“type”:“pointerMove”,“origin”:{“ELEMENT”:“42.266604”,“element-6066-11e4-a52e-4f735466cecf”:“42.266604”}},{“button”:0,“type”:“pointerDown”},{“button”:0,“type”:“pointerUp”}]}]}
2022-08-29 15:08:21:052 [W3C (35d76e73)] Driver proxy active, passing request on via HTTP proxy
2022-08-29 15:08:21:087 [WD Proxy] Got response with status 500: {“status”:104,“value”:{“error”:“unsupported operation”,“message”:“Currently only pen and touch pointer input source types are supported”}}

Please suggest any solution

Looks like there is a bug filed:

But no movement on it. I think you should go back to the older libraries.