Python Forum

Full Version: enable flash using selenium chromedriver
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello :)

Me again,...

I'm currently trying to automate some stuff in an older game, which is still running via flash ...

After I login to the website, and start the gameworld, I get an error message that 'Flash' gets blocked.
[Image: KXVHY8D]


First question... is there a way to save all changes made hand for future chrome windows ?
Because I tried to change the flash settings by hand several times, but all will be resetted after closing chrome and re-open it.


I've read through a lot of solutions, which are basically nearly all the same.
I changed the chrome options to this, to change flash settings programatically:
chrome_options = webdriver.ChromeOptions()
chrome_options.add_argument("--disable-features=EnableEphemeralFlashPermission")

chrome_prefs = {"profile.default_content_setting_values.plugins": 1,
                "profile.content_settings.plugin_whitelist.adobe-flash-player": 1,
                "profile.content_settings.exceptions.plugins.*,*.per_resource.adobe-flash-player": 1,
                "PluginsAllowedForUrls": "BEST URL EVER"}

chrome_options.add_experimental_option("prefs",chrome_prefs)

driver = webdriver.Chrome(chrome_options=chrome_options, service_log_path='NUL')

driver.get("https://naruto.oasgames.com/de/serverlist")
My second thought was to login to a google account, where Flash settings are enabled.
Unfortunately I can't login to any google account within the opened chrome window.
" This browwser or this app arent save. use an other brwoser which is uspported to login"

Well... anyone had such a similar issue ?

Thanks for your help !
I would like an answer to this as well