'Where does the downloaded file go when execute robot framework using Jenkins

I need one help, I am Executing a script of robot framework using Jenkins, as per the flow the script should download one XLS and validate the data using Pandas.

When I am executing the script using Jenkins and searching the downloaded file in a hardcoded path i.e. "C:\Users\Administrator\Downloads" the file is not found. but when executing it manually the file downloaded on the same path

Can anyone please help me by telling me where do Jenkins stores all the downloaded files?

PS : I am using Google Chrome as web browser



Solution 1:[1]

For each job Jenkins runs, it creates a workspace directory, usually at: $JENKINS_HOME/workspace/(Name of the Job)

The scripts (and robotframework's in this case) are run there, as the root directory. Most probably the downloaded file will be in a path from there (or an error should have occurred because the Jenkins user does not have access to the C:\Users... path).

There is a step in the Jenkins job, which is to archive (download) files from workspace, to Jenkins database, to be shown as "artifacts". Even the screenshots images or videos recording, must be registered in that step, so they can be viewed on the Report and Log in Jenkins (Robot Framework Plugin).

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Helio