Closed
Bug 244324
Opened 20 years ago
Closed 20 years ago
bugzilla-submit crashes when incorrect base url provided.
Categories
(Bugzilla :: Bug Import/Export & Moving, defect)
Tracking
()
RESOLVED
FIXED
Bugzilla 2.20
People
(Reporter: afw, Assigned: kiko)
Details
Attachments
(2 files)
1.81 KB,
patch
|
justdave
:
review-
|
Details | Diff | Splinter Review |
2.44 KB,
patch
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4.2) Gecko/20040301 Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4.2) Gecko/20040301 [alan@jambutty bugzilla-submit]$ bugzilla-submit http://192.168.2.3:8081/index.cgi < bug.txt <!-- 1.0@bugzilla.org --> <!-- 1.0@bugzilla.org --> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>Bugzilla Main Page</title> </head> <body bgcolor="#FFFFFF" onload=""> <!-- 1.0@bugzilla.org --> <table bgcolor="#000000" width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td> <font color="#FFFFFF" size="8"><center> Bugzilla Version 2.16.5 </center></font> </td> </tr> </table> <table border="0" cellspacing="0"> <tr> <td valign="top" align="left"> <table border="0" cellpadding="0" cellspacing="2"> <tr> <td valign="top" align="left" nowrap="nowrap"> <font size="+1"><b>Bugzilla Main Page</b></font> </td> </tr> </table> </td> <td valign="middle"> </td> <td valign="middle" align="left"></td> </tr> </table> <script type="text/javascript" language="JavaScript"> <!-- function addSidebar() { if ((typeof window.sidebar == "object") && (typeof window.sidebar.addPanel == "function")) { window.sidebar.addPanel ("Bugzilla", "http://192.168.2.3:8081/sidebar.cgi", ""); } else { var rv = window.confirm ("This page is enhanced for use with Netscape 6. " + "Would you like to upgrade now?"); if (rv) document.location.href = "http://home.netscape.com/download/index.html"; } } //--> </script> <table width="100%"><tr> <td> <p>This is where we put in lots of nifty words explaining all about Bugzilla.</p> But it all boils down to a choice of: <p> <a href="query.cgi">Query existing bug reports</a><br> <a href="enter_bug.cgi">Enter a new bug report</a><br> <a href="reports.cgi">Get summary reports</a><br> </p><p> <a href="query.cgi?GoAheadAndLogIn=1">Log in to an existing account</a><br> <a href="createaccount.cgi">Open a new Bugzilla account</a><br> </p><p> <a href="javascript:addSidebar()">Add to Sidebar</a> (Requires Mozilla or Netscape 6)<br> </p> <form name="f" action="show_bug.cgi" method="get" onsubmit="QuickSearch(f.id.value); return false;"> <p> Enter a bug # or some search terms:<br> <input type="text" name="id"> <input type="submit" value="Show"> <a href="quicksearch.html">[Help]</a> </p> </form> </td> <td align="right"><img src="ant.jpg" width="329" height="220" border="2" alt="ant.jpg [8.5k]"></td> </tr></table> <script type="text/javascript" language="JavaScript" src="localconfig.js"></script> <script type="text/javascript" language="JavaScript" src="quicksearch.js"></script> <script type="text/javascript"> <!-- document.forms['f'].id.focus(); //--> </script> <!-- 1.0@bugzilla.org --> <table border="0"> <tr> <td bgcolor="#000000" valign="top"> <table border="0" cellpadding="10" cellspacing="0" width="100%" bgcolor="lightyellow"> <tr> <td> This is <b>Bugzilla</b>: the Mozilla bug system. For more information about what Bugzilla is and what it can do, see <a href="http://www.bugzilla.org/">bugzilla.org</a>. <br> <!-- 1.0@bugzilla.org --> <form method="get" action="show_bug.cgi"> <table width="100%"> <tr> <td> Actions: </td> <td valign="middle" nowrap> <a href="enter_bug.cgi">New</a> | <a href="query.cgi">Query</a> | <input type="submit" value="Find"> bug # <input name="id" size="6"> | <a href="reports.cgi">Reports</a> </td> <td> </td> <td valign="middle" align="right"> <a href="createaccount.cgi">New Account</a> | <a href="query.cgi?GoAheadAndLogIn=1">Log In</a> </td> </tr> </table> </form> </td> </tr> </table> </td> </tr> </table> </body> </html> bugzilla-submit: Internal error: bug id not found; please report a bug Here is the input stream: Product: TestProduct Component: TestComponent Priority: P3 Version: other Severity: critical Summary: Zounds!! Engines overheating! Comment: Coolant depleted. Here is the .netrc machine "http://192.168.2.3:8081/index.cgi" login afw@u.washington.edu password xxxxxxxxx Reproducible: Always Steps to Reproduce: 1.Just run bugzilla-submit from the command line. 2.It blows up. Expected Results: bugzilla-submit seems to be very unstable. I have tried it about 100 times. It actually worked four times. Usually it fails with the message: bugzilla-submit: no credentials for Bugzilla instance at http://192.168.2.3:8081 The credentials are fine because: 1. It works 4/100 times. I didn't change the .netrc 2. Using the same email-addr/passwd, I can log in to the bugzilla instance via the browser. This facility would be very useful, if only it worked reliably.
Comment 1•20 years ago
|
||
What version of Python do you have on your system? (output of 'python -V')
Assignee: justdave → kiko
Summary: b ugzilla-submit crashed → bugzilla-submit crashed
Comment 2•20 years ago
|
||
Oh, I think I see what's going on from your command line. "index.cgi" is not part of your Bugzilla system's base url. Leave that off. Both on the command line and in .netrc bugzilla-submit may be smart enough to chop it off itself, but the fact that you have it in .netrc that was is probably what's causing the auth failures. bugzilla-submit submits to post_bug.cgi, and your .netrc only suggests a password to use for index.cgi (instead of for the entire bugzilla)
Reporter | ||
Comment 3•20 years ago
|
||
1. I am using python version 2.3.3 2. When I take the /index.cgi suffix off of the URL in .netrc and off of the URL on the command line, bugzilla-submit still blows up in the same way. I also tried appending /post_bug.cgi to both URLs, and it still fails the same way.
Comment 4•20 years ago
|
||
I think it needs the slash on the end... My .netrc looks like this: machine "http://landfill.bugzilla.org/bugzilla-tip/" login justdave@syndicomm.com password ***** from my test that worked. Otherwise, except as an occasional user of it, I don't know a whole lot about it, so we'll probably have to wait for kiko to get more ideas to try.
Reporter | ||
Comment 5•20 years ago
|
||
Thank you. The slash did it. Here is the winning URL: http://192.168.2.3:8081/ Just an opinion... There may be two bugs here. 1. Bugzilla-submit shouldn't blow up for lack of a trailing slash. 2. More importantly, the documentation should explain exactly what is meant for the "machine" field of the .netrc and for the "bugzilla-url" on the command line. From my point of view, however, this problem is solved.
Assignee | ||
Comment 6•20 years ago
|
||
I've recently added a fix to CVS that should at least solve the slash issue: date: 2004/04/13 18:52:50; author: kiko%async.com.br; state: Exp; lines: +10 -0 Add a slightly hackish approach to test against values in .netrc that diverge from the specified url by a trailing slash -- we *know* they're not the same thing, but it seems people want us to think they are! I'll have a look into the documentation next.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Assignee | ||
Comment 7•20 years ago
|
||
Here's the update I'm checking in, quickly reviewed by justdave. It states clearly that urlbase is what you should use and even adds a .netrc example.
Comment 8•20 years ago
|
||
Comment on attachment 153363 [details] [diff] [review] manpage update xml doesn't validate with this. /home/dave/mozilla/webtools/bugzilla/contrib/bugzilla-submit/bugzilla-submit.xm l:191: element listitem: validity error : Element listitem content does not follow the DTD, expecting (calloutlist | glosslist | itemizedlist | orderedlist | segmentedlist | simplelist | variablelist | caution | important | note | tip | warning | literallayout | programlisting | programlistingco | screen | screenco | screenshot | synopsis | cmdsynopsis | funcsynopsis | classsynopsis | fieldsynopsis | constructorsynopsis | destructorsynopsis | methodsynopsis | formalpara | para | simpara | address | blockquote | graphic | graphicco | mediaobject | mediaobjectco | informalequation | informalexample | informalfigure | informaltable | equation | example | figure | table | msgset | procedure | sidebar | qandaset | anchor | bridgehead | remark | highlights | abstract | authorblurb | epigraph | indexterm | beginpage)+, got (para para screen CDATA application CDATA) I think the following chunk: >+Note that the machine entry should match exactly the instance URL >+specified to <application>bugzilla-submit</application>. needs to have <para></para> wrapped around it.
Attachment #153363 -
Flags: review-
Assignee | ||
Comment 9•20 years ago
|
||
Checked in with added para tags.
Summary: bugzilla-submit crashed → bugzilla-submit crashes when incorrect base url provided.
Assignee | ||
Comment 10•20 years ago
|
||
This code checks if the user specified a 404ing URL, or one that doesn't point to the toplevel directory (via a hack, okay, but it works).
Assignee | ||
Comment 11•20 years ago
|
||
Checked in code, hopefully making bz-submit more robust under pressure.
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
![]() |
||
Updated•19 years ago
|
Target Milestone: --- → Bugzilla 2.20
Updated•11 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
•