Skip to content

Commit 70adb42

Browse files
author
maxim veksler
committed
flake8.
1 parent 6122373 commit 70adb42

File tree

3 files changed

+15
-8
lines changed

3 files changed

+15
-8
lines changed

pandas/io/parquet.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
from pandas.io.common import get_filepath_or_buffer
99
from pandas.io.s3 import is_s3_url
1010

11+
1112
def get_engine(engine):
1213
""" return our implementation """
1314

@@ -191,7 +192,7 @@ def __init__(self):
191192

192193
def write(self, df, path, compression='snappy', **kwargs):
193194
if is_s3_url(path):
194-
raise NotImplementedError("fastparquet s3 write is not implemented."
195+
raise NotImplementedError("fastparquet s3 write isn't implemented."
195196
" Consider using pyarrow instead.")
196197

197198
self.validate_dataframe(df)

pandas/tests/io/test_parquet.py

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -229,21 +229,26 @@ def check_round_trip(self, df, engine, expected=None, path=None,
229229
with tm.ensure_clean() as path:
230230
df.to_parquet(path, engine, **write_kwargs)
231231
actual = read_parquet(path, engine, **read_kwargs)
232-
tm.assert_frame_equal(expected, actual, check_names=check_names)
232+
tm.assert_frame_equal(expected, actual,
233+
check_names=check_names)
233234

234235
# repeat
235236
df.to_parquet(path, engine, **write_kwargs)
236237
actual = read_parquet(path, engine, **read_kwargs)
237-
tm.assert_frame_equal(expected, actual, check_names=check_names)
238+
tm.assert_frame_equal(expected, actual,
239+
check_names=check_names)
238240
else:
239241
df.to_parquet(path, engine, **write_kwargs)
240242
actual = read_parquet(path, engine, **read_kwargs)
241-
tm.assert_frame_equal(expected, actual, check_names=check_names)
243+
tm.assert_frame_equal(expected, actual,
244+
check_names=check_names)
242245

243246
# repeat
244247
df.to_parquet(path, engine, **write_kwargs)
245248
actual = read_parquet(path, engine, **read_kwargs)
246-
tm.assert_frame_equal(expected, actual, check_names=check_names)
249+
tm.assert_frame_equal(expected, actual,
250+
check_names=check_names)
251+
247252

248253
class TestBasic(Base):
249254

@@ -433,7 +438,8 @@ def test_categorical_unsupported(self, pa_lt_070):
433438

434439
def test_s3_roundtrip(self, df_compat, s3_resource, pa):
435440
# GH #19134
436-
self.check_round_trip(df_compat, pa, path='s3://pandas-test/pyarrow.parquet')
441+
self.check_round_trip(df_compat, pa,
442+
path='s3://pandas-test/pyarrow.parquet')
437443

438444

439445
class TestParquetFastParquet(Base):
@@ -497,4 +503,5 @@ def test_filter_row_groups(self, fp):
497503
def test_s3_roundtrip(self, df_compat, s3_resource, fp):
498504
# GH #19134
499505
with pytest.raises(NotImplementedError):
500-
self.check_round_trip(df_compat, fp, path='s3://pandas-test/fastparquet.parquet')
506+
self.check_round_trip(df_compat, fp,
507+
path='s3://pandas-test/fastparquet.parquet')

pandas/tests/io/test_s3.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,3 @@ class TestS3URL(object):
66
def test_is_s3_url(self):
77
assert is_s3_url("s3://pandas/somethingelse.com")
88
assert not is_s3_url("s4://pandas/somethingelse.com")
9-

0 commit comments

Comments
 (0)