postnl / postnl-magento1-End-of-life

This is the official Magento 1 extension of PostNL.
12 stars 9 forks source link

[BUG] Error Fetching http body, No Content-Length, connection closed or chunked data #72

Open Martvse opened 2 years ago

Martvse commented 2 years ago

I don't know if this problem is caused by our own Magento environment or if it is the plugin itself. Still, I'm posting it here to help others who may be running into the same problem.

To Reproduce Steps to reproduce the behavior:

  1. Login on the Magento backend as an administrator
  2. Open the sales -> order page
  3. In the order grid, choose a order and do mass action 'PostNL - Maak zendingen aan, print labels en meld voor' and submit the action

Expected result The shipment is created, registered with PostNL and a popup appears with the corresponding labels

Actual result An error is thrown: "Error Fetching http body, No Content-Length, connection closed or chunked data"

Workaround Open Abstract.php in 'app/code/community/TIG/PostNL/Model/Core/Cif' and add the following line to the soapOptions array (after line 389): 'compression' => SOAP_COMPRESSION_ACCEPT | SOAP_COMPRESSION_GZIP | SOAP_COMPRESSION_DEFLATE

This fixed our problem.

Please complete the following information

tig-jeffreybranderhorst commented 2 years ago

Hi @Martvse ,

Thank you for submitting the solution, I will indeed keep it open for future users. The magento 1 module has been end of life for a while. You could contact postnl to ask them to add this to the magento 1 they will decide if they want to add this extra line of code.

Have a great day, Jeffrey