HTTP POST doesn't work on x86 windows build (works on all others)

The title basically says it all…

I have an application in which I need to HTTP post something to a server on a local network (I use IP and not a name in case it’s important for any reason…).

It works well in a browser, on Android and also on Windows arm phone. But not on windows x86. I get an error (immediately, so it’s not a timeout):

Http failure response for (unknown url): 0 Unknown Error

Also, I am absolutely sure it did work before. And I don’t think I changed anything in the code. I have also tried going back to older commits to verify this, but at this point none of them works.

And it’s not a firewall. I even tried to turn it off for a while, but it didn’t help.

Any ideas?

Try googling ‘Http failure response for (unknown url): 0 Unknown Error’

Well, of course I have tried that… I decided to post here because all the people having those kinds of problems either say it’s SSL ceritficate issue or CORS issue.

In my case, it cannot be SSL because i use HTTP and not HTTPS and it shouldn’t be CORS because from all the other platforms including Windows on arm it simply works…

I will however try to get more verbose server output so that I know whether the request reaches the server or not.

//EDIT: No, the request definitely doesn’t reach the server. Thus it shouldn’t be CORS, right?
I added some logging to the server, and I get the logs when I connect from Android, browser, Windows Phone… But I don’t get any log when connecting from the x86 windows build. Again, it used to work before…

You haven’t posted any source code? Or the output from ionic info?

Do you use HttpClient?

See:

Do you explicitly set the content type?

See:

Does your API server support HTTP OPTIONS method?

See:

Well, I didn’t post any code, because the POST request is as generic as you can get:

this.httpClient.post('http://172.24.1.1:8080/content.json', JSON.stringify(body), { headers: { 'Content-Type': 'application/json' } }).timeout(2000)    
    .subscribe(data => {            
      console.log('success'); 
    }, error => {
      console.log('error');
      console.log(error);
    });

And yet again, it works on everything except x86 windows build, that is, it shouldn’t be server related…

Anyway, I’ll look for at the links you posted and see if there’s any hint…

Thanks

I have a new info…

I get the same error when running Ionic serve from Edge (normally I use Firefox). I incidentally found out, that this one is solved by switching the WiFi network type from private to public (yes, from private to public - one would expect it to be the other way around…). But the UWP packed version still doedn’t send HTTP POST even on public network.

May have something to do with:

//EDIT: It even seems to work in debug mode, but not in release mode…

May have something to do with:
https://cordova.apache.org/docs/en/5.4.0/guide/platforms/win8/win10-support.html

The following capabilities are unavailable when deploying your Remote Mode application to the Windows Store