In python selenium4 to get the element under shadow I get the following error using the following code

    shadow_host = driver.find_element(By.TAG_NAME, 'wujie-app')

    shadow_root = driver.execute_script('return arguments[0].shadowRoot;', shadow_host)
    inner_element = shadow_root.find_element(By.CSS_SELECTOR, '.arco-input')

Why doesn’t it go wrong to kiss the above