def get_input_value(page, css_selector):
 page.wait_for_element_presence(css_selector, 'Elements matching "{}" selector are present'.format(css_selector))
 return page.q(css=css_selector).attrs('value')[0]

def get_input_value ( page , css_selector ) : page . wait_for_element_presence ( css_selector , 'Elements matching "{}" selector are present' . format ( css_selector ) ) return page . q ( css = css_selector ) . attrs ( 'value' ) [ 0 ]
returns the value of the field matching the css selector .