The chrome driver is not downloading files on headless mode

1,158 views
Skip to first unread message

rpol...@intellisys.com.do

unread,
Oct 4, 2019, 4:59:43 PM10/4/19
to ChromeDriver Users
So I'm trying to download a file. it works with head but not with the headless mode, don't know what is happening.. I'm using c# selenium for this

John Chen

unread,
Oct 4, 2019, 5:06:00 PM10/4/19
to rpol...@intellisys.com.do, ChromeDriver Users
Which version of ChromeDriver are you using, and on what platform? File download in headless mode is a new feature, and requires ChromeDriver 77 on Windows and Linux, or ChromeDriver 79 (not yet released) on Mac.

On Fri, Oct 4, 2019 at 1:59 PM <rpol...@intellisys.com.do> wrote:
So I'm trying to download a file. it works with head but not with the headless mode, don't know what is happening.. I'm using c# selenium for this

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-us...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/chromedriver-users/f0615a56-4b8d-480a-a9c1-a2cb33bb0497%40googlegroups.com.

rodwelpola...@gmail.com

unread,
Oct 5, 2019, 1:23:16 PM10/5/19
to ChromeDriver Users
I'm using the 78 version of chromium I'm using windows as well

John Chen

unread,
Oct 7, 2019, 12:48:22 PM10/7/19
to rodwelpola...@gmail.com, ChromeDriver Users
Could you show us how you were configuring download in your app, and how were you starting the download?

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-us...@googlegroups.com.

rpol...@intellisys.com.do

unread,
Oct 7, 2019, 3:30:23 PM10/7/19
to ChromeDriver Users
This is my configuration:

_chromeOptions.AddUserProfilePreference("download.default_directory", @"Folder to download");
_chromeOptions.AddUserProfilePreference("intl.accept_languages", "nl");
_chromeOptions.AddUserProfilePreference("disable-popup-blocking", "true");
_webdriver = new ChromeDriver(_chromeOptions);

On Monday, October 7, 2019 at 12:48:22 PM UTC-4, John Chen wrote:
Could you show us how you were configuring download in your app, and how were you starting the download?

On Sat, Oct 5, 2019 at 10:23 AM <rodwelpola...@gmail.com> wrote:
I'm using the 78 version of chromium I'm using windows as well

El viernes, 4 de octubre de 2019, 16:59:43 (UTC-4), rpol...@intellisys.com.do escribió:
So I'm trying to download a file. it works with head but not with the headless mode, don't know what is happening.. I'm using c# selenium for this

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-users+unsub...@googlegroups.com.

John Chen

unread,
Oct 7, 2019, 3:53:38 PM10/7/19
to rpol...@intellisys.com.do, ChromeDriver Users
The code looks correct to me, so I don't know why it doesn't work. Are you using ChromeDriver 78? Do you mind sharing verbose log from ChromeDriver?

On Mon, Oct 7, 2019 at 12:30 PM <rpol...@intellisys.com.do> wrote:
This is my configuration:

_chromeOptions.AddUserProfilePreference("download.default_directory", @"Folder to download");
_chromeOptions.AddUserProfilePreference("intl.accept_languages", "nl");
_chromeOptions.AddUserProfilePreference("disable-popup-blocking", "true");
_webdriver = new ChromeDriver(_chromeOptions);

On Monday, October 7, 2019 at 12:48:22 PM UTC-4, John Chen wrote:
Could you show us how you were configuring download in your app, and how were you starting the download?

On Sat, Oct 5, 2019 at 10:23 AM <rodwelpola...@gmail.com> wrote:
I'm using the 78 version of chromium I'm using windows as well

El viernes, 4 de octubre de 2019, 16:59:43 (UTC-4), rpol...@intellisys.com.do escribió:
So I'm trying to download a file. it works with head but not with the headless mode, don't know what is happening.. I'm using c# selenium for this

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-us...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-us...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/chromedriver-users/8c7b84e6-9243-4632-a8dd-4ff25830e5d4%40googlegroups.com.

rpol...@intellisys.com.do

unread,
Oct 7, 2019, 6:02:58 PM10/7/19
to ChromeDriver Users
In the code appears that is version 77.

(Session info: chrome=77.0.3865.90)


On Monday, October 7, 2019 at 3:53:38 PM UTC-4, John Chen wrote:
The code looks correct to me, so I don't know why it doesn't work. Are you using ChromeDriver 78? Do you mind sharing verbose log from ChromeDriver?

On Mon, Oct 7, 2019 at 12:30 PM <rpol...@intellisys.com.do> wrote:
This is my configuration:

_chromeOptions.AddUserProfilePreference("download.default_directory", @"Folder to download");
_chromeOptions.AddUserProfilePreference("intl.accept_languages", "nl");
_chromeOptions.AddUserProfilePreference("disable-popup-blocking", "true");
_webdriver = new ChromeDriver(_chromeOptions);

On Monday, October 7, 2019 at 12:48:22 PM UTC-4, John Chen wrote:
Could you show us how you were configuring download in your app, and how were you starting the download?

On Sat, Oct 5, 2019 at 10:23 AM <rodwelpola...@gmail.com> wrote:
I'm using the 78 version of chromium I'm using windows as well

El viernes, 4 de octubre de 2019, 16:59:43 (UTC-4), rpol...@intellisys.com.do escribió:
So I'm trying to download a file. it works with head but not with the headless mode, don't know what is happening.. I'm using c# selenium for this

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-users+unsub...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-users+unsub...@googlegroups.com.

John Chen

unread,
Oct 7, 2019, 6:56:05 PM10/7/19
to rpol...@intellisys.com.do, ChromeDriver Users
Looks like you're running into https://crbug.com/chromedriver/3106. _chromeOptions.AddUserProfilePreference("download.default_directory", @"Folder to download") doesn't work in ChromeDriver 77. You need something slightly more verbose:

        Dictionary<string, string> downloadInfo = new Dictionary<string, string>();
        downloadInfo["default_directory"] = @"Folder to download";
        _chromeOptions.AddUserProfilePreference("download", downloadInfo);

This issue is fixed in ChromeDriver 78. Sorry about the inconvenience.

On Mon, Oct 7, 2019 at 3:03 PM <rpol...@intellisys.com.do> wrote:
In the code appears that is version 77.

(Session info: chrome=77.0.3865.90)


On Monday, October 7, 2019 at 3:53:38 PM UTC-4, John Chen wrote:
The code looks correct to me, so I don't know why it doesn't work. Are you using ChromeDriver 78? Do you mind sharing verbose log from ChromeDriver?

On Mon, Oct 7, 2019 at 12:30 PM <rpol...@intellisys.com.do> wrote:
This is my configuration:

_chromeOptions.AddUserProfilePreference("download.default_directory", @"Folder to download");
_chromeOptions.AddUserProfilePreference("intl.accept_languages", "nl");
_chromeOptions.AddUserProfilePreference("disable-popup-blocking", "true");
_webdriver = new ChromeDriver(_chromeOptions);

On Monday, October 7, 2019 at 12:48:22 PM UTC-4, John Chen wrote:
Could you show us how you were configuring download in your app, and how were you starting the download?

On Sat, Oct 5, 2019 at 10:23 AM <rodwelpola...@gmail.com> wrote:
I'm using the 78 version of chromium I'm using windows as well

El viernes, 4 de octubre de 2019, 16:59:43 (UTC-4), rpol...@intellisys.com.do escribió:
So I'm trying to download a file. it works with head but not with the headless mode, don't know what is happening.. I'm using c# selenium for this

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-us...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-us...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "ChromeDriver Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromedriver-us...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/chromedriver-users/c35c5706-b01b-4235-acf6-6b30d7ce3f68%40googlegroups.com.

Debanjan Bhattacharjee

unread,
Oct 9, 2019, 5:03:16 AM10/9/19
to John Chen, rpol...@intellisys.com.do, ChromeDriver Users
Reply all
Reply to author
Forward
0 new messages