<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">The result doesn't contain any tables,
      so parse_single_table rightfully raises an exception.&nbsp; If you want
      to access the contents of the file (which contain an error message
      etc.), so can use vo.table.parse.<br>
      <br>
      Cheers,<br>
      Mike<br>
      <br>
      On 12/17/2012 03:22 PM, Jerome Caron wrote:<br>
    </div>
    <blockquote
      cite="mid:1355775756.58468.YahooMailNeo@web171404.mail.ir2.yahoo.com"
      type="cite">
      <meta http-equiv="Content-Type" content="text/html;
        charset=ISO-8859-1">
      <div style="color:#000; background-color:#fff; font-family:times
        new roman, new york, times, serif;font-size:12pt">
        <div><span>I don't know if the file I get from SkyBoT is an
            incorrect VO table file, or if there is a problem with the
            function </span><span>astropy.io.vo.table.parse_single_table.</span></div>
        <div><span>Can anybody guide me&nbsp;?</span></div>
        <div><span>Many thanks for your help</span></div>
        <div><span>Clear skies</span></div>
        <div><span>Jerome Caron</span></div>
        <div><br>
        </div>
        <div style="font-family: times new roman, new york, times,
          serif; font-size: 12pt;">
          <div style="font-family: times new roman, new york, times,
            serif; font-size: 12pt;">
            <div dir="ltr"> <font face="Arial" size="2"> <b><span
                    style="font-weight: bold;">De&nbsp;:</span></b> Jerome
                Caron <a class="moz-txt-link-rfc2396E" href="mailto:jerome_caron_astro@ymail.com">&lt;jerome_caron_astro@ymail.com&gt;</a><br>
                <b><span style="font-weight: bold;">&Agrave;&nbsp;:</span></b>
                <a class="moz-txt-link-rfc2396E" href="mailto:astropy@scipy.org">"astropy@scipy.org"</a> <a class="moz-txt-link-rfc2396E" href="mailto:astropy@scipy.org">&lt;astropy@scipy.org&gt;</a> <br>
                <b><span style="font-weight: bold;">Cc&nbsp;:</span></b>
                francois Kugel <a class="moz-txt-link-rfc2396E" href="mailto:fkugel@wanadoo.fr">&lt;fkugel@wanadoo.fr&gt;</a> <br>
                <b><span style="font-weight: bold;">Envoy&eacute; le :</span></b>
                Dimanche 16 d&eacute;cembre 2012 22h00<br>
                <b><span style="font-weight: bold;">Objet&nbsp;:</span></b>
                [AstroPy] VO table from skybot cannot be read by
                vo.table<br>
              </font> </div>
            <br>
            <div id="yiv37740015">
              <div>
                <div style="color: rgb(0, 0, 0); font-family: times new
                  roman, new york, times, serif; font-size: 12pt;
                  background-color: rgb(255, 255, 255);">
                  <div>Dear list</div>
                  <div>I have a problem with vo.table and SkyBOT.</div>
                  <div>I make a SkyBoT request and I get the following
                    xml file</div>
                  <div>&nbsp;</div>
                  <div>&lt;?xml version="1.0" encoding="UTF-8" ?&gt;<br>
                    &lt;vot:VOTABLE version="1.2" xmlns:xsi="<a
                      moz-do-not-send="true"
                      href="http://www.w3.org/2001/XMLSchema-instance"
                      rel="nofollow" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>"
                    xmlns:vot="<a moz-do-not-send="true"
                      href="http://www.ivoa.net/xml/VOTable/v1.2"
                      rel="nofollow" target="_blank">http://www.ivoa.net/xml/VOTable/v1.2</a>"
                    xsi:schemaLocation="<a moz-do-not-send="true"
                      href="http://www.ivoa.net/xml/VOTable/v1.2"
                      rel="nofollow" target="_blank">http://www.ivoa.net/xml/VOTable/v1.2</a>
                    <a moz-do-not-send="true"
                      href="http://www.ivoa.net/xml/VOTable/VOTable-1.2.xsd"
                      rel="nofollow" target="_blank">http://www.ivoa.net/xml/VOTable/VOTable-1.2.xsd</a>"
                    xmlns:stc="<a moz-do-not-send="true"
                      href="http://www.ivoa.net/xml/STC" rel="nofollow"
                      target="_blank">http://www.ivoa.net/xml/STC</a>"&gt;<br>
                    &lt;vot:INFO ID="status" name="QUERY_STATUS"
                    value="OK"/&gt;<br>
                    &lt;vot:INFO ID="reqTarget" name="-c"
                    value="1.1623100147908+0.78109932048627,rm=848.52813742386"/&gt;<br>
                    &lt;vot:INFO ID="reqEpoch" name="Epoch"
                    value="2456278.2798"/&gt;<br>
                    &lt;vot:INFO ID="supplier" name="Supplier"
                    value="Provided by IMCCE/OBSPM/CNRS"/&gt;<br>
                    &lt;vot:RESOURCE
                    name="Skybot.ConeSearch"&gt;&lt;vot:DESCRIPTION&gt;SkyBoT
                    - List of the targets located in the
                    FOV&lt;/vot:DESCRIPTION&gt;<br>
                    &lt;vot:INFO name="QUERY_STATUS" value="ERROR"&gt;No
                    solar system object was found in the requested FOV:
                    RA DEC: 04:26:22.91 +44:45:13.30 EPOCH: 2012-12-16
                    18:42:54.72&lt;/vot:INFO&gt;<br>
                    &lt;/vot:RESOURCE&gt;<br>
                    &lt;/vot:VOTABLE&gt;<br>
                  </div>
                  <div>I have a function that uses vo.table from
                    astropy, that usually works fine. But this time it
                    crashes with the following messages:</div>
                  <div>&nbsp;</div>
                  <div>&#8592;[0;31mERROR&#8592;[0m: IndexError: No table found in
                    VOTABLE file. [astropy.io.vo.tree]<br>
                    Traceback (most recent call last):<br>
                    &nbsp; File
                    "X:\imagesheq5\2012-12-16\pav-18\04_check_objects_v10.py",
                    line 159, in &lt;module&gt;<br>
                    &nbsp;&nbsp;&nbsp; cat = astrometry.read_votable(Folder+
                    '\\skybot.xml', text_display=False)<br>
                    &nbsp; File "C:\aspylib\aspylib\astrometry\query2.py",
                    line 34, in read_votable<br>
                    &nbsp;&nbsp;&nbsp; votable = parse_single_table(filename,
                    pedantic=False)<br>
                    &nbsp; File
                    "C:\Python27\lib\site-packages\astropy-0.1-py2.7-win32.egg\astropy\io\vo\table.py",
                    line 126, in parse_single_table<br>
                    &nbsp;&nbsp;&nbsp; return votable.get_first_table()<br>
                    &nbsp; File
                    "C:\Python27\lib\site-packages\astropy-0.1-py2.7-win32.egg\astropy\io\vo\tree.py",
                    line 2970, in get_first_table<br>
                    &nbsp;&nbsp;&nbsp; raise IndexError("No table found in VOTABLE
                    file.")<br>
                    IndexError: No table found in VOTABLE file.<br>
                    Appuyez sur une touche pour continuer...</div>
                  <div>&nbsp;</div>
                  <div>Do you have any idea ?</div>
                  <div>Jerome Caron</div>
                </div>
              </div>
            </div>
            <br>
            _______________________________________________<br>
            AstroPy mailing list<br>
            <a moz-do-not-send="true" href="mailto:AstroPy@scipy.org"
              ymailto="mailto:AstroPy@scipy.org">AstroPy@scipy.org</a><br>
            <a moz-do-not-send="true"
              href="http://mail.scipy.org/mailman/listinfo/astropy"
              target="_blank">http://mail.scipy.org/mailman/listinfo/astropy</a><br>
            <br>
            <br>
          </div>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
AstroPy mailing list
<a class="moz-txt-link-abbreviated" href="mailto:AstroPy@scipy.org">AstroPy@scipy.org</a>
<a class="moz-txt-link-freetext" href="http://mail.scipy.org/mailman/listinfo/astropy">http://mail.scipy.org/mailman/listinfo/astropy</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>