Closed
Bug 277303
Opened 20 years ago
Closed 20 years ago
checksetup.pl emits a syntax error when trying to fix indexes on the milestones table
Categories
(Bugzilla :: Installation & Upgrading, defect)
Tracking
()
RESOLVED
FIXED
Bugzilla 2.18
People
(Reporter: pds, Assigned: mkanat)
Details
Attachments
(1 file)
1.05 KB,
patch
|
Wurblzap
:
review+
|
Details | Diff | Splinter Review |
While attempting to upgrade from 2.16.1 to 2.18 tip-of-branch, I encountered an
error in the checksetup.pl script. At line 3343 in the script, the PrintWarn
parameter of the DBI handle is queried. This parameter does not exist in DBI
version 1.38, but the script states that only version 1.36 of the DBI module is
required.
For whatever its worth, the adjusting of the PrintWarn parameter may not be
achieving its attended purpose when used with DBI version 1.46. When I use
version 1.46 of the DBI module, I always noticed the following error message
when doing the upgrade:
DBD::mysql::db do failed: You have an error in your SQL syntax near 'PRIMARY' at
line 1 at checksetup.pl line 3345.
I have been testing with MySQL 3.23.53a on RedHat 9 and MySQL 4.0.23-debug on
Windows XP. I am not sure whether this information might be useful in deciding
how to fix this bug or is indicative of a second bug.
Assignee | ||
Comment 1•20 years ago
|
||
Crap. If that is true, it's my fault.
Assignee: zach → mkanat
Flags: approval2.18?
Assignee | ||
Comment 2•20 years ago
|
||
Arrrgghh, that's the second time I've done that. And now I can't clear it,
because of that bug...
Flags: blocking2.18?
Updated•20 years ago
|
Flags: blocking2.20+
Flags: blocking2.18?
Flags: blocking2.18+
Flags: approval2.18?
OS: Linux → All
Hardware: PC → All
Target Milestone: --- → Bugzilla 2.18
Assignee | ||
Comment 3•20 years ago
|
||
Actually, here's the real problem:
<avatraxiom> ALTER TABLE milestones DROP INDEX PRIMARY;
<avatraxiom> ERROR 1064: You have an error in your SQL syntax near 'PRIMARY' at
line 1
<avatraxiom> Um, what??
<avatraxiom> It doesn't just say that PRIMARY is a bad index. It actually said
that I have *bad syntax*.
I'm not sure why I didn't catch that when I originally wrote the patch...
Status: UNCONFIRMED → NEW
Ever confirmed: true
Assignee | ||
Comment 4•20 years ago
|
||
I've changed the summary to reflect something that's actually a problem.
If the DBI that you're using doesn't support PrintWarn, it just won't do
anything, right? That is, does it actually throw an error when it tries to set
PrintWarn?
Summary: checksetup.pl uses DBI:PrintWarn parameter which requires newer DBI → checksetup.pl emits a syntax error when trying to fix indexes on the milestones table
Assignee | ||
Comment 5•20 years ago
|
||
OK, this is actually a wholly better fix than the fix that I originally checked
in here.
Attachment #170513 -
Flags: review?(travis)
Assignee | ||
Updated•20 years ago
|
Whiteboard: patch awaiting review
Reporter | ||
Comment 6•20 years ago
|
||
As I attempted, but apparently failed, to make clear in my original report, I
observed two different problems with version 1.46 of the DBI module I
checksetup.pl reported the SQL syntax error. With version 1.38 of the DBI
module, however, the checksetup.pl script aborted, or at least appeared to
abort, at line 3343, i.e. two lines before the SQL syntax error, and complained
about the PrintWarn parameter. All that said, I would expect that your new
patch will solve both problems.
Comment 7•20 years ago
|
||
Max, if you're interested, open up r? -- you'd get r=wurblzap.
Assignee | ||
Updated•20 years ago
|
Attachment #170513 -
Flags: review?(travis) → review?
Assignee | ||
Comment 8•20 years ago
|
||
OK, go ahead. :-)
Comment 9•20 years ago
|
||
Comment on attachment 170513 [details] [diff] [review]
Much better fix
This is what is done in other places -- drop the index, then re-create it.
r=wurblzap by inspection.
Attachment #170513 -
Flags: review? → review+
Updated•20 years ago
|
Flags: approval?
Flags: approval2.18?
Whiteboard: patch awaiting review → patch awaiting approval
Updated•20 years ago
|
Severity: normal → major
Flags: approval?
Flags: approval2.18?
Flags: approval2.18+
Flags: approval+
Updated•20 years ago
|
Whiteboard: patch awaiting approval → patch awaiting checkin
Comment 10•20 years ago
|
||
Checking in checksetup.pl;
/cvsroot/mozilla/webtools/bugzilla/checksetup.pl,v <-- checksetup.pl
new revision: 1.322; previous revision: 1.321
done
Checking in checksetup.pl;
/cvsroot/mozilla/webtools/bugzilla/checksetup.pl,v <-- checksetup.pl
new revision: 1.289.2.20; previous revision: 1.289.2.19
done
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Whiteboard: patch awaiting checkin
Updated•12 years ago
|
QA Contact: matty_is_a_geek → default-qa
You need to log in
before you can comment on or make changes to this bug.
Description
•