This issue happened for the first time on 2017.3, works on previous version.
When I call the simple code below or for any other url the yield takes long time and returns always HTTP/1.1 500 Internal Server Error. I can assure that there is no server error, works on any other Unity version and works on any POST tool. The network flow from Fiddler shows some weird content from Unity WWW with form:
WWWForm wwwForm = new WWWForm();
wwwForm.AddField("data", enc);
using (www = new WWW(url, wwwForm))
{
yield return www;
}
I have used Fiddler to check what is being sent and as shown below it has invalid data on the body and no Content-Length (I have ommited part of the url):
This request is invalid and causes the server Internal Error, on previous versions everything works as expected and the network request is created successfully.
It is to me a critical issue as i have several dependencies with network that are not running.
It’s an issue with WWW class, not WWWForm, the later can be used with UnityWebRequest too.
It will take at least a couple of weeks to release a fix, can’t really promise though, it depends on QA etc.
Do you know if it is Windows only or all platforms? I have some plugins for iOs and Mac using WWW and wouldn’t like to update all of them because that get updated all the time and I would have to modify again.
It’s cross-platform issue. Chunked transfer was accidentally enabled in WWW class and now we started to see how many servers don’t support that yet.
Yes, unfortunately there are many yet. Mine is on Azure and by default disabled, to enable it we need a complete new release, what is not so nice on Azure.
If you guys add the parameter to enable chunked transfer as on WebRequest, with a default false value, WWW will be perfect =).
I’m having a similar issue. I’m submitting a request initialized with WWW and WWWForm to a server I’m hosting locally with Django. The server isn’t receiving any of my POST variables. It was working fine before I upgraded to 2017.3. I think the version I was using before was 2017.1.
Hi,
Just stumbled across this thread after posting a very similar question in the HelpRoom forum.
I’ve now changed my code in the appropriate places from using the WWW class to use the UnityWebRequest class. However it still doesn’t work. Why: Because in Unity 2017.3.0, I can’t change the UnityWebRequest.chunkedTransfer property! Meaning I can’t set it to false.
Going back to Unity 2017.2.1 I can set the chunkedTransfer property to false without any problems and the UnityWebRequest then works like a charm.
Can you please escalate these bugs to be fixed asap? This bug is critical, as in this current state Unity 2017.3.0 is completely useless to me.
Really? That’s strange. It hasn’t been working for me all day. I can set the properties UnityWebRequest.url, UnityWebRequest.timeout and UnityWebRequest.method etc.etc.
But with UnityWebRequest.chunkedTransfer and UnityWebRequest.useHttpContinue to true the value in the my debugger (Visual Studio 2017) remains false.
Guess what happens: Even after explicitly setting it to false I pass into the if statement. In the debugger the value is still depicted as being true and the code behaves that way as well.
In Unity 2017.2.1 however everything behaves as expected.
I haven’t used the debugger, I just replaced WWW to UnityWebRequest, set chunked to false and ran, and the POST worked. Then i haven’t needed to debug.
Sadly it didn’t work for me. So I’ve had to revert to Unity 2017.2.1.
This version seems to work fine for me. But I did want to take advantage of the latest Windows Mixed Reality features and native VR support.
(Currently I’m porting one of our older apps from Unity 5.6.0 to the latest Unity 2017 version. That’s why I’m refactoring all the code that used the WWW class to using the UnityWebRequest class.)