View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0012971 | mantisbt | api soap | public | 2011-05-02 11:49 | 2019-12-13 18:06 |
Reporter | MagicBuzz | Assigned To | dregad | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | closed | Resolution | no change required | ||
Product Version | 1.2.5 | ||||
Summary | 0012971: mc_projects_get_user_accessible() produce inconsistant encoded strings | ||||
Description | When you send a wrong login/password threw the mc_projects_get_user_accessible() method, the it returns an error message using an iso-8856-1 encoding while the webservice announce utf-8 encoding. It's blocking for .NET devs as the .NET support of webservices fail and the message error from the webservice is not usable. | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
This sounds pretty annoying. I assume that you mean ISO-8859-1, right? If that is the case, how do you detect the string encoding? AFAIK it only uses characters which overlap with the UTF-8 encoding. |
|
Hello, I can't even read the webservice response at all. PS : I'm using Mantis and my client program on a french computer, with french settings. Exemple : Could become, when mismatching encodings : |
|
I found this in class.nusoap_base.php (in the /library/nusoap folder) :
It looks like the nusoap library has known problems when using UTF-8 encodings. The comments seems to say exactely what happens to me. May be there is an update ? |
|
The problem seems to be (dirty) fixed by changing two times two lines : Line 151 in class.nusoap_base.php : var $soap_defencoding = 'ISO-8859-1'; becomes : //var $soap_defencoding = 'ISO-8859-1'; And line 151 in nusoap.php : var $soap_defencoding = 'ISO-8859-1'; becomes : //var $soap_defencoding = 'ISO-8859-1'; => I don't have the inconsistent charset message anymore. But now I get the problem 0012977 |
|
I am having a hard time reproducing this since both Java and PHP implementations work just fine. Please provide a sample implementation in C# ( preferrably running under Mono ) which fails. It can be whichever is most convenient for you, e.g. a minimal SQL dump of the database and a SOAP invocation. |
|
I uploaded a simple project (source + binaries). The seems not to be culture specific regarding the output I obtain when launching it on this server's webservices with en-US culture : Choose the culture : fr-[F]R or en_[U]S Do you want to [D]isplay the error in the program, or make it [C]rash and see th Hit any key to end the program. |
|
I've tried importing this into monodevelop but am unable to build the solution. The error ( repeated 57 times ) is
Any idea why that happens? |
|
Reminder sent to: vboctor Victor, you should be the best person to look into this. Any thoughts about the .NET SOAP client problems? |
|
I've tried to reproduce with with plain Mono, but was unable to . Here's what I did
MantisConnect m = new MantisConnect(); |
|
I've finally managed to install VS Express and look into this issue. I've reproduced the 'inconsistent' encoding problem, but managed to work around it by adding a 'Web Reference' instead of a 'Service Reference'. I've followed the steps at http://www.sanity-free.com/125/php_webservices_and_csharp_dotnet_soap_clients.html :
I now have a working web service client which works as expected. Please let me know if this works for you as well, I'd like to add it to the reference documentation. |
|
Unassigned after a long time of inactivity. |
|
Considering that this issue was reported on an old version of MantisBT and the problem seems related to the nusoap library which is no longer used in MantisBT since 1.3.0-beta.1 (see 0016444), I'm closing this issue. Feel free to reopen if the error can be reproduced in the latest version. |
|