-
Notifications
You must be signed in to change notification settings - Fork 219
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
BOM-1537 : Upgrade to Python 3.8 #452
Conversation
8175a1d
to
3fd43ce
Compare
@mzulqarnain1 See also #454 #453 for some potential warnings related to migration. |
bbbe558
to
734bca2
Compare
@@ -146,15 +146,15 @@ def POST(self): | |||
querydict_to_multidict(self._request.FILES, wrap=DjangoUploadedFile), | |||
) | |||
|
|||
@lazy | |||
def body(self): # pylint: disable=method-hidden | |||
@property |
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.
please add a reason for this change.
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.
Both of these are marked as property
in class we are inheriting from so pylint suggested making it property
in child class too.
@@ -139,7 +138,7 @@ def load_classes(cls, fail_silently=True): | |||
""" | |||
all_classes = itertools.chain( | |||
pkg_resources.iter_entry_points(cls.entry_point), | |||
(entry_point for identifier, entry_point in cls.extra_entry_points), | |||
(entry_point for identifier, entry_point in iter(cls.extra_entry_points)), |
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.
why you are doing this ?
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 a lazy member of our class which returns a list when called, but pylint doesn't consider it an iterable and warns, so wrapping it in iter()
does the trick.
@@ -54,22 +54,18 @@ def __new__(cls, scope, user_id, block_scope_id, field_name, block_family='xbloc | |||
@abstractmethod | |||
def get(self, key): | |||
"""Reads the value of the given `key` from storage.""" |
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 think you can disable the pass warning instead of removing.
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.
Should I go on and re-add all the pass
?
734bca2
to
23e43fd
Compare
23e43fd
to
70065e0
Compare
Relevant JIRA : https://openedx.atlassian.net/browse/BOM-1537