View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0026672 | mantisbt | api soap | public | 2020-02-04 14:04 | 2024-09-28 11:28 |
Reporter | GunSmoker | Assigned To | dregad | ||
Priority | high | Severity | crash | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Product Version | 2.13.0 | ||||
Target Version | 2.26.4 | Fixed in Version | 2.26.4 | ||
Summary | 0026672: mc_issue_add fails with "Object of class SoapFault could not be converted to int" | ||||
Description | It seems that latest versions of Mantis have a regression issue. Issue confirmed on 2.22.1 (see 0026492 ), 2.22.2 (www.mantishub.com / mantishub.io), 2.23.0 (local Apache). Unfortunately, I don't know what previous version of Mantis does not have this issue. Code that worked on previous versions of Mantis now fails. Specifically, mc_issue_add fails with "Object of class SoapFault could not be converted to int". Even if there is a bug in client code, and it sends invalid request - the server MUST respond with a clear failure reason (like "invalid credentials", "required field is not specified", "category not found", etc.), but not with internal crash. The sample XML request for mc_issue_add is specified in "Additional info" below. | ||||
Steps To Reproduce | From Apache logs: Stack Trace: | ||||
Additional Information | <?xml version="1.0" encoding="UTF-8"?> | ||||
Tags | No tags attached. | ||||
Apache logs are for 2.23.0 |
|
Just to clarify - this is a server-side problem, it is not about client side. Apache logs: |
|
I was able to reproduce this problem, attempting to add an Issue with either an invalid Category, or an empty Category when $g_allow_no_category = OFF.
Fatal error: Uncaught SoapFault exception: [SOAP-ENV:Server] Error Type: SYSTEM WARNING, |
|
MantisBT: master-2.26 bcc7cab2 2024-09-20 19:52 Details Diff |
Tests: creating an issue with invalid category Issue 0026672 |
Affected Issues 0026672 |
|
mod - tests/rest/RestIssueTest.php | Diff File | ||
MantisBT: master-2.26 64eca96d 2024-09-20 20:24 Details Diff |
Fix PHP warning in IssueAddCommand When given an invalid Category, or an empty Category when $g_allow_no_category = OFF, mci_get_category_id() returned a SoapFault object instead of throwing a ClientException, resulting in a PHP Warning "Object of class SoapFault could not be converted to int". This affects mc_issue_add() Fixes 0026672 |
Affected Issues 0026672 |
|
mod - api/soap/mc_api.php | Diff File |