<p>I wrote a bunch of code over the holiday slowdown thinking that I could use git magic later to group the commits into neat, cohesive pull requests, but it turns out it's not so easy to do that so my pull requests got a little convoluted and I apologize. This pull request does the following:</p>

<ul class="task-list">
<li><p>Fixes sample_checking.py to use the <code>SingleTelescopeResultReader</code> class to parse Telescope input files (previously it used the <code>parse_filename_for_metadata</code> and <code>parse_data_file</code> but these are now module private - insofar as naming conventionsl let us pretend things are private).</p></li>
<li>
<p>Changes <code>TelescopeResultReader</code> so that it's an iterator over all the parsed rows (like the Python file <code>open</code> API is with lines of text) instead of the caller having to call <code>read_rows</code>. Now functions that are expecting a list of raw Telescope data rows can receive a <code>TelescopeResultReader</code> and not know the difference.</p>

<ul class="task-list">
<li>As a result of the above, we update <code>sample_checking.py</code> to just pass along a <code>TelescopeResultReader</code> object when it calls <code>add_to_counts()</code> instead of having to explicitly call <code>read_rows</code>.</li>
</ul>
</li>
</ul>

<p>You're welcome to review the pull request commit-by-commit if it's easier (though I will generally try to prevent making pull requests where you have to do that because it's usually a pain)</p>

<hr>

<h4>You can merge this Pull Request by running</h4>
<pre>  git pull https://github.com/mtlynch/mlab-observatory reader-iterator</pre>
<p>Or view, comment on, or merge it at:</p>
<p>  <a href='https://github.com/opentechinstitute/mlab-observatory/pull/33'>https://github.com/opentechinstitute/mlab-observatory/pull/33</a></p>

<h4>Commit Summary</h4>
<ul>
  <li>Fixing sample_checking so that it calls new APIs for parsing Telescope data</li>
  <li>Changing the semantics of TelescopeResultReader so that now _read_rows is private and callers get the rows through the __iter__ function. Also got rid of the get_metadata function in MergedTelescopeResultReader because it was confusing and unncessesary.</li>
  <li>Updating DataFileBlacklister to use new TelescopeResultReader iterator.</li>
</ul>

<h4>File Changes</h4>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/opentechinstitute/mlab-observatory/pull/33/files#diff-0">convert_from_telescope/result_merge.py</a>
    (37)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/opentechinstitute/mlab-observatory/pull/33/files#diff-1">convert_from_telescope/result_merge_test.py</a>
    (90)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/opentechinstitute/mlab-observatory/pull/33/files#diff-2">convert_from_telescope/sample_checking.py</a>
    (17)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/opentechinstitute/mlab-observatory/pull/33/files#diff-3">convert_from_telescope/telescope_data_parser.py</a>
    (34)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/opentechinstitute/mlab-observatory/pull/33/files#diff-4">convert_from_telescope/telescope_data_parser_test.py</a>
    (33)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/opentechinstitute/mlab-observatory/pull/33.patch'>https://github.com/opentechinstitute/mlab-observatory/pull/33.patch</a></li>
  <li><a href='https://github.com/opentechinstitute/mlab-observatory/pull/33.diff'>https://github.com/opentechinstitute/mlab-observatory/pull/33.diff</a></li>
</ul>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br>Reply to this email directly or <a href="https://github.com/opentechinstitute/mlab-observatory/pull/33">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AC7qBNyWJdytupGCyreN2XaW_jNb1A6hks5nevj1gaJpZM4DOmBx.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
  <div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
    <link itemprop="url" href="https://github.com/opentechinstitute/mlab-observatory/pull/33"></link>
    <meta itemprop="name" content="View Pull Request"></meta>
  </div>
  <meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>