Skip to content

Commit

Permalink
Merge pull request googleapis#2992 from garye/patch-1
Browse files Browse the repository at this point in the history
Remove invalid chunk validation
  • Loading branch information
tseaver authored Feb 14, 2017
2 parents b1a7046 + d0af421 commit 6f98d17
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 16 deletions.
2 changes: 0 additions & 2 deletions bigtable/google/cloud/bigtable/row_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -366,8 +366,6 @@ def _validate_chunk_row_in_progress(self, chunk):
"""Helper for :meth:`_validate_chunk`"""
assert self.state == self.ROW_IN_PROGRESS
self._validate_chunk_status(chunk)
if not chunk.HasField('commit_row') and not chunk.reset_row:
_raise_if(not chunk.timestamp_micros or not chunk.value)
_raise_if(chunk.row_key and
chunk.row_key != self._row.row_key)
_raise_if(chunk.HasField('family_name') and
Expand Down
14 changes: 0 additions & 14 deletions bigtable/unit_tests/test_row_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -416,20 +416,6 @@ def test_invalid_empty_chunk(self):
with self.assertRaises(InvalidChunk):
prd.consume_next()

def test_invalid_empty_second_chunk(self):
from google.cloud.bigtable.row_data import InvalidChunk

chunks = _generate_cell_chunks(['', ''])
first = chunks[0]
first.row_key = b'RK'
first.family_name.value = 'A'
first.qualifier.value = b'C'
response = _ReadRowsResponseV2(chunks)
iterator = _MockCancellableIterator(response)
prd = self._make_one(iterator)
with self.assertRaises(InvalidChunk):
prd.consume_next()


class TestPartialRowsData_JSON_acceptance_tests(unittest.TestCase):

Expand Down

0 comments on commit 6f98d17

Please sign in to comment.