Try using selenium webdriver, it will execute the JS scripts, and you can hide or unhide the navigator
Here are the tutorial of how to use
You'll need to install Selenium pip install selenium and download the webdriver [instructions here]
pip install selenium