-
Notifications
You must be signed in to change notification settings - Fork 1
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
extractor: Add list based lookups #619
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❌ Changes requested. Reviewed everything up to 22e839f in 1 minute and 30 seconds
More details
- Looked at
779
lines of code in12
files - Skipped
1
files when reviewing. - Skipped posting
3
drafted comments based on config settings.
1. fennel/testing/query_engine.py:470
- Draft comment:
Remove print statements used for debugging purposes. Consider using a logging framework if needed for debugging. - Reason this comment was not posted:
Marked as duplicate.
2. fennel/testing/query_engine.py:471
- Draft comment:
Remove print statements used for debugging purposes. Consider using a logging framework if needed for debugging. - Reason this comment was not posted:
Marked as duplicate.
3. fennel/featuresets/featureset.py:704
- Draft comment:
Remove print statements used for debugging purposes. Consider using a logging framework if needed for debugging. - Reason this comment was not posted:
Marked as duplicate.
Workflow ID: wflow_rEmp52xpSvgtHjqx
Want Ellipsis to fix these issues? Tag @ellipsis-dev
in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
fennel/testing/query_engine.py
Outdated
input_feature.name | ||
].explode() | ||
|
||
print(repeated_timestamps) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove print statements used for debugging purposes. Consider using a logging framework if needed for debugging.
22e839f
to
0055a20
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Looks good to me! Incremental review on 0055a20 in 41 seconds
More details
- Looked at
830
lines of code in13
files - Skipped
1
files when reviewing. - Skipped posting
1
drafted comments based on config settings.
1. fennel/internal_lib/to_proto/to_proto.py:727
- Draft comment:
Simplify the extractor type check by using a set for comparison.
if extractor.extractor_type in {ExtractorType.LOOKUP, ExtractorType.LIST_LOOKUP}:
- Reason this comment was not posted:
Confidence changes required:50%
The code infennel/internal_lib/to_proto/to_proto.py
has a repeated logic for checking the extractor type. This can be simplified by using a set for comparison.
Workflow ID: wflow_DXCh8OltvKXMNLKD
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
0055a20
to
9f87486
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Looks good to me! Incremental review on 9f87486 in 44 seconds
More details
- Looked at
833
lines of code in13
files - Skipped
1
files when reviewing. - Skipped posting
4
drafted comments based on config settings.
1. fennel/client_tests/test_complex_autogen_extractor.py:349
- Draft comment:
Consider usingrelativedelta
from thedateutil
library to calculateage_years
more clearly and accurately. - Reason this comment was not posted:
Confidence changes required:50%
The code infennel/client_tests/test_complex_autogen_extractor.py
uses a manual calculation forage_years
that could be simplified using a library function. This would improve readability and maintainability.
2. fennel/featuresets/featureset.py:702
- Draft comment:
Good use ofget_origin
to check for list types. This ensures proper handling of generic types. - Reason this comment was not posted:
Confidence changes required:0%
The code infennel/featuresets/featureset.py
usesget_origin
to check for list types. This is a good practice to ensure type checking for generic types.
3. fennel/testing/query_engine.py:493
- Draft comment:
Consider refactoring the repeated pattern of settingdataset_lookup
to improve code clarity and reduce redundancy. - Reason this comment was not posted:
Confidence changes required:30%
The code infennel/testing/query_engine.py
has a repeated pattern for handlingdataset_lookup
which could be refactored for clarity.
4. fennel/testing/query_engine.py:487
- Draft comment:
Good use offillna
for handling default values in dataframes. This is a standard practice for managing missing data. - Reason this comment was not posted:
Confidence changes required:0%
The code infennel/testing/query_engine.py
usesfillna
for handling default values, which is a good practice for handling missing data.
Workflow ID: wflow_ZYreki6olbI58Tb8
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
9f87486
to
ff27874
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Looks good to me! Incremental review on ff27874 in 43 seconds
More details
- Looked at
77
lines of code in2
files - Skipped
0
files when reviewing. - Skipped posting
1
drafted comments based on config settings.
1. fennel/testing/mock_client.py:530
- Draft comment:
Remove the print statement in the exception handling block. Use logging if necessary. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable:
This is a testing/mock client file used for testing purposes. The print statement is added in an error case to help with debugging by showing the problematic dataframe before raising the exception. While using logging would be more standard, in a testing context having print statements for debugging is quite reasonable. The print provides immediately visible debug info that could be helpful during test failures.
The comment makes a valid point that logging is generally preferred over print statements in production code. Print statements can be problematic if output needs to be captured or redirected.
However, this is test code where print statements are commonly used for debugging visibility. The print statement serves a clear debugging purpose by showing the problematic dataframe before the exception.
The comment should be deleted. While it makes a technically valid point, using print for debugging in test code is reasonable and the print statement serves a clear purpose here.
Workflow ID: wflow_gMizF6igq6OgoGvD
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
ff27874
to
bb924f2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Looks good to me! Incremental review on bb924f2 in 23 seconds
More details
- Looked at
75
lines of code in2
files - Skipped
0
files when reviewing. - Skipped posting
1
drafted comments based on config settings.
1. fennel/testing/mock_client.py:530
- Draft comment:
Remove the print statement inside the exception handling block to clean up the code. - Reason this comment was not posted:
Confidence changes required:50%
The print statement in the exception handling block is not necessary for production code. It can be removed to clean up the code.
Workflow ID: wflow_BGqUV3FajGLQSBFW
You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
Important
Add
LIST_LOOKUP
type to extractors for list-based lookups, update query engine, and add tests.LIST_LOOKUP
type toExtractorType
infeatureset_pb2.py
andfeatureset_pb2.pyi
.Extractor
class infeatureset.py
to supportLIST_LOOKUP
._get_generated_extractors
and_validate
infeatureset.py
to handle list-based features._compute_list_lookup_extractor
inquery_engine.py
to handle list-based lookups.run_extractors
inquery_engine.py
to processLIST_LOOKUP
extractors.test_featureset.py
andtest_invalid_featureset.py
.test_expr.py
andtest_complex_autogen_extractor.py
to reflect changes.pyproject.toml
to includeattrs
dependency.This description was created by for bb924f2. It will automatically update as commits are pushed.