View Issue Details

IDProjectCategoryView StatusLast Update
0011449mantisbtbugtrackerpublic2010-02-22 14:34
Reporteryw84ever Assigned Todhx  
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
Product Versiongit trunk 
Target Version1.2.0Fixed in Version1.2.0 
Summary0011449: application error 0000401 when resolving as a duplicate
Description

running mantis-1.2.x, currently at commit 237ce0568c1e6b760f0d09597c9ed8d537c3b3aa

wanted to mark a ticket as resolved, resolving as a duplicate and entering a duplicate mantis issue number

doing so resulted in application error 401; complains about bug_monitor, as shown in the attachment

while at view.php, i marked the ticket as a duplicate then changed its status to resolved, which worked fine

Additional Information

bug_update.php

TagsNo tags attached.
Attached Files
apperror401.png (8,237 bytes)   
apperror401.png (8,237 bytes)   

Relationships

related to 0011375 closeddhx Users that are monitoring a bug should be transferred if the bug is closed as a duplicate 
has duplicate 0011477 closeddhx Copying issue throws APPLICATION ERROR 0000401 

Activities

yw84ever

yw84ever

2010-02-02 06:43

reporter   ~0024281

I wonder if this has to do with the changes from 0011375

yw84ever

yw84ever

2010-02-02 06:45

reporter   ~0024282

no users listed as monitoring either of the tickets

jreese

jreese

2010-02-04 13:55

reporter   ~0024317

Reminder sent to: dhx

David, could you please look into this issue?

jreese

jreese

2010-02-04 13:56

reporter   ~0024318

I've confirmed this behavior on one of my trackers that has been updated to latest 1.2.x from Git.

yw84ever

yw84ever

2010-02-05 03:20

reporter   ~0024325

git bisect points to

8a9f6d0593d78bc7b4cbe47c0444ba0d50d05fa2 is first bad commit
commit 8a9f6d0593d78bc7b4cbe47c0444ba0d50d05fa2
Author: David Hicks <hickseydr@optusnet.com.au>
Date: Fri Jan 15 21:04:47 2010 +1100

Fix 0011375: Copy list of users monitoring duplicate bug to original bug

If a bug X is resolved as being a duplicate of bug Y, any users that are
monitoring bug X should automatically start monitoring bug Y (if they
aren't already).

This solution isn't perfect because it's still possible to manually add
a &quot;duplicate&quot; relationship within the relationship table or use
bug_update_page.php to manually resolve an issue as being a duplicate.

This copying of the bug monitor list thus only occurs when
bug_resolve(...) is called - ie. when a bug is resolved using the bug
status dropdown and a duplicate bug ID is provided on the following
bug_change_status_page.php page.

A new bug_monitor_copy( source_bug_id, destination_bug_id ) function has
been placed into bug_api.php for use in other cases too. Currently the
only other use of this function is when copying/cloning a bug.

One may wonder why a call to bug_monitor_copy() isn't made somewhere
within relationship_api.php to catch all cases where a duplicate
relationship is created. The reason is to do with maintaining low
coupling - relationship API shouldn't need to know about the logic of
duplicate bugs and bug monitoring lists.

Thanks to Akemi Yagi for reporting this issue on the CentOS bug tracker
at http://bugs.centos.org/view.php?id=3931 and to Mark Rappoport for
passing the matter upstream to MantisBT, providing an initial patch in
the process.

:040000 040000 52087cc0d6145232c1889f620693b584af8f700f 85fed586015e7074bddcd5f895908e9571e47b74 M core

as the one changing this behavior. other builds that i tried out through git bisect (anything in 2010), were fine until the one above.

hope this helps

dhx

dhx

2010-02-07 07:03

reporter   ~0024335

Oops I made a mistake when backporting this patch from the 1.3.x branch to 1.2.x branch. I've tested both 1.2.x and 1.3.x and they're both working now.

Thanks for reporting this issue!

Related Changesets

MantisBT: master-1.2.x b65591fd

2010-02-07 06:55

dhx


Details Diff
Fix 0011449: Fix incorrect table name in db_get_table call

In the 1.2.x branch of MantisBT, db_get_table expects a prefix of
"mantis" and a suffix of "table". This was updated in the 1.3.x branch
so that the prefix and suffix aren't used in calls to db_get_table.

Commit 8a9f6d0593d78bc7b4cbe47c0444ba0d50d05fa2 was a backport of the
same patch applied to the 1.3.x branch. In this backport, the
db_get_table argument should have been changed to add the required
"mantis" prefix and "table" suffix to the table name.
Affected Issues
0011449
mod - core/bug_api.php Diff File