Skip to content

Commit

Permalink
dropped lxml dependency in build script
Browse files Browse the repository at this point in the history
  • Loading branch information
keighrim committed Mar 1, 2024
1 parent c6ef677 commit dae2e83
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
6 changes: 3 additions & 3 deletions build.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,14 @@ def get_soup() -> BeautifulSoup:
"<head></head>" +
"<body></body>" +
"</html>",
features='lxml')
features='html.parser')


def tag(tagname: str, attrs: Optional[Dict] = None, text: Optional[str] = None, dtrs: Optional[List[Tag]] = None) -> Tag:
"""Return a soup Tag element."""
attrs = {} if attrs is None else attrs
dtrs = [] if dtrs is None else dtrs
newtag = BeautifulSoup('', features='lxml').new_tag(tagname, attrs=attrs)
newtag = BeautifulSoup('', features='html.parser').new_tag(tagname, attrs=attrs)
if text is not None:
newtag.append(text)
for dtr in dtrs:
Expand Down Expand Up @@ -258,7 +258,7 @@ def _add_ontologies(self) -> None:
<a href='ontologies/clams.vocabulary.rdf'>RDF</a>,
<a href='ontologies/clams.vocabulary.owl'>OWL</a>,
<a href='ontologies/clams.vocabulary.jsonld'>JSONLD</a> and
<a href='ontologies/clams.vocabulary.ttl'>TTL</a>.</p>""", features="lxml")
<a href='ontologies/clams.vocabulary.ttl'>TTL</a>.</p>""", features="html.parser")
for element in onto_soup.body:
self.main_content.append(element)

Expand Down
1 change: 0 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
beautifulsoup4
lxml
PyYAML

0 comments on commit dae2e83

Please sign in to comment.