View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0014916 | Mylyn Connector | Build | public | 2012-11-04 11:29 | 2017-02-14 15:30 |
| Reporter | rombert | Assigned To | |||
| Priority | normal | Severity | minor | Reproducibility | always |
| Status | acknowledged | Resolution | open | ||
| Product Version | 3.8.0 | ||||
| Target Version | Backlog | ||||
| Summary | 0014916: Synchronization error due to deleted user in Mantis | ||||
| Description | A user (let's call it "UserX") had been deleted in Mantis. java.lang.IllegalArgumentException: Null name for MantisUser with id 17 Additional details below I tried to modity mc_account_api.php in Mantis to handle deleted users (see attachment) but the problem remains. | ||||
| Additional Information | Complete error stack trace : java.lang.IllegalArgumentException: Null name for MantisUser with id 17 | ||||
| Tags | No tags attached. | ||||
| Attached Files | |||||
|
Interesting, let's see if there is something which can be done in the Eclipse client . Otherwise we'll send this to the mantisbt.org bugtracker |
|
|
Original note author: jeckyhl I found why my first correction in Mantis SOAP API didn't worked (see attachment mc_account_api (v2).php.patch). The trick is to return a fake username like 'userXX' where XX is the id of the deleted user (this is done by method user_get_name in user_api.php). Yet I'm not sure this is the right way to fix this issue. |
|
|
Originally reported at https://sourceforge.net/apps/mantisbt/mylyn-mantis/view.php?id=259 by jeckyhl mc_account_api.php.patch (472 bytes)
Index: mc_account_api.php
===================================================================
--- mc_account_api.php (r�vision 851)
+++ mc_account_api.php (copie de travail)
@@ -11,7 +11,7 @@
$t_result['id'] = $p_user_id;
if( user_exists( $p_user_id ) ) {
- $t_result['name'] = user_get_field( $p_user_id, 'username' );
+ $t_result['name'] = user_get_name( $p_user_id );
$t_dummy = user_get_field( $p_user_id, 'realname' );
if( !empty( $t_dummy ) ) {
mc_account_api (v2).php.patch (554 bytes)
Index: mc_account_api.php
===================================================================
--- mc_account_api.php (r�vision 851)
+++ mc_account_api.php (copie de travail)
@@ -9,9 +9,10 @@
function mci_account_get_array_by_id( $p_user_id ) {
$t_result = array();
$t_result['id'] = $p_user_id;
-
+ $t_result['name'] = user_get_name( $p_user_id );
+
if( user_exists( $p_user_id ) ) {
- $t_result['name'] = user_get_field( $p_user_id, 'username' );
+
$t_dummy = user_get_field( $p_user_id, 'realname' );
if( !empty( $t_dummy ) ) {
|
|