---
title: "python-dotenv Breaking Changes on PyPI | Since.dev"
description: "What each python-dotenv release removed, renamed or changed: 14 breaking changes in 3 versions on PyPI, each with its source."
canonical_url: https://since.dev/packages/pypi/python-dotenv
last_updated: 2026-03-01
---

# python-dotenv breaking changes

Every breaking API change we have recorded in python-dotenv on PyPI: 14 breaking changes in 3 versions. Below are its newest 3 versions, removals and renames first, each with its source.

Newest change March 1, 2026

## 1.2.2

9 breaking changes, first published March 1, 2026.

- **Behavior changed** `dotenv run`  

The dotenv run command now passes flags straight through to the specified command, so flag handling by dotenv run may differ from before. [github.com](https://github.com/theskumar/python-dotenv/releases/tag/v1.2.2)
- **Behavior changed** `dotenv.set_key`  

dotenv.set_key used to follow symlinks in some situations and no longer does. To restore the old behavior in all cases, pass follow_symlinks=True. [github.com](https://github.com/theskumar/python-dotenv/releases/tag/v1.2.2)
- **Behavior changed** `dotenv.unset_key`  

dotenv.unset_key used to follow symlinks in some situations and no longer does. To restore the old behavior in all cases, pass follow_symlinks=True. [github.com](https://github.com/theskumar/python-dotenv/releases/tag/v1.2.2)
- **Behavior changed** `set`  

The CLI set command used to follow symlinks in some situations and no longer does. [github.com](https://github.com/theskumar/python-dotenv/releases/tag/v1.2.2)
- **Behavior changed** `unset`  

The CLI unset command used to follow symlinks in some situations and no longer does. [github.com](https://github.com/theskumar/python-dotenv/releases/tag/v1.2.2)
- **Signature changed** `dotenv.cli.run`  

Was def run(ctx: click.Context, override: bool, commandline: List\[str\]) -> None; now def run(ctx: click.Context, override: bool, commandline: tuple\[str, ...\]) -> None. [pypi.org](https://pypi.org/project/python-dotenv/1.2.2/)
- **Signature changed** `dotenv.main.rewrite`  

Was def rewrite(path: StrPath, encoding: Optional\[str\]) -> Iterator\[Tuple\[IO\[str\], IO\[str\]\]\]; now def rewrite(path: StrPath, encoding: Optional\[str\], follow_symlinks: bool = False) -> Iterator\[Tuple\[IO\[str\], IO\[str\]\]\]. [pypi.org](https://pypi.org/project/python-dotenv/1.2.2/)
- **Signature changed** `dotenv.set_key`  

Was def set_key(dotenv_path: StrPath, key_to_set: str, value_to_set: str, quote_mode: str = 'always', export: bool = False, encoding: Optional\[str\] = 'utf-8') -> Tuple\[Optional\[bool\], str, str\]; now def set_key(dotenv_path: StrPath... [pypi.org](https://pypi.org/project/python-dotenv/1.2.2/)
- **Signature changed** `dotenv.unset_key`  

Was def unset_key(dotenv_path: StrPath, key_to_unset: str, quote_mode: str = 'always', encoding: Optional\[str\] = 'utf-8') -> Tuple\[Optional\[bool\], str\]; now def unset_key(dotenv_path: StrPath, key_to_unset: str, quote_mode: str = 'always'... [pypi.org](https://pypi.org/project/python-dotenv/1.2.2/)

## 1.2.0

2 breaking changes, first published October 26, 2025.

- **Removed** `dotenv.cli.list`  

dotenv.cli.list was removed in python-dotenv 1.2.0 [pypi.org](https://pypi.org/project/python-dotenv/1.2.0/)
- **Renamed** `dotenv.cli.set`  

Use dotenv.cli.set_value instead. [pypi.org](https://pypi.org/project/python-dotenv/1.2.0/)

## 1.1.0

3 breaking changes, first published March 25, 2025.

- **Removed**  

Python 3.8 is no longer supported in this release, so code running on Python 3.8 should move to a newer Python version. [github.com](https://github.com/theskumar/python-dotenv/releases/tag/v1.1.0)
- **Signature changed** `dotenv.cli.enumerate_env`  

Was def enumerate_env(); now def enumerate_env() -> Optional\[str\]. [pypi.org](https://pypi.org/project/python-dotenv/1.1.0/)
- **Signature changed** `dotenv.cli.run_command`  

Was def run_command(command: List\[str\], env: Dict\[str, str\]) -> int; now def run_command(command: List\[str\], env: Dict\[str, str\]) -> None. [pypi.org](https://pypi.org/project/python-dotenv/1.1.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, not only the newest. On Team and up, a fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

## Put your code on continuous management.

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

### See how out of date your code is.

[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`

---

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