MantisBT

View Issue Details Jump to Notes ] Wiki ] Related Changesets ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0014189mantisbtsub-projectspublic2012-04-24 19:312012-09-05 11:19
Reporterpatgaytx 
Assigned Todregad 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionduplicate 
PlatformOSOS Version
Product Version1.2.10 
Target VersionFixed in Version 
Summary0014189: APPLICATION ERROR 0001502 Category not found.
DescriptionI'm getting this message after moving a bug from one subproject to another:
APPLICATION ERROR 0001502

Category not found.

The patch provided in 0013007 seems to be in place in bug_api.php.

Can someone tell me what's going on and how to fix it?

 // Bug has no category
        if( $t_category_id == 0 ) {
                // Category is required in target project, set it to default
                if( ON != config_get( 'allow_no_category', null, null, $p_target_proj
ect_id ) ) {
                        bug_set_field( $p_bug_id, 'category_id', config_get( 'default
_category_for_moves' ) );
                }
        }
        // Check if the category is global, and if not attempt mapping it to the new
project
        else {
                $t_category_project_id = category_get_field( $t_category_id, 'project
_id' );

                if ( $t_category_project_id != ALL_PROJECTS
                  && !project_hierarchy_inherit_parent( $p_target_project_id, $t_cate
gory_project_id )
                ) {
 
TagsNo tags attached.
Attached Files

- Relationships
duplicate of 0013850closeddregad Moving from project to project causes application error 1502 
related to 0014190acknowledged When moving an issue, allow selection of both the Project and the Category 
related to 0012105closeddregad Receiving APPLICATION ERROR 0001502 on view_all_bug_page.php 

-  Notes
User avatar (0031714)
patgaytx (reporter)
2012-04-24 19:56

I wanted to add that the sub-project I'm trying to move the bug to does not have the same category name as the sub-project I'm moving from.

So the question now becomes, how to move a bug from one sub-project/category combination to another sub-project/category when the categories between sub-projects are different. My first inclination is to have the person moving the bug select both the "Move To" sub-project AND the "Move To" category.
User avatar (0031715)
patgaytx (reporter)
2012-04-24 20:00

Another thing I noticed is that this problem only occurs when the General Category (id 1) doesn't exist. This is the case for me as I deleted all the general categories. I updated the database table mantis_category_table and inserted id 1 with a name of General and was able to get past the message when moving a bug. The SQL I used was: INSERT INTO `mantis`.`mantis_category_table` (`id`, `project_id`, `user_id`, `name`, `status`) VALUES ('1', '0', '0', 'General', '0');

I still maintain my comment in the prior note: 0014189:0031714
So the question now becomes, how to move a bug from one sub-project/category combination to another sub-project/category when the categories between sub-projects are different. My first inclination is to have the person moving the bug select both the "Move To" sub-project AND the "Move To" category.
User avatar (0031716)
atrol (developer)
2012-04-25 01:35

You have to define $g_default_category_for_moves to some valid category. This can be done fot all projects in config_inc.php or per project on manage configuration page.
User avatar (0031717)
patgaytx (reporter)
2012-04-25 01:56

yeah, that's how I ended up fixing the problem. I added back the general category with id 1 (effectively defining $g_default_category_for_moves).

I'd like to see an enhancement made that would give you the opportunity to select both the Project/subproject and the category when doing a move so that it doesn't require any preconfiguration in the config_inc.php or at the project level.
User avatar (0031719)
dregad (developer)
2012-04-25 05:53

The original issue is a duplicate of 0013850, and atrol provided the correct fix for that. I will document this in the Admin guide / troubleshooting section.

Your feature request will be tracked separately in 0014190.

- Related Changesets
MantisBT: master 21b7b34f
Timestamp: 2012-04-25 03:02:19
Author: dregad
Details ] Diff ]
Documentation: added error 1502 in Troubleshooting guide

Affects 0013850, 0014189 and several other issues (see related).
mod - docbook/Admin_Guide/en-US/Troubleshooting.xml Diff ] File ]
MantisBT: master-1.2.x 695040ce
Timestamp: 2012-04-25 03:02:19
Author: dregad
Details ] Diff ]
Documentation: added error 1502 in Troubleshooting guide

Affects 0013850, 0014189 and several other issues (see related).
mod - docbook/adminguide/en/troubleshooting.sgml Diff ] File ]
MantisBT: master 30df2f45
Timestamp: 2012-05-02 01:10:22
Author: dregad
Details ] Diff ]
Documentation: improved troubleshooting for error 1502

Added instructions on how to retrieve the category id
mod - docbook/Admin_Guide/en-US/Troubleshooting.xml Diff ] File ]
MantisBT: master-1.2.x 6e842296
Timestamp: 2012-05-02 01:10:22
Author: dregad
Details ] Diff ]
Documentation: improved troubleshooting for error 1502

Added instructions on how to retrieve the category id
mod - docbook/adminguide/en/troubleshooting.sgml Diff ] File ]

- Issue History
Date Modified Username Field Change
2012-04-24 19:31 patgaytx New Issue
2012-04-24 19:56 patgaytx Note Added: 0031714
2012-04-24 20:00 patgaytx Note Added: 0031715
2012-04-25 01:35 atrol Note Added: 0031716
2012-04-25 01:35 atrol Status new => feedback
2012-04-25 01:56 patgaytx Note Added: 0031717
2012-04-25 01:56 patgaytx Status feedback => new
2012-04-25 05:53 dregad Note Added: 0031719
2012-04-25 05:53 dregad Relationship added duplicate of 0013850
2012-04-25 05:53 dregad Status new => resolved
2012-04-25 05:53 dregad Resolution open => duplicate
2012-04-25 05:53 dregad Assigned To => dregad
2012-04-25 05:54 dregad Priority immediate => normal
2012-04-25 05:54 dregad Severity block => major
2012-04-25 05:54 dregad Relationship added related to 0014190
2012-05-02 00:52 reinier Note Added: 0031741
2012-05-02 01:29 reinier Note Deleted: 0031741
2012-05-11 10:15 dregad Changeset attached => MantisBT master 21b7b34f
2012-05-11 10:15 dregad Changeset attached => MantisBT master-1.2.x 695040ce
2012-05-11 10:16 dregad Changeset attached => MantisBT master-1.2.x 6e842296
2012-05-11 10:16 dregad Changeset attached => MantisBT master 30df2f45
2012-05-23 20:31 atrol Status resolved => closed
2012-09-05 11:19 dregad Relationship added related to 0012105


MantisBT 1.2.16dev master-1.2.x-8c2bd07 [^]
Copyright © 2000 - 2013 MantisBT Team
Time: 0.1314 seconds.
memory usage: 2,858 KB
Powered by Mantis Bugtracker