Skip to content

FileSystem.CopyFile Success or Fail #11393

@scubaman120

Description

@scubaman120

Dynamo version

2.3.0.5885

Operating system.

Windows 10

What did you do?

File System.CopyFile will output null regardless if it works or fails.

image

What did you expect to see?

It would be nice if it exported true for files that were successfully copied and false for files that were not copied.

image

import shutil

original = IN[0]
target = IN[1]

List = [] 
for o, t in zip(original,target):
	try:
		shutil.copyfile(o, t)
		List.append(True)
	except:
		List.append(False)
		
OUT = List

What did you see instead?

null

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions