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

fix: Avoid populating order.ordering with empties. #618

Merged
merged 5 commits into from
Jul 12, 2022

Conversation

shahzadlone
Copy link
Member

Relevant issue(s)

Resolves #589

Description

Hunch mentioned in last week's meeting was correct, it was indeed a make where it would populate the array with empties and then append being called on top of it.

Also removed the function IsEmpty(), we used to check for empty elements previously which was introduced in #481.

Tasks

  • I made sure the code is well commented, particularly hard-to-understand areas.
  • I made sure the repository-held documentation is changed accordingly.
  • I made sure the pull request title adheres to the conventional commit style (the subset used in the project can be found in tools/configs/chglog/config.yml).
  • I made sure to discuss its limitations such as threats to validity, vulnerability to mistake and misuse, robustness to invalidation of assumptions, resource requirements, ...

How has this been tested?

make test and CI checks.

Specify the platform(s) on which this was tested:

  • Arch Linux

@shahzadlone shahzadlone added bug Something isn't working action/no-benchmark Skips the action that runs the benchmark. area/mapper Related to the mapper components labels Jul 11, 2022
@shahzadlone shahzadlone added this to the DefraDB v0.3 milestone Jul 11, 2022
@shahzadlone shahzadlone requested a review from a team July 11, 2022 10:15
@shahzadlone shahzadlone self-assigned this Jul 11, 2022
@shahzadlone shahzadlone force-pushed the lone/fix/ordering-populated-by-empties branch from 85feaec to 64c5dc2 Compare July 11, 2022 13:27
Copy link
Contributor

@AndrewSisley AndrewSisley left a comment

Choose a reason for hiding this comment

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

That's a silly mistake! Sorry Shahzad, and sorry for not spotting it when we looked this over again last week!

Cheers for fixing

@shahzadlone
Copy link
Member Author

That's a silly mistake! Sorry Shahzad, and sorry for not spotting it when we looked this over again last week!

Cheers for fixing

We don't do mistakes, just happy accidents haha. Was a fun learning opportunity to watch out for those for myself aswell.

https://youtu.be/wCsO56kWwTc

Hunch was corrent, as mentioned in the standup it was indeed a
`make` where it would populate the array with empties and then again
append on top of them.)
@shahzadlone shahzadlone force-pushed the lone/fix/ordering-populated-by-empties branch from 64c5dc2 to e7eb47a Compare July 12, 2022 05:29
@shahzadlone shahzadlone merged commit eca5324 into develop Jul 12, 2022
@shahzadlone shahzadlone deleted the lone/fix/ordering-populated-by-empties branch July 12, 2022 05:37
shahzadlone added a commit to shahzadlone/defradb that referenced this pull request Feb 23, 2024
- Resolves: sourcenetwork#589 

- Description: Hunch mentioned in last week's meeting was correct, it was indeed a `make` where it would populate the array with empties and then append being called on top of it. Also removed the function `IsEmpty()`, we used to check for empty elements previously which was introduced in sourcenetwork#481.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
action/no-benchmark Skips the action that runs the benchmark. area/mapper Related to the mapper components bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

sortNode.ordering is populated by empty elements
2 participants