File graphic_soulforge_preview.py
has 256 lines of code (exceeds 250 allowed). Consider refactoring. Open
import io
import math
from typing import Mapping
from wand.color import Color
Too many local variables (25/15) Open
def render_soulforge_screen(self):
- Read upRead up
- Exclude checks
Used when a function or method has too many local variables.
Too many local variables (28/15) Open
def render_affixes(self):
- Read upRead up
- Exclude checks
Used when a function or method has too many local variables.
Too many local variables (16/15) Open
def render_farming(self):
- Read upRead up
- Exclude checks
Used when a function or method has too many local variables.
Too many statements (63/50) Open
def render_affixes(self):
- Read upRead up
- Exclude checks
Used when a function or method has too many statements. You should then split it in smaller functions / methods.
Too many statements (79/50) Open
def render_soulforge_screen(self):
- Read upRead up
- Exclude checks
Used when a function or method has too many statements. You should then split it in smaller functions / methods.
Unable to import 'wand.drawing' Open
from wand.drawing import Drawing
- Read upRead up
- Exclude checks
Used when pylint has been unable to import a module.
Unable to import 'wand.color' Open
from wand.color import Color
- Read upRead up
- Exclude checks
Used when pylint has been unable to import a module.
Missing function or method docstring Open
def save_image(self):
- Read upRead up
- Exclude checks
Used when a function or method has no docstring.Some special methods like init do not require a docstring.
Line too long (109/100) Open
crafting_message = word_wrap(self.img, draw, self.data["texts"]["in_soulforge"], width - 20, 100)
- Read upRead up
- Exclude checks
Used when a line is longer than a given number of characters.
Missing class docstring Open
class WeeklyPreview(BasePreview):
- Read upRead up
- Exclude checks
Used when a class has no docstring.Even an empty class must have a docstring.
Line too long (102/100) Open
heading = f'{self.data["texts"]["dungeon"]} &\n{self.data["texts"]["kingdom_challenges"]}'
- Read upRead up
- Exclude checks
Used when a line is longer than a given number of characters.
Missing function or method docstring Open
def render_all(result):
- Read upRead up
- Exclude checks
Used when a function or method has no docstring.Some special methods like init do not require a docstring.
Missing module docstring Open
import io
- Read upRead up
- Exclude checks
Used when a module has no docstring.Empty modules do not require a docstring.
Missing function or method docstring Open
def render_affixes(self):
- Read upRead up
- Exclude checks
Used when a function or method has no docstring.Some special methods like init do not require a docstring.
Line too long (106/100) Open
my_affix.colorize(color=Color(f'rgb({color_code})'), alpha=Color('rgb(100%, 100%, 100%)'))
- Read upRead up
- Exclude checks
Used when a line is longer than a given number of characters.
Line too long (105/100) Open
description = word_wrap(self.img, draw, affix['description'], width - 80, base_size + 10)
- Read upRead up
- Exclude checks
Used when a line is longer than a given number of characters.
Missing function or method docstring Open
def render_soulforge_screen(self):
- Read upRead up
- Exclude checks
Used when a function or method has no docstring.Some special methods like init do not require a docstring.
Line too long (116/100) Open
center = left + 300 - hypotenuse * math.sin(rad_angle), top + 350 - hypotenuse * math.cos(rad_angle)
- Read upRead up
- Exclude checks
Used when a line is longer than a given number of characters.
Missing function or method docstring Open
def get_box_coordinates(self, box_number):
- Read upRead up
- Exclude checks
Used when a function or method has no docstring.Some special methods like init do not require a docstring.
Missing function or method docstring Open
def extract_requirements(self) -> Mapping[str, str]:
- Read upRead up
- Exclude checks
Used when a function or method has no docstring.Some special methods like init do not require a docstring.
Line too long (114/100) Open
f'x140 {self.data["texts"]["tier_8"]} {self.data["texts"]["kingdom_challenges"]}:\n{kingdoms}'
- Read upRead up
- Exclude checks
Used when a line is longer than a given number of characters.
Missing function or method docstring Open
def render_farming(self):
- Read upRead up
- Exclude checks
Used when a function or method has no docstring.Some special methods like init do not require a docstring.
Variable name x
doesn't conform to snake_case naming style Open
x = left + width
- Read upRead up
- Exclude checks
Used when the name doesn't conform to naming rules associated to its type (constant, variable, class...).
Line too long (121/100) Open
f'x100 {jewel["available_on"]}: {self.data["texts"]["gem_bounty"]} ({self.data["texts"]["n_gems"]})',
- Read upRead up
- Exclude checks
Used when a line is longer than a given number of characters.