<p dir="auto">This is using a fresh install of Anaconda in an Ubuntu 15.10 based Google Cloud VM.  At first glance it seemed to relate to difficulties getting console encoding (see <code class="notranslate">from pandas.core.format import detect_console_encoding</code> below)?</p>
<div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import pandas

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
&lt;ipython-input-1-f0ee645c240d&gt; in &lt;module&gt;()
----&gt; 1 import pandas as pd
      2 import dask.dataframe as dd
      3 from dask.diagostics import ProgressBar as pb

/home/michael/anaconda3/lib/python3.5/site-packages/pandas/__init__.py in &lt;module&gt;()
     40
     41 # let init-time option registration happen
---&gt; 42 import pandas.core.config_init
     43
     44 from pandas.core.api import *

/home/michael/anaconda3/lib/python3.5/site-packages/pandas/core/config_init.py in &lt;module&gt;()
     15                                 is_instance_factory, is_one_of_factory,
     16                                 get_default_val)
---&gt; 17 from pandas.core.format import detect_console_encoding
     18
     19

/home/michael/anaconda3/lib/python3.5/site-packages/pandas/core/format.py in &lt;module&gt;()
      8 from pandas.core.base import PandasObject
      9 from pandas.core.common import adjoin, notnull
---&gt; 10 from pandas.core.index import Index, MultiIndex, _ensure_index
     11 from pandas import compat
     12 from pandas.compat import(StringIO, lzip, range, map, zip, reduce, u,

/home/michael/anaconda3/lib/python3.5/site-packages/pandas/core/index.py in &lt;module&gt;()
     29 from pandas.core.strings import StringAccessorMixin
     30 from pandas.core.config import get_option
---&gt; 31 from pandas.io.common import PerformanceWarning
     32
     33

/home/michael/anaconda3/lib/python3.5/site-packages/pandas/io/common.py in &lt;module&gt;()
     66
     67 try:
---&gt; 68     from boto.s3 import key
     69     class BotoFileLikeReader(key.Key):
     70         &quot;&quot;&quot;boto Key modified to be more file-like

/home/michael/anaconda3/lib/python3.5/site-packages/boto/__init__.py in &lt;module&gt;()
  1214     return storage_uri(uri_str)
  1215
-&gt; 1216 boto.plugin.load_plugins(config)

/home/michael/anaconda3/lib/python3.5/site-packages/boto/plugin.py in load_plugins(config)
    90         return
    91     directory = config.get('Plugin', 'plugin_directory')
---&gt; 92     for file in glob.glob(os.path.join(directory, '*.py')):
    93         _import_module(file)

/home/michael/anaconda3/lib/python3.5/posixpath.py in join(a, *p)
    87                 path += sep + b
    88     except (TypeError, AttributeError, BytesWarning):
---&gt; 89         genericpath._check_arg_types('join', a, *p)
    90         raise
    91     return path

/home/michael/anaconda3/lib/python3.5/genericpath.py in _check_arg_types(funcname, *args)
   141         else:
   142             raise TypeError('%s() argument must be str or bytes, not %r' %
--&gt; 143                             (funcname, s.__class__.__name__)) from None
   144     if hasstr and hasbytes:
   145         raise TypeError(&quot;Can't mix strings and bytes in path components&quot;) from None

TypeError: join() argument must be str or bytes, not 'NoneType'"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">pandas</span>

<span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span>
<span class="pl-v">TypeError</span>                                 <span class="pl-v">Traceback</span> (<span class="pl-s1">most</span> <span class="pl-s1">recent</span> <span class="pl-s1">call</span> <span class="pl-s1">last</span>)
<span class="pl-c1">&lt;</span><span class="pl-s1">ipython</span><span class="pl-c1">-</span><span class="pl-s1">input</span><span class="pl-c1">-</span><span class="pl-c1">1</span><span class="pl-c1">-</span><span class="pl-s1">f0ee645c240d</span><span class="pl-c1">&gt;</span> <span class="pl-s1">in</span> <span class="pl-c1">&lt;</span><span class="pl-s1">module</span><span class="pl-c1">&gt;</span>()
<span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">1</span> <span class="pl-s1">import</span> <span class="pl-s1">pandas</span> <span class="pl-k">as</span> <span class="pl-s1">pd</span>
      <span class="pl-c1">2</span> <span class="pl-k">import</span> <span class="pl-s1">dask</span>.<span class="pl-s1">dataframe</span> <span class="pl-k">as</span> <span class="pl-s1">dd</span>
      <span class="pl-c1">3</span> <span class="pl-k">from</span> <span class="pl-s1">dask</span>.<span class="pl-s1">diagostics</span> <span class="pl-k">import</span> <span class="pl-v">ProgressBar</span> <span class="pl-k">as</span> <span class="pl-s1">pb</span>

<span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">michael</span><span class="pl-c1">/</span><span class="pl-s1">anaconda3</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python3</span>.<span class="pl-c1">5</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">pandas</span><span class="pl-c1">/</span><span class="pl-s1">__init__</span>.<span class="pl-s1">py</span> <span class="pl-c1">in</span> <span class="pl-c1">&lt;</span><span class="pl-s1">module</span><span class="pl-c1">&gt;</span>()
     <span class="pl-c1">40</span>
     <span class="pl-c1">41</span> <span class="pl-c"># let init-time option registration happen</span>
<span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">42</span> <span class="pl-s1">import</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">core</span>.<span class="pl-s1">config_init</span>
     <span class="pl-c1">43</span>
     <span class="pl-c1">44</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">core</span>.<span class="pl-s1">api</span> <span class="pl-k">import</span> <span class="pl-c1">*</span>

<span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">michael</span><span class="pl-c1">/</span><span class="pl-s1">anaconda3</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python3</span>.<span class="pl-c1">5</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">pandas</span><span class="pl-c1">/</span><span class="pl-s1">core</span><span class="pl-c1">/</span><span class="pl-s1">config_init</span>.<span class="pl-s1">py</span> <span class="pl-c1">in</span> <span class="pl-c1">&lt;</span><span class="pl-s1">module</span><span class="pl-c1">&gt;</span>()
     <span class="pl-c1">15</span>                                 <span class="pl-s1">is_instance_factory</span>, <span class="pl-s1">is_one_of_factory</span>,
     <span class="pl-c1">16</span>                                 <span class="pl-s1">get_default_val</span>)
<span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">17</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">core</span>.<span class="pl-s1">format</span> <span class="pl-k">import</span> <span class="pl-s1">detect_console_encoding</span>
     <span class="pl-c1">18</span>
     <span class="pl-c1">19</span>

<span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">michael</span><span class="pl-c1">/</span><span class="pl-s1">anaconda3</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python3</span>.<span class="pl-c1">5</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">pandas</span><span class="pl-c1">/</span><span class="pl-s1">core</span><span class="pl-c1">/</span><span class="pl-s1">format</span>.<span class="pl-s1">py</span> <span class="pl-c1">in</span> <span class="pl-c1">&lt;</span><span class="pl-s1">module</span><span class="pl-c1">&gt;</span>()
      <span class="pl-c1">8</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">core</span>.<span class="pl-s1">base</span> <span class="pl-k">import</span> <span class="pl-v">PandasObject</span>
      <span class="pl-c1">9</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">core</span>.<span class="pl-s1">common</span> <span class="pl-k">import</span> <span class="pl-s1">adjoin</span>, <span class="pl-s1">notnull</span>
<span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">10</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">core</span>.<span class="pl-s1">index</span> <span class="pl-k">import</span> <span class="pl-v">Index</span>, <span class="pl-v">MultiIndex</span>, <span class="pl-s1">_ensure_index</span>
     <span class="pl-c1">11</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span> <span class="pl-k">import</span> <span class="pl-s1">compat</span>
     <span class="pl-c1">12</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">compat</span> <span class="pl-k">import</span>(<span class="pl-v">StringIO</span>, <span class="pl-s1">lzip</span>, <span class="pl-s1">range</span>, <span class="pl-s1">map</span>, <span class="pl-s1">zip</span>, <span class="pl-s1">reduce</span>, <span class="pl-s1">u</span>,

<span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">michael</span><span class="pl-c1">/</span><span class="pl-s1">anaconda3</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python3</span>.<span class="pl-c1">5</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">pandas</span><span class="pl-c1">/</span><span class="pl-s1">core</span><span class="pl-c1">/</span><span class="pl-s1">index</span>.<span class="pl-s1">py</span> <span class="pl-s1">in</span> <span class="pl-c1">&lt;</span><span class="pl-s1">module</span><span class="pl-c1">&gt;</span>()
     <span class="pl-c1">29</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">core</span>.<span class="pl-s1">strings</span> <span class="pl-k">import</span> <span class="pl-v">StringAccessorMixin</span>
     <span class="pl-c1">30</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">core</span>.<span class="pl-s1">config</span> <span class="pl-k">import</span> <span class="pl-s1">get_option</span>
<span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">31</span> <span class="pl-k">from</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">io</span>.<span class="pl-s1">common</span> <span class="pl-k">import</span> <span class="pl-v">PerformanceWarning</span>
     <span class="pl-c1">32</span>
     <span class="pl-c1">33</span>

<span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">michael</span><span class="pl-c1">/</span><span class="pl-s1">anaconda3</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python3</span>.<span class="pl-c1">5</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">pandas</span><span class="pl-c1">/</span><span class="pl-s1">io</span><span class="pl-c1">/</span><span class="pl-s1">common</span>.<span class="pl-s1">py</span> <span class="pl-c1">in</span> <span class="pl-c1">&lt;</span><span class="pl-s1">module</span><span class="pl-c1">&gt;</span>()
     <span class="pl-c1">66</span>
     <span class="pl-c1">67</span> <span class="pl-k">try</span>:
<span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">68</span>     <span class="pl-k">from</span> <span class="pl-s1">boto</span>.<span class="pl-s1">s3</span> <span class="pl-k">import</span> <span class="pl-s1">key</span>
     <span class="pl-c1">69</span>     <span class="pl-k">class</span> <span class="pl-v">BotoFileLikeReader</span>(<span class="pl-s1">key</span>.<span class="pl-v">Key</span>):
     <span class="pl-c1">70</span>         """boto Key modified to be more file-like

/home/michael/anaconda3/lib/python3.5/site-packages/boto/__init__.py in &lt;module&gt;()
  1214     return storage_uri(uri_str)
  1215
-&gt; 1216 boto.plugin.load_plugins(config)

/home/michael/anaconda3/lib/python3.5/site-packages/boto/plugin.py in load_plugins(config)
    90         return
    91     directory = config.get('Plugin', 'plugin_directory')
---&gt; 92     for file in glob.glob(os.path.join(directory, '*.py')):
    93         _import_module(file)

/home/michael/anaconda3/lib/python3.5/posixpath.py in join(a, *p)
    87                 path += sep + b
    88     except (TypeError, AttributeError, BytesWarning):
---&gt; 89         genericpath._check_arg_types('join', a, *p)
    90         raise
    91     return path

/home/michael/anaconda3/lib/python3.5/genericpath.py in _check_arg_types(funcname, *args)
   141         else:
   142             raise TypeError('%s() argument must be str or bytes, not %r' %
--&gt; 143                             (funcname, s.__class__.__name__)) from None
   144     if hasstr and hasbytes:
   145         raise TypeError("Can't mix strings and bytes in path components") <span class="pl-k">from</span> <span class="pl-c1">None</span>

<span class="pl-v">TypeError</span>: <span class="pl-en">join</span>() <span class="pl-s1">argument</span> <span class="pl-s1">must</span> <span class="pl-s1">be</span> <span class="pl-s1">str</span> <span class="pl-c1">or</span> <span class="pl-s1">bytes</span>, <span class="pl-c1">not</span> <span class="pl-s">'NoneType'</span></pre></div>
<p dir="auto">When using the <code class="notranslate">read_gbq()</code> function on a BigQuery table, incorrect results are returned.</p>
<p dir="auto">I compare the output from <code class="notranslate">read_gbq()</code> to that of a CSV export from BigQuery directly. Interestingly, there are the same number of rows in each output - however, there are many duplicates in the <code class="notranslate">read_gbq()</code> output.</p>
<p dir="auto">I'm using Pandas '0.13.0rc1-125-g4952858' on a Mac 10.9 using Python 2.7. Numpy '1.8.0'.</p>
<p dir="auto">The code I execute to load the data in pandas:<br>
<code class="notranslate">churn_data = gbq.read_gbq(train_query, project_id = projectid)</code></p>
<p dir="auto">I can't share the underlying data. What additional data/info would be useful for root causing?</p>
<p dir="auto">The output data is ~400k lines.</p>