Action API class not working on Android emulator

Hi,

I would like some help with the action API class. We were using the touchAction API previously, however this was deprecated in the more recent versions of Appium. Our test framework is webdriver.io

webdriver.io docs:
touchAction | WebdriverIO

Appium deps:

 "appium": "2.5.1",
 "appium-uiautomator2-driver": "3.0.1",
 "appium-xcuitest-driver": "7.2.0",

Code to scroll on mobile device:

async scrollToFindElement(
    checkElement: WebdriverIO.Element,
    coordinates: Coordinates,
    numberOfRetries = 10,
  ) {
    const destinationY =
      coordinates.originY + coordinates.destinationY > 0
        ? coordinates.destinationY
        : 0
    const destinationX =
      coordinates.originX + coordinates.destinationX > 0
        ? coordinates.destinationX
        : 0
    let loop = true
    for (let index = 0; index < numberOfRetries && loop; index++) {
      if (await checkElement.isDisplayed()) {
        loop = false
      } else {
        driver
          .action('pointer', {
            parameters: { pointerType: 'touch' },
          })
          .move(coordinates.originX, coordinates.originY)
          .pause(300)
          .move(destinationX, destinationY)
          .perform()
      }
    }
  }
}

When I run the tests, I am seeing the following error:

[0-1] Error in "0: Then I should see the Priority banner"
invalid element state: Unable to perform W3C actions. Check the logcat output for possible error reports and make sure your input actions chain is valid.

I would appreciate any help or guidance.