Releases: thomasborgen/soup2dict
Releases · thomasborgen/soup2dict
2.1.0
2.1.0
This release moves some code around and introduces the new keyword argument as_json: bool
that, if True
, dumps the soup to json string
right from the function.
Feature
- Add
as_json
keyword parameter toconvert
Internal
- Moves
classes.typeclass
functions totransformer.py
and renames theconvert
function totransform
. This is so that we can have a newconvert
function in our__init__.py
with the new parameter and this feature will not introduce a breaking change. - Fix CI after main branch change
2.0.0
2.0.0
No new features in this release, but we now support python 3.9 and 3.10
Breaking
- soup2dict drops python 3.6 support
Features
- Add support for python 3.9 and 3.10
Internal
- Fixes poetry install in github workflows
- Cleans up github workflow
- Add python 3.9 and 3.10 to github workflows
The License
Patch adds MIT LICENSE and updates metadata in pyproject.toml
The Converter
First Release. Should be able handle most BeautifulSoup stuff
Features
- BeautifulSoup to dictionary converter
- Converts BeautifulSoup, ResultSet, (list), Tag and all descendants of NavigableString Classes.
- tag attributes are prefixed with
@
- text data is contained in
#text
key @class
is always a list of 1-many classes if it exists on the element- all sub elements are
element_name
keys with an array containing 1 to many dictionaries.