Skip to content

Commit

Permalink
chore: make sure to include the new row key in row merging errors (#2046
Browse files Browse the repository at this point in the history
)

* chore: make sure to include the new row key in row merging errors

Change-Id: Ieebc425d359a426d24c1ed69d0093e97635bd742

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
igorbernstein2 and gcf-owl-bot[bot] committed Jan 12, 2024
1 parent 55d1fb9 commit 90cacb2
Showing 1 changed file with 4 additions and 0 deletions.
Expand Up @@ -277,6 +277,10 @@ State handleLastScannedRow(ByteString rowKey) {

@Override
State handleChunk(CellChunk chunk) {
// Make sure to populate the rowKey before validations so that validation failures include
// the new key
rowKey = chunk.getRowKey();

validate(!chunk.getResetRow(), "AWAITING_NEW_ROW: can't reset");
validate(!chunk.getRowKey().isEmpty(), "AWAITING_NEW_ROW: rowKey missing");
validate(chunk.hasFamilyName(), "AWAITING_NEW_ROW: family missing");
Expand Down

0 comments on commit 90cacb2

Please sign in to comment.