[Cosmetic] unkown -> unknown

This commit is contained in:
Salvador E. Tropea 2023-03-28 11:22:19 -03:00
parent 921f5260c5
commit 895d852ed2
17 changed files with 33 additions and 33 deletions

View File

@ -211,7 +211,7 @@ def apply_fixed_filter(comps, filter):
class BaseFilter(RegFilter):
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
self._internal = False
# Two type of filters:
# Transform: can change the component. Returns
@ -381,7 +381,7 @@ class FieldRename(Optionable):
""" Field translation """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.field = ''
""" Name of the field to rename """

View File

@ -21,7 +21,7 @@ class Environment(Optionable):
""" Used to define the KiCad environment vars """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.symbols = ''
""" System level symbols dir. KiCad 5: KICAD_SYMBOL_DIR. KiCad 6: KICAD6_SYMBOL_DIR """
@ -95,7 +95,7 @@ class KiCadAlias(Optionable):
""" KiCad alias (for 3D models) """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.name = ''
""" Name of the alias """
@ -280,7 +280,7 @@ class Globals(FiltersOptions):
self.set_doc('filters', " [list(dict)] KiBot warnings to be ignored ")
self._filter_what = 'KiBot warnings'
self.filters = FilterOptionsKiBot
self._unkown_is_error = True
self._unknown_is_error = True
self._error_context = 'global '
def set_global(self, opt):

View File

@ -146,7 +146,7 @@ class Layer(Optionable):
""" Suffix used in file names related to this layer. Derived from the name if not specified """
self.description = ''
""" A description for the layer, for documentation purposes """
self._unkown_is_error = True
self._unknown_is_error = True
self._protel_extension = None
def config(self, parent):

View File

@ -43,7 +43,7 @@ class Optionable(object):
_color_re_component = re.compile(HEX_DIGIT)
def __init__(self):
self._unkown_is_error = False
self._unknown_is_error = False
self._error_context = ''
self._tree = {}
self._configured = False
@ -138,7 +138,7 @@ class Optionable(object):
for k, v in self._tree.items():
# Map known attributes and avoid mapping private ones
if (k[0] == '_') or (k not in attrs):
if self._unkown_is_error:
if self._unknown_is_error:
valid = list(filter(lambda x: x[0] != '_', attrs.keys()))
msg = "Unknown {}option `{}`.".format(self._error_context, k)
possible = difflib.get_close_matches(k, valid, n=1)

View File

@ -25,7 +25,7 @@ class DrillMap(Optionable):
self.type = 'pdf'
""" [hpgl,ps,gerber,dxf,svg,pdf] Format for a graphical drill map """
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
class DrillReport(Optionable):
@ -35,7 +35,7 @@ class DrillReport(Optionable):
self.filename = ''
""" Name of the drill report. Not generated unless a name is specified.
(%i='drill_report' %x='txt') """
self._unkown_is_error = True
self._unknown_is_error = True
class AnyDrill(VariantOptions):

View File

@ -90,7 +90,7 @@ class BaseOutput(RegOutput):
self._sch_related = False
self._both_related = False
self._none_related = False
self._unkown_is_error = True
self._unknown_is_error = True
self._done = False
self._category = None
@ -196,7 +196,7 @@ class BoMRegex(Optionable):
""" Implements the pair column/regex """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.column = ''
""" Name of the column to apply the regular expression.

View File

@ -60,7 +60,7 @@ class PCB2BlenderOptions(Optionable):
This option controls if we add it for none, all or only for THT/SMD pads with solder paste """
self.stack_boards = True
""" Move the sub-PCBs to their relative position """
self._unkown_is_error = True
self._unknown_is_error = True
class BlenderOutputOptions(Optionable):
@ -79,7 +79,7 @@ class BlenderOutputOptions(Optionable):
self.output = GS.def_global_output
""" Name for the generated file (%i='3D_blender_$VIEW' %x=VARIABLE).
The extension is selected from the type """
self._unkown_is_error = True
self._unknown_is_error = True
class BlenderLightOptions(Optionable):
@ -95,7 +95,7 @@ class BlenderLightOptions(Optionable):
""" [number|string] Y position [m]. You can use `width`, `height` and `size` for PCB dimensions """
self.pos_z = 0
""" [number|string] Z position [m]. You can use `width`, `height` and `size` for PCB dimensions """
self._unkown_is_error = True
self._unknown_is_error = True
def solve(self, member):
val = getattr(self, member)
@ -154,7 +154,7 @@ class BlenderRenderOptions(Optionable):
self.auto_crop = False
""" When enabled the image will be post-processed to remove the empty space around the image.
In this mode the `background2` is changed to be the same as `background1` """
self._unkown_is_error = True
self._unknown_is_error = True
class BlenderPointOfViewOptions(Optionable):
@ -177,7 +177,7 @@ class BlenderPointOfViewOptions(Optionable):
self.file_id = ''
""" String to diferentiate the name of this view.
When empty we use the `view` """
self._unkown_is_error = True
self._unknown_is_error = True
self._file_id = ''
def config(self, parent):
@ -205,7 +205,7 @@ class PCB3DExportOptions(Base3DOptionsWithHL):
Populated components are the ones listed in `show_components` """
self._expand_id = 'blender_export'
self._expand_ext = 'pcb3d'
self._unkown_is_error = True
self._unknown_is_error = True
def get_output_name(self, out_dir):
p = self._parent
@ -278,7 +278,7 @@ class Blender_ExportOptions(BaseOptions):
""" *[dict|list(dict)] How the object is viewed by the camera """
super().__init__()
self._expand_id = '3D_blender'
self._unkown_is_error = True
self._unknown_is_error = True
def config(self, parent):
super().config(parent)

View File

@ -74,7 +74,7 @@ class BoMJoinField(Optionable):
self.text_before = ''
self.text_after = ''
return
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.field = ''
""" *Name of the field """
@ -134,7 +134,7 @@ class BoMColumns(Optionable):
""" Information for the BoM columns """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.field = ''
""" *Name of the field to use for this column.

View File

@ -40,7 +40,7 @@ class Download_Datasheets_Options(VariantOptions):
""" Instead of download things we already downloaded use symlinks """
# Used to collect the targets
self._dry = False
self._unkown_is_error = True
self._unknown_is_error = True
def config(self, parent):
super().config(parent)

View File

@ -32,7 +32,7 @@ class KiBoMRegex(Optionable):
""" Implements the pair column/regex """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.column = ''
""" Name of the column to apply the regular expression.
@ -59,7 +59,7 @@ class KiBoMColumns(Optionable):
""" Information for the BoM columns """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.field = ''
""" *Name of the field to use for this column.

View File

@ -135,7 +135,7 @@ class LayerOptions(Layer):
""" Data for a layer """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.color = ""
""" Color used for this layer """
@ -163,7 +163,7 @@ class PagesOptions(Optionable):
""" One page of the output document """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.mirror = False
""" Print mirrored (X axis inverted) """

View File

@ -41,7 +41,7 @@ class PosColumns(Optionable):
""" Which columns we want and its names """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.id = ''
""" *[Ref,Val,Package,PosX,PosY,Rot,Side] Internal name """

View File

@ -91,7 +91,7 @@ class QRCodeOptions(Optionable):
""" *[silk,copper] Layer for the footprint """
self.pcb_negative = False
""" Generate a negative image for the PCB """
self._unkown_is_error = True
self._unknown_is_error = True
def config(self, parent):
super().config(parent)

View File

@ -23,7 +23,7 @@ class TagReplaceBase(Optionable):
""" Tags to be replaced """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.tag = ''
""" Name of the tag to replace. Use `version` for a tag named `@version@` """

View File

@ -20,7 +20,7 @@ class FilterOptionsKiBot(Optionable):
""" Valid options for a filter entry """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.filter = ''
""" Name for the filter, for documentation purposes """

View File

@ -32,7 +32,7 @@ class KiCadVariable(Optionable):
""" KiCad variable definition """
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.name = ''
""" Name of the variable. The `version` variable will be expanded using `${version}` """

View File

@ -63,7 +63,7 @@ class Edge(object):
class SubPCBOptions(PanelOptions):
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.name = ''
""" *Name for this sub-pcb """
@ -352,7 +352,7 @@ class SubPCBOptions(PanelOptions):
class BaseVariant(RegVariant):
def __init__(self):
super().__init__()
self._unkown_is_error = True
self._unknown_is_error = True
with document:
self.name = ''
""" Used to identify this particular variant definition """