Skip to content

0.6.0

Compare
Choose a tag to compare
@dargueta dargueta released this 16 Feb 15:52
· 198 commits to master since this release

Released: 2019-02-16

New Features

New field types were added:

  • Float16: half-precision floating-point numbers. While this has technically
    been supported since 0.4.3, it was never made explicit. Float16 only works
    on Python 3.6 and above. Attempting to use it on Python 3.5 will trigger a
    ValueError.
  • Timestamp, Timestamp32, and Timestamp64.

Bugfixes

  • Integer accidentally used some positional arguments instead of keyword-only.
    Only a breaking change for people who used it directly (rare) and ignored the
    "only use keyword argumets" advice.
  • Integer wasn't catching OverflowError and rethrowing it as an
    UnserializableValueError like it was supposed to.
  • helpers.iter_bytes() would iterate through the entire stream if max_bytes
    was 0.
  • Struct.to_dict() didn't omit fields marked with discard.

Breaking Changes

  • Support for Python 3.4 was dropped (deprecated 0.5.1).
  • Zigzag integer encoding support was dropped (deprecated 0.5.0).
  • Removed the validation module and moved the decorator marker to decorators.
  • Struct.to_dict() now omits fields marked with discard. They used to be
    left in due to a bug that has now been fixed.
  • Float and String field class constructors have been changed to throw
    ConfigurationError instead of other exception types, to be more in line
    with the other fields.