-
Notifications
You must be signed in to change notification settings - Fork 2.2k
docs(helper): add missing helper docstrings #1927
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1927 +/- ##
==========================================
+ Coverage 86.50% 86.52% +0.01%
==========================================
Files 148 148
Lines 7042 7056 +14
==========================================
+ Hits 6092 6105 +13
- Misses 950 951 +1
Continue to review full report at Codecov.
|
Latency summaryCurrent PR yields:
Breakdown
Backed by latency-tracking. Further commits will update this comment. |
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.
I'd rather remove not used functions.
@@ -904,7 +948,10 @@ def run_async(func, *args, **kwargs): | |||
""" | |||
|
|||
class RunThread(threading.Thread): | |||
"""Create a running thread when in Jupyter notebook.""" |
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 class is private to the function. Having docstrings is OK, but I'd still rename it to _RunThread
in order to highlight, that it is private.
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.
Done
jina/helper.py
Outdated
def run(self): | ||
"""Run function for thread.""" |
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.
"""Run function for thread.""" | |
"""Runs given `func` asynchronously.""" |
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.
Done
jina/helper.py
Outdated
@@ -743,11 +757,41 @@ def typename(obj): | |||
|
|||
|
|||
def rsetattr(obj, attr: str, val): |
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.
rsetattr
and rgetattr
are not used anywhere in the codebase anymore. Let's remove them.
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.
Done
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👍
No description provided.