-
Notifications
You must be signed in to change notification settings - Fork 265
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
Use canonical fully qualified class names for metrics #1680
Conversation
Note that the current JSON data release does not use the canonical fully-qualified class names; we could use a script to rewrite the JSON to the correct names. |
e2b5ec9
to
b98ac8b
Compare
@@ -1,98 +0,0 @@ | |||
# Add any classes that need to be loaded dynamically via `create_object`. |
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.
This is great :)
6347118
to
89ba7de
Compare
mypy is failing due to an unrelated issue |
89ba7de
to
ff3c770
Compare
class_name = components[-1] | ||
module_name = ".".join(components[:-1]) | ||
cls = getattr(importlib.import_module(module_name), class_name) |
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.
This pattern shows up three times...could we factor it out or put a comment that we need to sync?
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.
Added todo.
The current implementation of
create_object()
is obsolete and incorrect; see this answer for the correct version.This also means we don't need to keep adding names to the
__init__.py
file.Addresses #1327