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

Fork sort Package from Go 1.13 to Ensure Stability Across Go Versions #487

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

endale98
Copy link

@endale98 endale98 commented Dec 4, 2024

Summary

This pull request introduces a forked version of the sort package from Go 1.13 to replace the current sort package in our codebase. The goal is to prevent instability caused by discrepancies in sorts implementations across different Go versions.

Details

Forked sorts Package

  • Imported the sorts package from Go 1.13 into our codebase.
  • Placed the forked package under internal/sorts to avoid naming conflicts.

Updated References

  • Modified all import statements to use the new forked package.
  • Ensured that all sorting functions now utilize the forked version.

Reasoning

We’ve observed inconsistencies in sorting behavior due to updates and changes in the sorts package in newer Go versions. By standardizing on the Go 1.13 version, we ensure:

  • Consistent Behavior: Uniform sorting results across all environments.
  • Stability: Reduced risk of bugs introduced by future Go version updates.
  • Control: Ability to patch or modify the sorting functions as needed.

Impact

Positive:

  • Improved stability and predictability of sorting operations.
  • Easier debugging and maintenance due to consistent sorting logic.

Neutral:

  • No expected performance degradation.
  • API remains the same; no changes required for dependent code.

Negative:

  • Slight increase in codebase size due to inclusion of the forked package.

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.

1 participant