1

I am trying to copy files to a location which requires access permissions(has UserID and Password to access the folder).

Is there a parameter or any special command to copy files to location which requires UserId and password?

Currently, I am using shutil.copy2 to copy files but getting below error:

PermissionError: [Errno 13] Permission denied:
Pranav Choudhary
  • 2,726
  • 3
  • 18
  • 38

1 Answers1

1

When you get that error, it could mean that you are trying to copy a file that is currently in use, like it's open, or your program opened but haven't closed it. Check to make sure it's closed.

If your file are log files, this might help:

Red
  • 26,798
  • 7
  • 36
  • 58