Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

go/libraries/doltcore/{doltdb,table}: remove row access methods from doltdb.Table #1102

Merged
merged 1 commit into from Dec 10, 2020

Conversation

andy-wm-arthur
Copy link
Contributor

@andy-wm-arthur andy-wm-arthur commented Dec 10, 2020

Removed:

  • Table.GetRowByPKVals()
  • Table.GetRow()
  • Table.GetRows()

Had do to some refactoring along the way to fix dependency cycles.
Reversed dependency rowconv -> pipeline to pipeline -> rowconv

@@ -105,7 +104,7 @@ func updateTableWithNewSchema(ctx context.Context, tblName string, tbl *doltdb.T
}

err = rowData.Iter(ctx, func(k, v types.Value) (stop bool, err error) {
oldRow, _, err := tbl.GetRow(ctx, k.(types.Tuple), newSchema)
oldRow, err := row.FromNoms(newSchema, k.(types.Tuple), v.(types.Tuple))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is temporary for this change, we'll need a general purpose way to set defaults

@andy-wm-arthur andy-wm-arthur marked this pull request as ready for review December 10, 2020 00:39
Copy link
Member

@zachmu zachmu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine, but you should add a note in your commits / merge comment about the rationale for this change.

@andy-wm-arthur andy-wm-arthur merged commit 89796fe into master Dec 10, 2020
@andy-wm-arthur andy-wm-arthur deleted the andy/table-refactor branch December 10, 2020 01:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants