---
title: "unidiff 1.0.0 Breaking Changes on PyPI | Since.dev"
description: "What each unidiff release removed, renamed or changed: 22 breaking changes in 3 versions on PyPI, each with its source."
canonical_url: https://since.dev/packages/pypi/unidiff
last_updated: 2026-12-04
---

# unidiff breaking changes

unidiff 1.0.0 (July 25, 2026) is its newest release with breaking changes, 15 of them. The first: unidiff 1.0.0 requires Python 3.9 or later. Every breaking API change we have recorded in unidiff on PyPI: 22 breaking changes in 3 versions. Below, its 3 versions with breaking changes, newest first, removals and renames first, each with its source.

Updated December 4, 2026

Latest version `1.0.1`, released September 15, 2026. [Source repository](https://github.com/matiasb/python-unidiff)

Its 1.0.0 release requires [Python 3.9](https://since.dev/calendar/python/3.9.md) or later. [Python end of life dates](https://since.dev/calendar/python.md).

- From [0.7.0](#v-0-7-0) to [1.0.0](#v-1-0-0): 15 breaking changes in 1 version.
- From [0.6.0](#v-0-6-0) to [1.0.0](#v-1-0-0): 20 breaking changes in 2 versions.

## unidiff 1.0.0 breaking changes

unidiff 1.0.0, released July 25, 2026: 15 breaking changes.

- **Removed**  

Python 2 is no longer supported; the minimum supported Python is now 3.9. Code running on Python 2 must stay on 0.7.5 or move to Python 3.9+. [github.com](https://github.com/matiasb/python-unidiff/releases/tag/v1.0.0)
- **Removed** `unidiff.patch.basestring`  

unidiff.patch.basestring was removed in unidiff 1.0.0 [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Removed** `unidiff.patch.implements_to_string`  

unidiff.patch.implements_to_string was removed in unidiff 1.0.0 [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Removed** `unidiff.patch.make_str`  

unidiff.patch.make_str was removed in unidiff 1.0.0 [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Removed** `unidiff.patch.open_file`  

unidiff.patch.open_file was removed in unidiff 1.0.0 [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Removed** `unidiff.patch.PY2`  

unidiff.patch.PY2 was removed in unidiff 1.0.0 [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Removed** `unidiff.patch.unicode`  

unidiff.patch.unicode was removed in unidiff 1.0.0 [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Behavior changed** `PatchedFile.path`  

PatchedFile.path also strips git mnemonic prefixes like c/, i/, o/, w/, 1/ and 2/, so git diff --cached paths resolve to the plain filename. Standard a/ and b/ diffs are unaffected. [github.com](https://github.com/matiasb/python-unidiff/releases/tag/v1.0.0)
- **Signature changed** `unidiff.Hunk`  

Was class Hunk(list); now class Hunk(list\[Line\]). [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Signature changed** `unidiff.patch.PatchInfo`  

Was class PatchInfo(list); now class PatchInfo(list\[str\]). [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Signature changed** `unidiff.PatchedFile`  

Was class PatchedFile(list); now class PatchedFile(list\[Hunk\]). [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Signature changed** `unidiff.PatchedFile.__init__`  

Was def \_\_init\_\_(self, patch_info=None, source='', target='', source_timestamp=None, target_timestamp=None, is_binary_file=False); now def \_\_init\_\_(self, patch_info: Optional\[PatchInfo\] = None, source: str = '', target: str = ''... [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Signature changed** `unidiff.PatchSet`  

Was class PatchSet(list); now class PatchSet(list\[PatchedFile\]). [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Signature changed** `unidiff.PatchSet.from_filename`  

Was @classmethod def from_filename(cls, filename, encoding=DEFAULT_ENCODING, errors=None, newline=None); now @classmethod def from_filename(cls, filename: str, encoding: str = DEFAULT_ENCODING, errors: Optional\[str\] = None, newline... [pypi.org](https://pypi.org/project/unidiff/1.0.0/)
- **Signature changed** `unidiff.PatchSet.from_string`  

Was @classmethod def from_string(cls, data, encoding=None, errors='strict'); now @classmethod def from_string(cls, data: Union\[str, bytes\], encoding: Optional\[str\] = None, errors: str = 'strict', metadata_only: bool = False) -> PatchSet. [pypi.org](https://pypi.org/project/unidiff/1.0.0/)

## unidiff 0.7.0 breaking changes

unidiff 0.7.0, released August 15, 2021: 5 breaking changes.

- **Removed** `unidiff.constants.RE_RENAME_SOURCE_FILENAME`  

unidiff.constants.RE_RENAME_SOURCE_FILENAME was removed in unidiff 0.7.0 [pypi.org](https://pypi.org/project/unidiff/0.7.0/)
- **Removed** `unidiff.constants.RE_RENAME_TARGET_FILENAME`  

unidiff.constants.RE_RENAME_TARGET_FILENAME was removed in unidiff 0.7.0 [pypi.org](https://pypi.org/project/unidiff/0.7.0/)
- **Removed** `unidiff.patch.RE_RENAME_SOURCE_FILENAME`  

unidiff.patch.RE_RENAME_SOURCE_FILENAME was removed in unidiff 0.7.0 [pypi.org](https://pypi.org/project/unidiff/0.7.0/)
- **Removed** `unidiff.patch.RE_RENAME_TARGET_FILENAME`  

unidiff.patch.RE_RENAME_TARGET_FILENAME was removed in unidiff 0.7.0 [pypi.org](https://pypi.org/project/unidiff/0.7.0/)
- **Behavior changed** `PatchedFile.path`  

For renamed files, PatchedFile.path now returns the target filename instead of the source name. Code relying on the old value must be updated. [github.com](https://github.com/matiasb/python-unidiff/releases/tag/v0.7.0)

## unidiff 0.6.0 breaking changes

unidiff 0.6.0, released May 7, 2020: 2 breaking changes.

- **Signature changed** `unidiff.PatchedFile.__init__`  

Was def \_\_init\_\_(self, patch_info=None, source='', target='', source_timestamp=None, target_timestamp=None); now def \_\_init\_\_(self, patch_info=None, source='', target='', source_timestamp=None, target_timestamp=None, is_binary_file=False... [pypi.org](https://pypi.org/project/unidiff/0.6.0/)
- **Signature changed** `unidiff.PatchSet.__init__`  

Was def \_\_init\_\_(self, f, encoding=None); now def \_\_init\_\_(self, f, encoding=None, metadata_only=False). [pypi.org](https://pypi.org/project/unidiff/0.6.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.
