Skip to content

Commit

Permalink
Fix method return type (strict python noticed we return None here)
Browse files Browse the repository at this point in the history
  • Loading branch information
andreilitvin committed Jun 8, 2023
1 parent 64d1df0 commit 409ee1a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/py_matter_idl/matter_idl/lint/lint_rules_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import xml.etree.ElementTree
from dataclasses import dataclass
from enum import Enum, auto
from typing import List, MutableMapping, Tuple, Union
from typing import List, MutableMapping, Optional, Tuple, Union

from lark import Lark
from lark.visitors import Discard, Transformer, v_args
Expand Down Expand Up @@ -167,7 +167,7 @@ def GetLinterRules(self):
def RequireAttribute(self, r: AttributeRequirement):
self._required_attributes_rule.RequireAttribute(r)

def FindClusterCode(self, name: str) -> Tuple[str, int]:
def FindClusterCode(self, name: str) -> Optionarl[Tuple[str, int]]:
if name not in self._cluster_codes:
# Name may be a number. If this can be parsed as a number, accept it anyway
try:
Expand Down

0 comments on commit 409ee1a

Please sign in to comment.