deleteing a directory in python code example
Example 1: python dlete folder
import shutil
shutil.rmtree('/folder_name')
Example 2: delete contents of directory python
import os
import glob
files = glob.glob('/YOUR/PATH/*')
for f in files:
os.remove(f)