Chinesecalendar is a module for judging whether the date type of date is a working day or a holiday in python. First install the module pip install chinesecalendar. The usage of the imported module is as follows:
import datetime
from chinese_calendar import is_workday
da = datetime.date(2019,1,2)
boll = is_workday(da)
print(boll)
The output result is a bool value, True is a working day, and False is a rest day.