Skip to content

Commit

Permalink
Merge pull request #238 from kianmeng/fix-typos
Browse files Browse the repository at this point in the history
Fix typos
  • Loading branch information
facelessuser authored Jan 3, 2022
2 parents a8640aa + df1cf19 commit 0baf35b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion soupsieve/css_match.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ def assert_valid_input(cls, tag: Any) -> None:

# Fail on unexpected types.
if not cls.is_tag(tag):
raise TypeError("Expected a BeautifulSoup 'Tag', but instead recieved type {}".format(type(tag)))
raise TypeError("Expected a BeautifulSoup 'Tag', but instead received type {}".format(type(tag)))

@staticmethod
def is_doc(obj: 'bs4.Tag') -> bool:
Expand Down
8 changes: 4 additions & 4 deletions soupsieve/css_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -562,7 +562,7 @@ def parse_pseudo_class_custom(self, sel: _Selector, m: Match[str], has_selector:
selector = self.custom.get(pseudo)
if selector is None:
raise SelectorSyntaxError(
"Undefined custom selector '{}' found at postion {}".format(pseudo, m.end(0)),
"Undefined custom selector '{}' found at position {}".format(pseudo, m.end(0)),
self.pattern,
m.end(0)
)
Expand Down Expand Up @@ -828,7 +828,7 @@ def parse_combinator(
if not has_selector:
if not is_forgive or combinator != COMMA_COMBINATOR:
raise SelectorSyntaxError(
"The combinator '{}' at postion {}, must have a selector before it".format(combinator, index),
"The combinator '{}' at position {}, must have a selector before it".format(combinator, index),
self.pattern,
index
)
Expand Down Expand Up @@ -1007,7 +1007,7 @@ def parse_selectors(
if not has_selector:
if not is_forgive:
raise SelectorSyntaxError(
"Expected a selector at postion {}".format(m.start(0)),
"Expected a selector at position {}".format(m.start(0)),
self.pattern,
m.start(0)
)
Expand All @@ -1017,7 +1017,7 @@ def parse_selectors(
break
else:
raise SelectorSyntaxError(
"Unmatched pseudo-class close at postion {}".format(m.start(0)),
"Unmatched pseudo-class close at position {}".format(m.start(0)),
self.pattern,
m.start(0)
)
Expand Down
2 changes: 1 addition & 1 deletion tests/test_level4/test_placeholder_shown.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def test_placeholder_shown(self):
/* Value will override this input */
<input id="29" type placeholder="This is some text" value="Actual value">
/* Text area content overides the placeholder
/* Text area content overrides the placeholder
<textarea id="30" placeholder="This is some text">Value</textarea>
<textarea id="31" placeholder="This is some text">
Expand Down

0 comments on commit 0baf35b

Please sign in to comment.