gpt4 book ai didi

php - 以前通过 TWILIO 发送 SMS 消息的工作调用现在失败了... "Unsupported SSL context options are set."

转载 作者:太空宇宙 更新时间:2023-11-03 13:27:55 27 4
gpt4 key购买 nike

这一段时间以来一直运行良好,我没有做任何更改。该代码在 Google AppEngine 上运行,它可能在过去 12 小时内更改了某些内容会导致此问题??

完整的错误信息:

HP Warning: file_get_contents(https://api.twilio.com/2010-04-01/Accounts/AC3f5788e1bf9a85f308ed805dc57b1111/Messages.json): failed to open stream: Unsupported SSL context options are set. The following options are present, but have been ignored: cafile, verify_depth Request deadline exceeded in /base/data/home/apps/s~vivonoteapp/1.371473117917944991/twilio-php-master/Services/Twilio/HttpStream.php on line 62

顺便说一句,这里是上面引用的第 62 行(自运行以来没有变化):

$result = file_get_contents($url, false, $ctx);

这是导致第 62 行被调用的我的代码(自运行以来没有变化):

$sms = $client->account->messages->sendMessage(get_twilio_number(), // FROM
$sender, // TO
$msg);

感谢任何想法。丽兹

最佳答案

实际错误是“超出请求截止日期”,其他消息是警告,让您知道您提供的某些 SSL 选项未被 URLFetch 实现使用。

您可以尝试通过传递更大的 timeout value 来延长请求的截止日期在您传递给 stream_context_create 的 http 选项中。

$options = [ 
'http' => [
'timeout' => 60.0,
],
];

此外,昨天出现了 URLFetch 中断,这也可以解释您的问题。详情 here .

关于php - 以前通过 TWILIO 发送 SMS 消息的工作调用现在失败了... "Unsupported SSL context options are set.",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19843149/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com