这是我所拥有的代码的一部分,这部分代码与通过称为telesign的API发送SMS相对应。如果我从Pycharm运行该代码,则该代码运行正常,该SMS发送时没有任何类型的问题,但是当我运行pyinstaller结束我的项目时,它给了我一个特定的错误,如下所示:
from telesign.messaging import MessagingClient
customer_id = "2170F10E-D4FB-4C0F-8252-A4C32ECD459B"
api_key = "I8qrRIlwrIjrUxTNA0otl9TSfktjsDuz7VzFnFGS0CFdEzT4MIJbje75XU4OsX5LmtiPBXiytAF+xQ8Sd+yiDA=="
phone_number = "5352659475"
message = "alerta"
message_type = "ARN"
messaging = MessagingClient(customer_id, api_key)
response = messaging.message(phone_number, message, message_type)
当我运行pyinstaller时,出现此错误
The telesign distribution was not found and is required by the application with pyinstaller
如您所见,它与找不到与Telesign相关的东西有关。