Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"mock_human=True" breaks some input fields #80

Open
sadikhan918 opened this issue Jan 5, 2025 · 1 comment
Open

"mock_human=True" breaks some input fields #80

sadikhan918 opened this issue Jan 5, 2025 · 1 comment

Comments

@sadikhan918
Copy link

sadikhan918 commented Jan 5, 2025

When I set the value of mock_human to be True, attempting to type into a field won't actually type anything. Removing the parameter makes it function properly.

Works and allows input fields to be typed into:


with initialResp.render(headless=False) as page:
                time.sleep(3)
                page.awaitNavigation()
                page.awaitSelector('#signInName')
                page.type('input#signInName', email)    # Does type here
                page.type('input#password', password)  # Does type here
                page.click('#next')

Does not work:


with initialResp.render(mock_human=True, headless=False) as page:
                time.sleep(3)
                page.awaitNavigation()
                page.awaitSelector('#signInName')
                page.type('input#signInName', email)    # Does not type here
                page.type('input#password', password)  # Does not type here
                page.click('#next')

@MiseaSybsa
Copy link

I think that's intended behaviour, you should try using .click on element before .type:

with initialResp.render(headless=False) as page:
                time.sleep(3)
                page.awaitNavigation()
                page.awaitSelector('#signInName')
                page.click('input#signInName')
                page.type('input#signInName', email)    # Does type here
                page.click('input#password')
                page.type('input#password', password)  # Does type here
                page.click('#next')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants