diff --git a/RELEASE.rst b/RELEASE.rst index 8bda8a2924e4c..942bde9df8342 100644 --- a/RELEASE.rst +++ b/RELEASE.rst @@ -25,7 +25,7 @@ Where to get it pandas 0.8.0 ============ -**Release date:** 6/26/2012 +**Release date:** 6/29/2012 **New features** @@ -210,6 +210,7 @@ pandas 0.8.0 - Pass keywords to pyplot.boxplot in DataFrame.boxplot (#1493) - Bug fixes in MonthBegin (#1483) - Preserve MultiIndex names in drop (#1513) + - Fix Panel DataFrame slice-assignment bug (#1533) pandas 0.7.3 ============ diff --git a/pandas/io/parsers.py b/pandas/io/parsers.py index a2277fc181fcc..797e5de7a4f6c 100644 --- a/pandas/io/parsers.py +++ b/pandas/io/parsers.py @@ -153,7 +153,6 @@ def _read(cls, filepath_or_buffer, kwds): from urllib2 import urlopen filepath_or_buffer = urlopen(filepath_or_buffer) if py3compat.PY3: # pragma: no cover - from io import TextIOWrapper if encoding: errors = 'strict' else: @@ -215,7 +214,19 @@ def read_csv(filepath_or_buffer, delimiter=None, encoding=None, squeeze=False): - kwds = locals() + kwds = dict(filepath_or_buffer=filepath_or_buffer, + sep=sep, dialect=dialect, + header=header, index_col=index_col, + names=names, skiprows=skiprows, + na_values=na_values, thousands=thousands, + comment=comment, parse_dates=parse_dates, + keep_date_col=keep_date_col, + dayfirst=dayfirst, date_parser=date_parser, + nrows=nrows, iterator=iterator, + chunksize=chunksize, skip_footer=skip_footer, + converters=converters, verbose=verbose, + delimiter=delimiter, encoding=encoding, + squeeze=squeeze) # Alias sep -> delimiter. sep = kwds.pop('sep') @@ -248,7 +259,19 @@ def read_table(filepath_or_buffer, delimiter=None, encoding=None, squeeze=False): - kwds = locals() + kwds = dict(filepath_or_buffer=filepath_or_buffer, + sep=sep, dialect=dialect, + header=header, index_col=index_col, + names=names, skiprows=skiprows, + na_values=na_values, thousands=thousands, + comment=comment, parse_dates=parse_dates, + keep_date_col=keep_date_col, + dayfirst=dayfirst, date_parser=date_parser, + nrows=nrows, iterator=iterator, + chunksize=chunksize, skip_footer=skip_footer, + converters=converters, verbose=verbose, + delimiter=delimiter, encoding=encoding, + squeeze=squeeze) # Alias sep -> delimiter. sep = kwds.pop('sep') @@ -284,8 +307,19 @@ def read_fwf(filepath_or_buffer, verbose=False, encoding=None, squeeze=False): - - kwds = locals() + kwds = dict(filepath_or_buffer=filepath_or_buffer, + colspecs=colspecs, widths=widths, + header=header, index_col=index_col, + names=names, skiprows=skiprows, + na_values=na_values, thousands=thousands, + comment=comment, parse_dates=parse_dates, + keep_date_col=keep_date_col, + dayfirst=dayfirst, date_parser=date_parser, + nrows=nrows, iterator=iterator, + chunksize=chunksize, skip_footer=skip_footer, + converters=converters, verbose=verbose, + delimiter=delimiter, encoding=encoding, + squeeze=squeeze) # Check input arguments. colspecs = kwds.get('colspecs', None) @@ -466,8 +500,6 @@ def __init__(self, f, delimiter=None, dialect=None, names=None, header=0, self.squeeze = squeeze def _make_reader(self, f): - import csv - sep = self.delimiter if sep is None or len(sep) == 1: