MultiAction.add method docstring states that it returns self instance. The method's type hint states that it returns none.
def add(self, *touch_actions: 'TouchAction') -> None:
"""Add TouchAction objects to the MultiAction, to be performed later.
Args:
touch_actions: one or more TouchAction objects describing a chain of actions to be performed by one finger
Usage:
| a1 = TouchAction(driver)
| a1.press(el1).move_to(el2).release()
| a2 = TouchAction(driver)
| a2.press(el2).move_to(el1).release()
| MultiAction(driver).add(a1, a2)
Returns:
`MultiAction`: Self instance
"""
for touch_action in touch_actions:
if self._touch_actions is None:
self._touch_actions = []
self._touch_actions.append(copy.copy(touch_action))
Environment
Appium version (or git revision) that exhibits the issue:
Currently on master branch, 3.3.1
Last Appium version that did not exhibit the issue (if applicable):
The problem
In appium/webdriver/common/multi_action.py:
MultiAction.add method docstring states that it returns self instance. The method's type hint states that it returns none.
Environment