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

Do some type changes and cleanup #42

Merged
merged 2 commits into from
Dec 1, 2023
Merged

Do some type changes and cleanup #42

merged 2 commits into from
Dec 1, 2023

Conversation

mdumandag
Copy link
Contributor

  • Changed the return type of geosearch commands from typed-dict to dataclass, to make it easier to use. Also, it conveys the optionality of the fields better now.
  • Changed return types of sdiff, sunion, sinter, and smembers method to list from set. This eliminates extra set allocation for users doing iteration over the result. If they want, they can return the list into set themselves.
  • Removed poetry.lock from the repo. We are a library, and the lock file will not be considered at all when the users install our library. If there is a problem in on of our depdencies during install, we would not be able to detect it at all due to lock file.
  • Also applied isort and black into the codebase.

- Changed the return type of geosearch commands from typed-dict to
  dataclass, to make it easier to use. Also, it conveys the optionality
  of the fields better now.
- Changed return types of sdiff, sunion, sinter, and smembers method
  to list from set. This eliminates extra set allocation for users
  doing iteration over the result. If they want, they can return the
  list into set themselves.
- Removed poetry.lock from the repo. We are a library, and the lock
  file will not be considered at all when the users install our library.
  If there is a problem in on of our depdencies during install, we would
  not be able to detect it at all due to lock file.
- Also applied isort and black into the codebase.
@mdumandag mdumandag requested a review from ytkimirti November 29, 2023 15:40
@mdumandag mdumandag merged commit ab4ac5a into main Dec 1, 2023
1 check passed
@mdumandag mdumandag deleted the type-fixes branch December 1, 2023 11:22
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.

2 participants