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

[Applab Datasets] Fix off-by-one error in upload scripts #32175

Merged
merged 1 commit into from Dec 3, 2019

Conversation

ajpal
Copy link
Contributor

@ajpal ajpal commented Nov 27, 2019

Description

ids for the purpose of the Data Tab are 1-indexed. I had set the id on each record correctly, but put them all in an array (0-indexed) and set them in firebase that way. As a result, the id on each record, did not match the id of the firebase node. This resulted in off-by-one errors when trying to edit or delete records
Before:
image
After:
image

Testing story

Reviewer Checklist:

  • Tests provide adequate coverage
  • Code is well-commented
  • New features are translatable or updates will not break translations
  • Relevant documentation has been added or updated
  • User impact is well-understood and desirable
  • Pull Request is labeled appropriately
  • Follow-up work items (including potential tech debt) are tracked and linked

Copy link

@epeach epeach left a comment

Choose a reason for hiding this comment

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

LGTM.

@ajpal ajpal merged commit 5eab058 into staging-next Dec 3, 2019
@ajpal ajpal deleted the nov27-firebase-csv branch December 3, 2019 17:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants