YurunHttp icon indicating copy to clipboard operation
YurunHttp copied to clipboard

YurunHttp 是开源的 PHP HTTP 客户端,支持链式操作,简单易用。完美支持Curl、Swoole 协程。QQ群:17916227

Results 6 YurunHttp issues
Sort by recently updated
recently updated
newest added

$httpRequest->retry($retryTimes); 期望改成 $httpRequest->retry(funtion($httpClient) use(xx){}, $retryTimes); 实际使用过程,如爬虫抓取,需要修改header信息来避免失败。如果可以,最好是可以定制失败重试的条件。目前的retry是针对500这种代码,显得用处不大。

enhancement

可以记录请求的日志吗

enhancement

当ws_clients 和服务器端的连接状态有变化时候,isConnected不能准确返回正确的值,导致产生错误,望大佬能修正下。 ` =ws_clients客户端==1==1========= PHP Fatal error: Uncaught Yurun\Util\YurunHttp\Exception\WebSocketException: Send Failed, error: Client no connection, errorCode: 5001 in /home/wwwroot/html_88001/vendor/yurunsoft/yurun-http/src/YurunHttp/WebSocket/Swoole.php:130 Stack trace: #0 /home/wwwroot/html_88001/vos_server_o.php(636): Yurun\Util\YurunHttp\WebSocket\Swoole->send() #1 [internal function]: server->{closure}() #2 {main}...

bug详情请看:https://github.com/Yurunsoft/YurunHttp/issues/34

**bug地址:** https://github.com/Yurunsoft/YurunHttp/blob/df62abcb81166f4fa1a1eca426cd0b6792b0edce/src/YurunHttp/Handler/Curl.php#L738 **当前代码:** ```php $this->buildCurlHandlerBase($request, $curlHandler, $recvHeaders[$k], $saveFileFps[$k]); $files = $request->getUploadedFiles(); $body = (string) $request->getBody(); if (!empty($files)) { $body = FormDataBuilder::build($body, $files, $boundary); $request = $request->withHeader('Content-Type', MediaType::MULTIPART_FORM_DATA . '; boundary='...