<p dir="auto">When I try to run <code class="notranslate">python example/regressions.py</code> it throws this error</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Traceback (most recent call last):
  File &quot;examples/regressions.py&quot;, line 12, in &lt;module&gt;
    dateRange = DatetimeIndex(start, periods=N)
  File &quot;/Users/vyomkesh/code/pandas/pandas/util/decorators.py&quot;, line 88, in wrapper
    return func(*args, **kwargs)
  File &quot;/Users/vyomkesh/code/pandas/pandas/tseries/index.py&quot;, line 240, in __new__
    data = list(data)
TypeError: 'datetime.datetime' object is not iterable"><pre class="notranslate"><code class="notranslate">Traceback (most recent call last):
  File "examples/regressions.py", line 12, in &lt;module&gt;
    dateRange = DatetimeIndex(start, periods=N)
  File "/Users/vyomkesh/code/pandas/pandas/util/decorators.py", line 88, in wrapper
    return func(*args, **kwargs)
  File "/Users/vyomkesh/code/pandas/pandas/tseries/index.py", line 240, in __new__
    data = list(data)
TypeError: 'datetime.datetime' object is not iterable
</code></pre></div>
<p dir="auto"><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="217953096" data-permission-text="Title is private" data-url="https://github.com/pandas-dev/pandas/issues/15838" data-hovercard-type="pull_request" data-hovercard-url="/pandas-dev/pandas/pull/15838/hovercard?comment_id=109296615&amp;comment_type=review_comment" href="https://github.com/pandas-dev/pandas/pull/15838#discussion_r109296615">#15838 (comment)</a></p>
<p dir="auto">we have fairly uniform IO routines of the form</p>
<p dir="auto"><code class="notranslate">.to_format(path, df, **kwargs)</code> (takes DataFrame)<br>
and<br>
<code class="notranslate">pd.read_format(path, **kwargs)</code> (returns DataFrame)</p>
<p dir="auto">so should document various aspects of this:</p>
<ul dir="auto">
<li>contract on input path strings</li>
<li>file-like objects  &amp; <code class="notranslate">is_file_like</code> (<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="219391145" data-permission-text="Title is private" data-url="https://github.com/pandas-dev/pandas/issues/15894" data-hovercard-type="pull_request" data-hovercard-url="/pandas-dev/pandas/pull/15894/hovercard" href="https://github.com/pandas-dev/pandas/pull/15894">#15894</a>)</li>
<li>do we do any encoding / compression (only on csv/json ATM), compression</li>
<li>various guarantees on what we are sending in (e.g. no Index, string columns which are non-duplicated), no non-string objects (see feather/parquet impl).</li>
<li>make these more pluggable</li>
<li>perhaps allow a specification for block access / chunking.</li>
<li>additional args to accept/use: <code class="notranslate">mode</code> (for writing)</li>
</ul>