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

fixed a potential bug #337

Merged
merged 11 commits into from
Aug 9, 2022
Merged

fixed a potential bug #337

merged 11 commits into from
Aug 9, 2022

Conversation

wiseaidev
Copy link
Contributor

@wiseaidev wiseaidev commented Aug 8, 2022

Related to #322

The reason for removing six, assuming you are using python 3.7+, is that it has the same memory footprint as the built-in range method:

>>> import six
>>> import sys
>>> from six.moves import xrange
>>> x = xrange(1,10000)
>>> a = range(1,10000)
>>> print (sys.getsizeof(a))
48
>>> print (sys.getsizeof(x))
48

Therefore, no benefits from using it instead of range.

Signed-off-by: wiseaidev <business@wiseai.dev>
Signed-off-by: wiseaidev <business@wiseai.dev>
Signed-off-by: wiseaidev <business@wiseai.dev>
Signed-off-by: wiseaidev <business@wiseai.dev>
Signed-off-by: wiseaidev <business@wiseai.dev>
Signed-off-by: wiseaidev <business@wiseai.dev>
Signed-off-by: wiseaidev <business@wiseai.dev>
Signed-off-by: wiseaidev <business@wiseai.dev>
)

try:
Copy link
Contributor

Choose a reason for hiding this comment

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

Nice catch!

@dvora-h dvora-h added the bug Something isn't working label Aug 9, 2022
@dvora-h
Copy link
Contributor

dvora-h commented Aug 9, 2022

@wiseaidev Great PR, thanks!

Can you solve the linter issue so that all the tests will run and we can merge it?

Signed-off-by: wiseaidev <business@wiseai.dev>
@wiseaidev
Copy link
Contributor Author

wiseaidev commented Aug 9, 2022

Hey @dvora-h, done! Do i need to push the poetry.lock file? cause i removed six from dependencies.

@wiseaidev
Copy link
Contributor Author

wiseaidev commented Aug 9, 2022

I see what's wrong, working on it! ping @dvora-h

Signed-off-by: wiseaidev <business@wiseai.dev>
@wiseaidev wiseaidev requested a review from dvora-h August 9, 2022 14:21
Signed-off-by: wiseaidev <business@wiseai.dev>
@dvora-h dvora-h merged commit ac6a75b into redis:main Aug 9, 2022
@dvora-h
Copy link
Contributor

dvora-h commented Aug 9, 2022

@wiseaidev Thanks for the quick fixes!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants