Import error while previewing the customized print format in PDF

Hi, Team
I am new to ERPNext and Frappe. I am playing around the print form builder to create a new print form for the quotation. After I adjust something in the format, While trying to preview the print format with PDF format, it shows below error, while it works in the html format preview, any hint on this?
Thanks.

Traceback (most recent call last):
File “apps/frappe/frappe/app.py”, line 110, in application
response = frappe.api.handle(request)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/api/init.py”, line 49, in handle
data = endpoint(**arguments)
^^^^^^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/api/v1.py”, line 36, in handle_rpc_call
return frappe.handler.handle()
^^^^^^^^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/handler.py”, line 49, in handle
data = execute_cmd(cmd)
^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/handler.py”, line 85, in execute_cmd
return frappe.call(method, **frappe.form_dict)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/init.py”, line 1672, in call
return fn(*args, **newargs)
^^^^^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/utils/typing_validations.py”, line 31, in wrapper
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/utils/weasyprint.py”, line 15, in download_pdf
pdf = generator.render_pdf()
^^^^^^^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/utils/weasyprint.py”, line 112, in render_pdf
HTML, CSS = import_weasyprint()
^^^^^^^^^^^^^^^^^^^
File “apps/frappe/frappe/utils/weasyprint.py”, line 246, in import_weasyprint
from weasyprint import CSS, HTML
ImportError: cannot import name ‘CSS’ from ‘weasyprint’ (apps/frappe/frappe/utils/weasyprint.py)