Our PDF has been failing to generate for the past 4 hours, It was working ok 12 hours ago and for many days before that. It looks like an issue on your end again.
Below is the error.
“cURL error 18: transfer closed with outstanding read data remaining”
It has been happening at various times. Sometimes it will pull several template pages into the new PDF before it fails.
To add some context, here are the functions it has failed on:
postAppendDocumentWithHttpInfo()
copyFileWithHttpInfo()
deleteFileWithHttpInfo()
@pfrworksite
Can you please share your sample document and code to reproduce the issue? We will further proceed to assist you accordingly.
The outage was resolved on your end after about 24 hours. It’s working fine now.
This can be closed.
Outage AGAIN! We’re getting this error again. It’s been happening for at least 4 hours. We need to look into a replacement for Aspose.
Providing code wouldn’t be helpful as its not consistent on when it fails.
It happens at various times when interacting with files. Here are some examples as to the function running when it fails: putHtmlInStorageToPdf(), writeFromXml(),CreateEmptyDocument()
@pfrworksite
does the error reproduce on any specific files? can you share an example file and the curl command?
it varies. Our process will complete 1 or many files before it fails, so its not a specific file. I can’t provide the specific curl command since its generated by the PHP library we use.
Here is another example of the most recent call that failed:
PdfApiUsage->copyFile(‘template/Busine…’, ‘working/38af007…’)
Here is a full error:
PHP Fatal error: Uncaught Aspose\PDF\ApiException: [401] cURL error 18: transfer closed with outstanding read data remaining (see libcurl - Error Codes) in /src/Aspose/PDF/Api/PdfApi.php:144
Stack trace:
#0 /src/Aspose/PDF/Api/PdfApi.php(109): Aspose\PDF\Api\PdfApi->copyFileWithHttpInfo(‘template/Busine…’, ‘working/38af007…’, NULL, NULL, NULL)
#1 aspose_xml.class.affil.dev.php(829): Aspose\PDF\Api\PdfApi->copyFile(‘template/Busine…’, ‘working/38af007…’)
#2 generate_pdf_from_xml.affil.dev.php(78): PdfApiUsage->copyFile(‘template/Busine…’, ‘working/38af007…’)
#3 {main}
thrown in /src/Aspose/PDF/Api/PdfApi.php on line 144
@pfrworksite
I have reported the issue for further investigation and fix. We will notify you once these issues are resolved.
I was able to add a debug statement to the code. i hope this helps:
- Found bundle for host api.aspose.cloud: 0x55de87c4ccb0 [can pipeline]
- Re-using existing connection! (#1) with host api.aspose.cloud
- Connected to api.aspose.cloud (74.113.210.20) port 443 (#1)
PUT /v3.0/pdf/storage/file//working/xml/33909033aa.xml HTTP/1.1
Host: api.aspose.cloud
User-Agent: aspose pdf cloud sdk
Accept: application/json
Authorization: Bearer removed****
Content-Length: 1695
- upload completely sent off: 1695 out of 1695 bytes
< HTTP/1.1 401 Unauthorized
< date: Fri, 02 May 2025 18:20:02 GMT
< content-type: application/json
< transfer-encoding: chunked
< x-cluster: cloud-01
< x-lb: TLR
< - transfer closed with outstanding read data remaining
- stopped the pause stream!
- Closing connection 1
I concur. It appears to be fixed. Thank you!