mirror of
https://github.com/django-components/django-components.git
synced 2025-09-26 15:39:08 +00:00
refactor: ruff - underscore unused vars
This commit is contained in:
parent
f100cc1836
commit
d30f352981
4 changed files with 4 additions and 4 deletions
|
@ -846,7 +846,7 @@ def _extract_property_docstrings(cls: Type) -> Dict[str, str]:
|
|||
- The function assumes that the class is defined at the global scope (module level)
|
||||
and that the body is indented with 4 spaces.
|
||||
"""
|
||||
lines, start_line_index = inspect.getsourcelines(cls)
|
||||
lines, _start_line_index = inspect.getsourcelines(cls)
|
||||
attrs_lines: List[str] = []
|
||||
ignore = True
|
||||
for line in lines:
|
||||
|
|
|
@ -155,7 +155,7 @@ class ComponentListCommand(ListCommand):
|
|||
data: List[Dict[str, Any]] = []
|
||||
for component in components:
|
||||
full_name = get_import_path(component)
|
||||
module, module_name, module_file_path = get_module_info(component)
|
||||
_module, _module_name, module_file_path = get_module_info(component)
|
||||
|
||||
# Make paths relative to CWD
|
||||
if module_file_path:
|
||||
|
|
|
@ -837,7 +837,7 @@ def _resolve_component_relative_files(
|
|||
|
||||
component_name = comp_cls.__qualname__
|
||||
# Get the full path of the file where the component was defined
|
||||
module, module_name, module_file_path = get_module_info(comp_cls)
|
||||
_module, module_name, module_file_path = get_module_info(comp_cls)
|
||||
if not module_file_path:
|
||||
logger.debug(
|
||||
f"Could not resolve the path to the file for component '{component_name}'."
|
||||
|
|
|
@ -233,7 +233,7 @@ class ComponentFormatter(TagFormatterABC):
|
|||
return f"end{self.tag}"
|
||||
|
||||
def parse(self, tokens: List[str]) -> TagResult:
|
||||
tag, *args = tokens
|
||||
_tag, *args = tokens
|
||||
|
||||
if not args:
|
||||
raise TemplateSyntaxError(f"{self.__class__.__name__}: Component tag did not receive tag name")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue