We are aware of the issue with the badge emails resending to everyone, we apologise for the inconvenience - learn more here.

Forum Discussion

Adi4's avatar
Adi4
Explorer | Level 3
12 months ago

Through error in Copy File Operation

Hello!
I perform copy operation like this:
FROM_PATH = /sure/copyfile
TO_PATH = /sure/automat

sure is main folder inside sure there are two file copyfile and automat. In copyfile has a pic that I want to copy in automat, automat is empty but it trough this error.

Exception in 2/files/copy_v2: {".tag":"to","to":{".tag":"conflict","conflict":"folder"}}
Reason:
Snap failed unexpectedly and did not provide any reason
Hide Details...
SnapCompletionService
com.dropbox.core.v2.files.RelocationErrorException: Exception in 2/files/copy_v2: {".tag":"to","to":{".tag":"conflict","conflict":"folder"}}
 
When I change the of TO_PATH like  /sure/[Different name]  then it work and make new file and copy file in [Different name]
How I removed this error and why it through this error when their is nothing duplicate in receiving file.
Thank You!
  • Adi4 As Здравко said, your destination path should include the destination file name as well, not just the parent folder.

     

    So for example, it sounds like what you actually want is something like this instead:

    TO_PATH = /sure/automat/copyfile

  • Adi4 As Здравко said, your destination path should include the destination file name as well, not just the parent folder.

     

    So for example, it sounds like what you actually want is something like this instead:

    TO_PATH = /sure/automat/copyfile

  • Здравко's avatar
    Здравко
    Legendary | Level 20

    Hi Adi4,

    The behaviour, you described, is something normal (strange would be different one). When you copy something (either file or folder) the destination should not exist! It will be created on copying. When destination exists (folder in particular case), the error you're receiving is something normal. If you want to copy the contained file, better point it both in source and destination path. 😉 If, by any chance, multiple files have to be copied, use batch version of 'copy'.

    Hope this helps.