Skip to content

Releases: yukinarit/pyserde

v0.12.7

17 Dec 03:16
b39d881
Compare
Choose a tag to compare

What's Changed

Refactoring

  • Fix skip_if causing serialization of a recursive type to be O(2**n) instead of O(n) by @gschaffner in #452

Other changes

New Contributors

Full Changelog: v0.12.6...v0.12.7

v0.12.6

28 Nov 05:19
7119be7
Compare
Choose a tag to compare

What's Changed

Bug fixes

Other changes

New Contributors

Full Changelog: v0.12.5...v0.12.6

v0.12.5

11 Nov 07:42
1cba1da
Compare
Choose a tag to compare

What's Changed

Bug fixes

Full Changelog: v0.12.4...v0.12.5

v0.12.4

25 Oct 02:08
76e919c
Compare
Choose a tag to compare

What's Changed

Bug fixes

Other changes

New Contributors

Full Changelog: v0.12.3...v0.12.4

v0.12.3

09 Oct 02:58
fead102
Compare
Choose a tag to compare

What's Changed

Bug fixes

Refactoring

Test

Full Changelog: v0.12.2...v0.12.3

v0.12.2

25 Jul 15:32
031f4c4
Compare
Choose a tag to compare

What's Changed

New features

  • Add support for dataclasses with kw_only by @m472 in #413

Bug fixes

CI

Build

Documentation

Other changes

New Contributors

  • @m472 made their first contribution in #413

Full Changelog: v0.12.1...v0.12.2

v0.12.1

18 Jul 00:00
c09842b
Compare
Choose a tag to compare

What's Changed

Bug fixes

Refactoring

Documentation

Full Changelog: v0.12.0...v0.12.1

v0.12.0

15 Jul 08:21
7bb6c0f
Compare
Choose a tag to compare

What's Changed

New features

This example works correctly now

@serde
@dataclass
class Foo:
    a: int

@serde
@dataclass
class Bar:
    a: int

bar = Bar(10)
s = to_json(bar)
print(s)
print(from_json(Union[Foo, Bar], s))

However, This will introduce a breaking change!! The default behaviour when you pass Union directly was "Untagged" until v0.11.1, but since v0.12.0 it is "ExternalTagging".

The following code prints {"a": 10} until v0.11.1, but prints {"Bar": {"a": 10}} since v0.12.0

print(to_json(bar))

For more information about Union, please see the docs

Refactoring

Other changes

Full Changelog: v0.11.1...v0.12.0

v0.11.1

25 Jun 05:41
04cc5bf
Compare
Choose a tag to compare

What's Changed

New features

  • Support (de)serialize a subclass of primitive type by @yukinarit in #388

Bug fixes

  • Fix deserializing from incompatible value e.g. None by @yukinarit in #389

Refactoring

Other changes

New Contributors

Full Changelog: v0.11.0...v0.11.1

v0.11.0

13 Jun 04:27
da9bd5f
Compare
Choose a tag to compare

This release fixes a lot of untyped code of (de)serialize APIs e.g. to_json and from_json. We started using ruff and pyright as well as existing tools e.g. mypy to improve the quality of the code. So if you are a mypy/pyright/pylance user, you would probably get less type error or untyped warnings.

Also, pyserde guide was refactored a lot so that it will detail undocumented pyserde features as much as I can. I still think the documentation is not good enough, any help to improve guide, API docs and README is appreciated. 🙏

What's Changed

New features

Bug fixes

  • Fix mypy error for Optional and Union in (de)serialize APIs by @yukinarit in #371
  • Fix nested generic class deserialization by @kmsquire in #377
  • Fix variable length tuple codegen by @kykosic in #378

Build

Documentation

Other changes

New Contributors

Full Changelog: v0.10.8...v0.11.0