network.request( ...HEAD" = BIG BUG

Hi,

We are facing quite a strange bug.The following code :

    local function onNetworkListenerTimeStamp( event )

        if event.isError then    

            print(“there is an error”)

        elseif ( event.phase == “ended” ) then

            print(“everything is fine”)

        end

    end

    network.request( sourceDate, “HEAD”, onNetworkListenerTimeStamp )

The code work perfectly on IOS devices, Android S3, Kindle Fire, S4 but does not work on Samsung Galaxy Tab 2 tablets ? The version number of Android on the tablet is 4.0.4

The following error is printed by Corona in the console window : ERROR: unexpected end of stream

We have just discover this bug on our production software. The impact is major as no news are displayed in real time because of this.

Any help would be appreciated.

For your information we have also try on the latest Corona build 2014.2368

Can you also print the event.response value to your console and see if there is more information there? 

Unfortunately NIl is returned.

Something else that could maybe help you know where to look, if we do a GET, it is working perfectly, therefore its only the HEAD which is getting the problem.

But on our side, we want to be able to do a HEAD first so we can get the last modified date to perform some date compare before downloading the file.

Nobody ?

I guess we will have no choice to use a separate timestamp file instead of simply using the HEAD command. It is unfortunate as it complicate the code and the process.

This sounds like you can build a repeatable test case.  If so, please file a bug report complete with build.settings and config.lua.  When you get the automated email from the bug tracker, please post the bug report number back to this thread.

Rob

Can you also print the event.response value to your console and see if there is more information there? 

Unfortunately NIl is returned.

Something else that could maybe help you know where to look, if we do a GET, it is working perfectly, therefore its only the HEAD which is getting the problem.

But on our side, we want to be able to do a HEAD first so we can get the last modified date to perform some date compare before downloading the file.

Nobody ?

I guess we will have no choice to use a separate timestamp file instead of simply using the HEAD command. It is unfortunate as it complicate the code and the process.

This sounds like you can build a repeatable test case.  If so, please file a bug report complete with build.settings and config.lua.  When you get the automated email from the bug tracker, please post the bug report number back to this thread.

Rob