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

SCRIPTEXECUTE support #68

Merged
merged 39 commits into from
Jul 18, 2021
Merged

SCRIPTEXECUTE support #68

merged 39 commits into from
Jul 18, 2021

Conversation

AvitalFineRedis
Copy link
Contributor

No description provided.

@codecov
Copy link

codecov bot commented May 18, 2021

Codecov Report

Merging #68 (53b1106) into master (3a7d3a6) will increase coverage by 0.49%.
The diff coverage is 96.42%.

❗ Current head 53b1106 differs from pull request most recent head c14248b. Consider uploading reports for the commit c14248b to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##           master      #68      +/-   ##
==========================================
+ Coverage   96.90%   97.40%   +0.49%     
==========================================
  Files           8        8              
  Lines         776      848      +72     
==========================================
+ Hits          752      826      +74     
+ Misses         24       22       -2     
Impacted Files Coverage Δ
redisai/postprocessor.py 100.00% <ø> (ø)
redisai/command_builder.py 89.33% <88.46%> (-0.35%) ⬇️
redisai/__init__.py 100.00% <100.00%> (ø)
redisai/client.py 97.11% <100.00%> (+0.14%) ⬆️
redisai/dag.py 98.07% <100.00%> (ø)
redisai/pipeline.py 100.00% <100.00%> (+15.15%) ⬆️
redisai/utils.py 97.50% <100.00%> (ø)
test/test.py 99.77% <100.00%> (+0.02%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2778c16...c14248b. Read the comment docs.

@AvitalFineRedis AvitalFineRedis linked an issue May 18, 2021 that may be closed by this pull request
@AvitalFineRedis AvitalFineRedis marked this pull request as ready for review May 19, 2021 06:33
removing second poetry build call, since they can be done in one
Copy link
Collaborator

@alonre24 alonre24 left a comment

Choose a reason for hiding this comment

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

Nice work! (specially for a first task in RedisAI...), please follow the comments. Note that you should indicate that scriptrun is deprecated by using the suitable decorator (as we do in modelrun).
Regarding the tests, I think that there are many redundant checks that are not specific to the redisai-py client, and that we don't need to copy those from the flow tests. On the other hand, we may want to add some tests of running scripts that are using Redis commands (we can discuss it further on slack...)

redisai/client.py Outdated Show resolved Hide resolved
redisai/client.py Outdated Show resolved Hide resolved
redisai/client.py Outdated Show resolved Hide resolved
redisai/client.py Outdated Show resolved Hide resolved
redisai/client.py Show resolved Hide resolved
redisai/command_builder.py Show resolved Hide resolved
redisai/command_builder.py Outdated Show resolved Hide resolved
test/test.py Outdated Show resolved Hide resolved
test/test.py Outdated Show resolved Hide resolved
test/test.py Outdated Show resolved Hide resolved
@lgtm-com
Copy link

lgtm-com bot commented May 20, 2021

This pull request fixes 2 alerts when merging d17b278 into 3a7d3a6 - view on LGTM.com

fixed alerts:

  • 2 for Unused import

@lgtm-com
Copy link

lgtm-com bot commented May 20, 2021

This pull request fixes 2 alerts when merging a2e4b65 into 3a7d3a6 - view on LGTM.com

fixed alerts:

  • 2 for Unused import

test/test.py Outdated Show resolved Hide resolved
@lgtm-com
Copy link

lgtm-com bot commented May 23, 2021

This pull request fixes 2 alerts when merging 24537c8 into 3a7d3a6 - view on LGTM.com

fixed alerts:

  • 2 for Unused import

Change the function variable in scriptrun function from AnyStr to str
@sonarcloud
Copy link

sonarcloud bot commented May 25, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 5 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@lgtm-com
Copy link

lgtm-com bot commented May 25, 2021

This pull request fixes 2 alerts when merging 53b1106 into 3a7d3a6 - view on LGTM.com

fixed alerts:

  • 2 for Unused import

Copy link
Collaborator

@alonre24 alonre24 left a comment

Choose a reason for hiding this comment

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

Nice work! Tell me if you have any questions about the comments...

redisai/client.py Outdated Show resolved Hide resolved
redisai/client.py Outdated Show resolved Hide resolved
redisai/client.py Outdated Show resolved Hide resolved
redisai/client.py Outdated Show resolved Hide resolved
redisai/client.py Show resolved Hide resolved
test/test.py Outdated Show resolved Hide resolved
test/test.py Show resolved Hide resolved
redisai/client.py Outdated Show resolved Hide resolved
redisai/dag.py Outdated
from redisai.postprocessor import Processor
from redisai import command_builder as builder

Copy link
Collaborator

Choose a reason for hiding this comment

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

Why the changes here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't think it's mine :0
I saw here some of Chayim's commits

Copy link
Collaborator

Choose a reason for hiding this comment

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

Same as above :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I see here some functions that use builder. The DagTestCase does not pass without this import

test/test.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@alonre24 alonre24 left a comment

Choose a reason for hiding this comment

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

Nice! Almost ready, just some few small comments

redisai/client.py Outdated Show resolved Hide resolved

from redisai import command_builder as builder
import redis
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why there is a diff here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

PipelineTest does not pass without it

test/test.py Outdated Show resolved Hide resolved
test/test.py Outdated Show resolved Hide resolved
test/test.py Outdated Show resolved Hide resolved
test/test.py Outdated Show resolved Hide resolved
@sonarcloud
Copy link

sonarcloud bot commented Jul 18, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.0% 0.0% Duplication

Copy link
Collaborator

@alonre24 alonre24 left a comment

Choose a reason for hiding this comment

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

Nice work!

@AvitalFineRedis AvitalFineRedis merged commit 8182aa6 into master Jul 18, 2021
@AvitalFineRedis AvitalFineRedis deleted the scriptexecute_support branch July 18, 2021 11:14
@AvitalFineRedis AvitalFineRedis restored the scriptexecute_support branch July 18, 2021 11:14
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.

add support for SCRIPTEXECUTE
3 participants