Skip to content

Commit

Permalink
style: [AXM-506] Replace noqa to pylint disable
Browse files Browse the repository at this point in the history
  • Loading branch information
KyryloKireiev committed Jun 26, 2024
1 parent 2815bc5 commit c49ad6b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion lms/djangoapps/mobile_api/course_info/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def get_course_modes(self, course_overview):
for mode in course_modes
]

def get_course_progress(self, obj: 'CourseOverview') -> Dict[str, int]: # noqa: F821
def get_course_progress(self, obj: CourseOverview) -> Dict[str, int]:
"""
Gets course progress calculated by course assignments.
"""
Expand Down
6 changes: 3 additions & 3 deletions lms/djangoapps/mobile_api/course_info/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@


def calculate_progress(
user: 'User', # noqa: F821
course_id: 'CourseLocator', # noqa: F821
user: 'User', # lint-amnesty, pylint: disable=unused-variable
course_id: 'CourseLocator', # lint-amnesty, pylint: disable=unused-variable
cache_timeout: int,
) -> Optional[List[Union['ReadSubsectionGrade', 'ZeroSubsectionGrade']]]: # noqa: F821
) -> Optional[List[Union['ReadSubsectionGrade', 'ZeroSubsectionGrade']]]: # lint-amnesty, pylint: disable=unused-variable, line-too-long
"""
Calculate the progress of the user in the course.
"""
Expand Down
4 changes: 2 additions & 2 deletions lms/djangoapps/mobile_api/users/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def get_course_modes(self, obj):
for mode in course_modes
]

def to_representation(self, instance: CourseEnrollment) -> 'OrderedDict': # noqa: F821
def to_representation(self, instance: CourseEnrollment) -> 'OrderedDict': # lint-amnesty, pylint: disable=unused-variable, line-too-long
"""
Override the to_representation method to add the course_status field to the serialized data.
"""
Expand Down Expand Up @@ -205,7 +205,7 @@ def get_course_status(self, model: CourseEnrollment) -> Optional[Dict[str, List[
@staticmethod
def _get_last_visited_block_path_and_unit_name(
block_id: str
) -> Union[Tuple[None, None], Tuple[List['XBlock'], str]]: # noqa: F821
) -> Union[Tuple[None, None], Tuple[List['XBlock'], str]]: # lint-amnesty, pylint: disable=unused-variable
"""
Returns the path to the latest block and unit name visited by the current user.
"""
Expand Down

0 comments on commit c49ad6b

Please sign in to comment.