I\'m using Selenium Webdriver (in Python) to automate the downloading of thousands of files. I want to set Chrome\'s download folder programmatically. After reading this, I
I think you also need
"directory_upgrade": true
Using the dictionary directly in a Chrome 'Prefrences' file, on a local windows install of chrome Version 28.0.1500.95 m, with the following download options:
"download": {
"default_directory": "C:\\Users\\rdub\\Desktop",
"extensions_to_open": ""
},
I get the default location, versus the desktop. When I change it to this:
"download": {
"default_directory": "C:\\Users\\rdub\\Desktop",
"directory_upgrade": true,
"extensions_to_open": ""
},
I get the desktop location.
Try the following:
desired_caps = {'prefs': {'download': {'default_directory': '/Users/thiagomarzagao/Desktop/downloaded_files/', "directory_upgrade": true, "extensions_to_open": ""}}}