-
Notifications
You must be signed in to change notification settings - Fork 879
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
Fix primitive entrypoint #1891
Fix primitive entrypoint #1891
Conversation
featuretools/primitives/__init__.py
Outdated
if primitive.__name__ in scope: | ||
error = f"primitive with name \"{primitive.__name__}\" already exists" | ||
raise RuntimeError(error) |
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.
If we want to be more specific, we can include which modules contain the conflicting primitives.
Can we add a test case similar to what we do with the plugin_tests? I was thinking we'd update the test folder structure like this:
|
Codecov Report
@@ Coverage Diff @@
## main #1891 +/- ##
=======================================
Coverage 98.76% 98.77%
=======================================
Files 147 148 +1
Lines 16307 16354 +47
=======================================
+ Hits 16106 16153 +47
Misses 201 201
Continue to review full report at Codecov.
|
Co-authored-by: Gaurav Sheni <gvsheni@gmail.com>
@rwedge ready for review |
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.
LGTM
Using
featuretools_primtives
as an entry point to load external primitive results in an error because we attempt to iterate over the module.This fix iterates over the keys in the module to extract primitive objects.