Closed Bug 378633 Opened 17 years ago Closed 17 years ago

'test_plan_permissions_regexp' failure when creating a new account in bugzilla since testopia install

Categories

(Testopia :: General, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: stuart.jewell, Assigned: gregaryh)

References

Details

User-Agent:       Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; InfoPath.1; .NET CLR 1.1.4322)
Build Identifier: 1.2

When user enters email address for new account creation, the following exception occurs:

DBD::mysql::st execute failed: Table 'test_plan_permissions_regexp' was not locked with LOCK TABLES [for Statement "SELECT test_plan_permissions_regexp.plan_id, 
                                 user_regexp, test_plan_permissions_regexp.permissions, 
                                 test_plan_permissions.plan_id
                          FROM test_plan_permissions_regexp
                     LEFT JOIN test_plan_permissions 
                            ON test_plan_permissions_regexp.plan_id = test_plan_permissions.plan_id
                           AND test_plan_permissions.userid = ?
                           AND test_plan_permissions.grant_type = ?"] at Bugzilla/User.pm line 707
	Bugzilla::User::derive_regexp_groups('Bugzilla::User=HASH(0x23d13e8)') called at Bugzilla/User.pm line 1417
	Bugzilla::User::insert_new_user('stuart.jewell@verizon.net', 'stubud') called at C:/Bugzilla/bugzilla-2.22.2/createaccount.cgi line 89



Reproducible: Sometimes

Steps to Reproduce:
1.  Select "Open a new Bugzilla account"
2.  Enter email address (and optionally "Real Name") and select "Submit"
Actual Results:  
DBD::mysql::st execute failed page displayed as described in description

Expected Results:  
User prompted for password info
I was able to (apparently) correct the same problem by adding the test_plan_permissions_regexp to the lock_tables list for updates in editusers.cgi:

--- editusers.cgi.orig  2007-04-22 13:34:40.000000000 -0500
+++ editusers.cgi       2007-04-22 13:31:23.000000000 -0500
@@ -245,6 +245,7 @@
     $dbh->bz_lock_tables('profiles WRITE',
                          'profiles_activity WRITE',
                          'test_plan_permissions WRITE',
+                        'test_plan_permissions_regexp READ',
                          'fielddefs READ',
                          'namedqueries READ',
                          'whine_queries READ',

I added 'test_plan_permissions_regexp READ' to editusers.cgi as defined in resolution.  I retried creating new user login and issue still occurs.  I verified change and then ran "checksetup.pl".  Issue still occurs.  Is there something else that needs to be done for change to propogate? Otherwise, suggested fix does not appear to correct issue.
I'm unable to reproduce the crash reported in comment 0. Note that the issue discussed in comment 1 has been fixed already. ghendricks, unless you can reproduce the problem described in comment 0, you can close this bug as WFM.
Version: unspecified → 1.2
Clarification:  Issue occurs specifically when self-enrolling and not a user is added by a bugzilla admin.
cvs ci -m "Bug 378633 – 'test_plan_permissions_regexp' failure when creating a new account in bugzilla since testopia install 
Patch by Mike Primm r=ghendricks" -l "/testopia/testopia/patch-2.22.2" "/testopia/testopia/patch-2.22" "/testopia/testopia/patch-2.22.1"
    Checking in testopia/patch-2.22.2;
    /cvsroot/mozilla/webtools/testopia/testopia/patch-2.22.2,v  <--  patch-2.22.2
    new revision: 1.3; previous revision: 1.2
    done
    Checking in testopia/patch-2.22;
    /cvsroot/mozilla/webtools/testopia/testopia/patch-2.22,v  <--  patch-2.22
    new revision: 1.13; previous revision: 1.12
    done
    Checking in testopia/patch-2.22.1;
    /cvsroot/mozilla/webtools/testopia/testopia/patch-2.22.1,v  <--  patch-2.22.1
    new revision: 1.9; previous revision: 1.8
    done
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.