<div dir="ltr">Thanks for the help. Could you help me with that because I am having login issues from a couple of stuff I found on the web? Or can you provide me with any helpful links?<div><br></div><div>So far I have looked at these and I keep getting a dummy html page (not related to the bug) instead of the XML page for the bug:</div><div><br></div><div><a href="http://stackoverflow.com/questions/189555/how-to-use-python-to-login-to-a-webpage-and-retrieve-cookies-for-later-usage">http://stackoverflow.com/questions/189555/how-to-use-python-to-login-to-a-webpage-and-retrieve-cookies-for-later-usage</a><br></div><div><a href="http://stackoverflow.com/questions/11167419/get-xml-data-from-bugzilla-url">http://stackoverflow.com/questions/11167419/get-xml-data-from-bugzilla-url</a><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jan 13, 2015 at 3:38 PM, Cole Robinson <span dir="ltr">&lt;<a href="mailto:crobinso@redhat.com" target="_blank">crobinso@redhat.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I guess you can just generate that URL from the bug&#39;s ID, then use standard<br>
python urllib or similar to fetch the web page contents. I don&#39;t think there&#39;s<br>
any bugzilla API call that does what you want though<br>
<br>
- Cole<br>
<span class=""><br>
On 01/13/2015 03:35 PM, Ravikumar Patel wrote:<br>
&gt; I&#39;ll guide you through the steps I&#39;ve followed to clarify what I mean. First,<br>
&gt; I queried for all bugs for a specific person. I then got a list of bugs for<br>
&gt; that person with all of their bug IDs. I clicked on one of the bug ID and it<br>
&gt; gave me a page with that bug&#39;s summary, status, aliases, product, etc. Once<br>
&gt; you get to the bottom of the page, you have a link to it&#39;s XML view/page. (see<br>
&gt; screenshot below)<br>
&gt;<br>
</span><span class="">&gt; Inline image 1<br>
&gt;<br>
&gt; Now I want to get access to this page (using my python script from previous<br>
&gt; emails):<br>
</span><span class="">&gt; Inline image 3<br>
&gt;<br>
&gt; I want to know if I can access this XML page from a corresponding bug ID via a<br>
&gt; python script?<br>
&gt;<br>
&gt; Thanks,<br>
&gt; Ravi<br>
&gt;<br>
&gt;<br>
&gt; On Tue, Jan 13, 2015 at 2:25 PM, Cole Robinson &lt;<a href="mailto:crobinso@redhat.com">crobinso@redhat.com</a><br>
</span><span class="">&gt; &lt;mailto:<a href="mailto:crobinso@redhat.com">crobinso@redhat.com</a>&gt;&gt; wrote:<br>
&gt;<br>
&gt;     I don&#39;t know what you mean by &#39;xml page&#39;<br>
&gt;<br>
&gt;     - Cole<br>
&gt;<br>
&gt;     On 01/13/2015 02:23 PM, Ravikumar Patel wrote:<br>
&gt;     &gt; This is a follow up question. How do I now access each bug&#39;s XML page now that<br>
&gt;     &gt; I have the bug IDs I needed?<br>
&gt;     &gt;<br>
&gt;     &gt; On Tue, Jan 13, 2015 at 1:34 PM, Cole Robinson &lt;<a href="mailto:crobinso@redhat.com">crobinso@redhat.com</a> &lt;mailto:<a href="mailto:crobinso@redhat.com">crobinso@redhat.com</a>&gt;<br>
</span><span class="">&gt;     &gt; &lt;mailto:<a href="mailto:crobinso@redhat.com">crobinso@redhat.com</a> &lt;mailto:<a href="mailto:crobinso@redhat.com">crobinso@redhat.com</a>&gt;&gt;&gt; wrote:<br>
&gt;     &gt;<br>
&gt;     &gt;     On 01/13/2015 12:59 PM, Ravikumar Patel wrote:<br>
&gt;     &gt;     &gt; Hello,<br>
&gt;     &gt;     &gt;<br>
&gt;     &gt;     &gt; I am trying to get the bug ID of all bugs from my Bugzilla account. Any<br>
&gt;     &gt;     &gt; suggestions as to how I am able to do so? Is it possible that to query for all<br>
&gt;     &gt;     &gt; projects and then access the bug IDs from each project? If so, then how?<br>
&gt;     &gt;     &gt;<br>
&gt;     &gt;     &gt; So far my code looks like this:<br>
&gt;     &gt;     &gt;<br>
&gt;     &gt;     &gt; |bz = bugzilla.Bugzilla(url=&#39;<a href="https://bugzilla.mycompany.com/xmlrpc.cgi" target="_blank">https://bugzilla.mycompany.com/xmlrpc.cgi</a>&#39;)<br>
&gt;     &gt;     &gt; try:<br>
&gt;     &gt;     &gt;    bz.login(&#39;<a href="mailto:name@email.com">name@email.com</a> &lt;mailto:<a href="mailto:name@email.com">name@email.com</a>&gt; &lt;mailto:<a href="mailto:name@email.com">name@email.com</a><br>
&gt;     &lt;mailto:<a href="mailto:name@email.com">name@email.com</a>&gt;&gt;<br>
&gt;     &gt;     &lt;mailto:<a href="mailto:name@email.com">name@email.com</a> &lt;mailto:<a href="mailto:name@email.com">name@email.com</a>&gt;<br>
&gt;     &lt;mailto:<a href="mailto:name@email.com">name@email.com</a> &lt;mailto:<a href="mailto:name@email.com">name@email.com</a>&gt;&gt;&gt;&#39;, &#39;password&#39;);<br>
&gt;     &gt;     &gt;    print&#39;Authorization cookie received.&#39;<br>
&gt;     &gt;     &gt; except bugzilla.BugzillaError:<br>
&gt;     &gt;     &gt;    print(str(sys.exc_info()[1]))<br>
&gt;     &gt;     &gt;    sys.exit(1)|<br>
&gt;     &gt;     &gt;<br>
&gt;     &gt;     &gt; Here is the link to the stackoverflow question page:<br>
&gt;     &gt;     &gt; <a href="http://stackoverflow.com/questions/27869663/how-do-i-query-bugzilla-to-get-all-the-bug-ids-using-python-and-xml-rpc" target="_blank">http://stackoverflow.com/questions/27869663/how-do-i-query-bugzilla-to-get-all-the-bug-ids-using-python-and-xml-rpc</a><br>
&gt;     &gt;     &gt;<br>
&gt;     &gt;     &gt; I really need help on this. Any suggestions?<br>
&gt;     &gt;<br>
&gt;     &gt;     bugs = bz.query(bz.build_query(assigned_to=&quot;your-bugzilla-account&quot;))<br>
&gt;     &gt;     for bug in bugs:<br>
</span>&gt;     &gt;         print <a href="http://bug.id" target="_blank">bug.id</a> &lt;<a href="http://bug.id" target="_blank">http://bug.id</a>&gt; &lt;<a href="http://bug.id" target="_blank">http://bug.id</a>&gt;<br>
&gt;     &gt;<br>
&gt;     &gt;     - Cole<br>
&gt;     &gt;<br>
&gt;     &gt;<br>
&gt;     &gt;<br>
&gt;     &gt;<br>
&gt;<br>
&gt;<br>
<br>
</blockquote></div><br></div>