---
title: "msgspec 0.23.0 Breaking Changes on PyPI | Since.dev"
description: "What each msgspec release removed, renamed or changed: 9 breaking changes in 1 version on PyPI, each with its source."
canonical_url: https://since.dev/packages/pypi/msgspec
last_updated: 2026-12-04
---

# msgspec breaking changes

msgspec 0.23.0 (November 28, 2026) is its newest release with breaking changes, 9 of them. The first: Invalid YAML scalar values now raise DecodeError in msgspec 0.23.0. Every breaking API change we have recorded in msgspec on PyPI: 9 breaking changes in 1 version. Below, its one version with breaking changes, newest first, removals and renames first, each with its source.

Updated December 4, 2026

Latest version `0.23.0`, released November 28, 2026. [Source repository](https://github.com/msgspec/msgspec)

Packages on PyPI run on Python. [Python end of life dates](https://since.dev/calendar/python.md).

## msgspec 0.23.0 breaking changes

msgspec 0.23.0, released November 28, 2026: 9 breaking changes.

- **Behavior changed**  

Invalid YAML scalar values that previously raised ValueError, LookupError or AttributeError now raise DecodeError. Code catching those exceptions must catch DecodeError. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)
- **Behavior changed**  

JSON schemas for fieldless array-like structs and named tuples no longer include empty prefixItems arrays. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)
- **Behavior changed**  

With decimal_format set to number, non-finite Decimal values are now rejected instead of being encoded. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)
- **Behavior changed**  

Datetime and time strings containing embedded NUL bytes are now rejected. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)
- **Behavior changed**  

Decoding ISO 8601 durations with overflowing day counts now fails instead of being accepted. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)
- **Behavior changed**  

Named tuples are only identified when their \_fields and \_field_defaults metadata are valid, and inspection applies the same checks. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)
- **Behavior changed**  

Decoding invalid UTF-8 as JSON, MessagePack or TOML now raises msgspec's DecodeError. Code that catches UnicodeDecodeError must catch DecodeError instead. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)
- **Behavior changed**  

str_keys=True now applies to dictionary keys even when their types appear in builtin_types, including date and time keys in TOML. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)
- **Behavior changed** `msgspec.toml.encode`  

When the converted top-level value is not a table, toml.encode now raises TypeError instead of AttributeError. [github.com](https://github.com/msgspec/msgspec/releases/tag/0.23.0)

## Check your code

These are the changes. To see which of them reach your code, [scan a public repository](https://since.dev/scan.md), or have your coding agent call `check_code` with your manifest or lockfile over [MCP](https://since.dev/docs.md#mcp). [The API](https://since.dev/docs.md#api) reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

## Put your code on continuous maintenance.

Scan a public repository now, or give your agent one line.

[Scan a repository](https://since.dev/scan.md). Any public GitHub repository. No sign-in.

### Tell your agent what changed since it was trained.

`claude mcp add --transport http since https://api.since.dev/mcp`

[Get an API key](https://app.since.dev/login?mode=signup)

Codex, Cursor and any MCP client use https://api.since.dev/mcp.

---

Every page on this site as Markdown: https://since.dev/sitemap.md. For agents: https://since.dev/llms.txt.
