Error load python script

hello everyone,i met a problem when i use “load python script” activity.
I can run the python script well with cmd. And the python script can also run well at pyCharm software.Besides, i checked , there’s no chinese or chinese charator in the python script.
Is there any other reason for this problem.
Thanks for your help.

The following codes are my python script:
#!/usr/bin/python3

encoding: utf-8

from openpyxl import load_workbook # Access excel workbook
import win32com.client as win32 # Change excel suffix
import pandas as pd # operate excel
import datetime # Custom Date Format in excel
import os # Processing files and directories
import shutil # copy file
import sys

current_sheet = str(datetime.datetime.now().strftime(‘%Y%m’))
current_date = str(datetime.datetime.now().strftime(‘%Y%m%d’))
“”"
operate_excel_BSH():delete row 1-9,11 from BSH.xlsx,delete column A,D,insert column E.
Rename the title of column E with “New invoice”,value of column E equal F/D.
Compare current BSH.xlsx with the latest invoice file and delete duplicate rows.
Delete row of data when value of column H equal ‘O’ or ‘N’ or the value type of column B not equal int
“”"

def operate_excel_BSH(bsh_invoice_path):
# change_excel_name from “BSH.xls” to “BSH.xlsx”
file_xls = “C:\BSH_EXCEL\BSH.xls”
excel = win32.gencache.EnsureDispatch(‘Excel.Application’)
wb = excel.Workbooks.Open(file_xls)
wb.SaveAs(file_xls + “x”, FileFormat=51)
wb.Close()
excel.Application.Quit()

# get_newest_file from specified folder path
nameList = []
for file in os.listdir(bsh_invoice_path):
    nameList.append(file[12:20])
newest_file = ""
for filename in nameList:
    if filename > newest_file:
        newest_file = filename
newest_file = "BSH Invoice " + newest_file + ".xlsx"

# delete row 1-9,11 from BSH.xlsx,delete column A,D
bsh = pd.DataFrame(pd.read_excel('C:\BSH_EXCEL\BSH.xlsx', sheet_name='BSH', header=None))
bsh1 = bsh.drop(bsh.index[[0, 1, 2, 3, 4, 5, 6, 7, 8, 10]])
bsh2 = bsh1.iloc[:, [1, 17, 18, 22, 7, 27, 28, 29, 19]]
bsh2.to_excel('C:\BSH_EXCEL\BSH.xlsx', sheet_name='BSH', index=False, header=False)

# insert column E.Rename the title of column E with "New invoice",value of column E equal F/D
file1 = load_workbook("C:\BSH_EXCEL\BSH.xlsx")
ws1 = file1.active
ws1.insert_cols(idx=5)
ws1.cell(1, 5, "New invoice")
x = 2
while x <= ws1.max_row:
    ws1.cell(x, 5, value=ws1.cell(x, 6).value / ws1.cell(x, 4).value)
    x += 1

# compare current BSH.xlsx with the latest invoice file and delete duplicate rows.
file_wk = load_workbook(bsh_invoice_path + "\\" + newest_file)
wk = file_wk[newest_file[12:18]]
max_cell = 1
for i in range(2, wk.max_row + 1):
    if wk.cell(row=i, column=1).value > max_cell:
        max_cell = wk.cell(row=i, column=1).value
count = 0
for row in ws1.iter_rows(min_col=1, max_col=1, min_row=2, max_row=""):
    for cell in row:
        if cell.value != max_cell:
            count += 1
        else:
            ws1.delete_rows(2, count + 1)
            break
file1.save("C:\BSH_EXCEL\BSH.xlsx")

# Delete row of data when value of column H equal 'O' or 'N' or the value type of column B not equal int
max_row = ws1.max_row
row_id = 1
while row_id < max_row:
    row_id += 1
    if type(ws1.cell(row=row_id, column=2).value) != int or ws1.cell(row=row_id, column=8).value != "M":
        ws1.delete_rows(idx=row_id)
        row_id -= 1
        max_row -= 1
file1.save("C:\BSH_EXCEL\BSH.xlsx")

# Change the date format of column G to 'mm/dd/yyyy'
for i in range(2, max_row + 1):
    if type(ws1.cell(row=i, column=7).value) == datetime.datetime:
        time = ws1.cell(row=i, column=7).value.timetuple()
        Versioninfo = str(time.tm_mon) + "/" + str(time.tm_mday) + "/" + str(time.tm_year)
        ws1.cell(row=i, column=7, value=Versioninfo)
file1.save("C:\BSH_EXCEL\BSH.xlsx")
"""
create a new excel at specified folder and copy column A-F and Column G from BSH.xlsx to Column A-F and Column K of this new excel.Then Input current date in Column M _Invoice date
"""
# Initialize a new file path 'bsh_invoice_path\BSH Invoice (current_date).xlsx'
newfile = bsh_invoice_path + "\\BSH Invoice " + current_date + ".xlsx"

# copy file BSH Invoice.xlsx from './file/' to 'K:\Finance\Li xia\Customer list\BSH Jiangsu\RPA\BSH invoice\'
shutil.copy('./file/BSH Invoice.xlsx', newfile)

# Copy column A-F and Column G from BSH.xlsx to Column A-F and Column K of 'BSH Invoice (current_date).xlsx'
file_bsh = load_workbook("C:\BSH_EXCEL\BSH.xlsx")
file_bshk = load_workbook(newfile)
ws = file_bsh.active
time = datetime.datetime.now().timetuple()
current_sheet1 = str(time.tm_mon) + "/" + str(time.tm_mday) + "/" + str(time.tm_year)
ws1 = file_bshk["Sheet1"]
ws1.title = current_sheet
ws1 = file_bshk[current_sheet]
i = 1
j = 0
for row in ws.iter_rows(min_row=2, max_row="", min_col=1, max_col=6):
    i += 1
    for cell in row:
        j += 1
        ws1.cell(row=i, column=j, value=cell.value)
    j = 0
i = 1
for row in ws.iter_rows(min_row=2, max_row="", min_col=7, max_col=7):
    i += 1
    for cell in row:
        ws1.cell(row=i, column=11, value=cell.value)
        ws1.cell(row=i, column=13, value=current_sheet1)
file_bshk.save(newfile)

# sorting,Disorder columns H,like Z->A
bsh = pd.DataFrame(pd.read_excel('C:\BSH_EXCEL\BSH.xlsx', sheet_name='BSH'))
bsh.sort_values(by='DocCa', ascending=False, inplace=True)
bsh.to_excel('C:\BSH_EXCEL\BSH.xlsx', sheet_name='BSH', index=False)