Inline-snapshot

Latest version: v0.21.2

Safety actively analyzes 723144 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 5 of 10

0.15.1

Fixed

- solved a bug caused by a variable inside a snapshot (148)

<a id='changelog-0.15.0'></a>

0.15.0

Added

- snapshots [inside snapshots](https://15r10nk.github.io/inline-snapshot/latest/eq_snapshot/#inner-snapshots) are now supported.

python
assert get_schema() == snapshot(
[
{
"name": "var_1",
"type": snapshot("int") if version < 2 else snapshot("string"),
}
]
)


- [runtime values](https://15r10nk.github.io/inline-snapshot/latest/eq_snapshot/#is) can now be part of snapshots.

python
from inline_snapshot import snapshot, Is

current_version = "1.5"
assert request() == snapshot(
{"data": "page data", "version": Is(current_version)}
)


- [f-strings](https://15r10nk.github.io/inline-snapshot/latest/eq_snapshot/#f-strings) can now also be used within snapshots, but are currently not *fixed* by inline-snapshot.

Changed

- *dirty-equals* expressions are now treated like *runtime values* or *snapshots* within snapshots and are not modified by inline-snapshot.

Fixed

- inline-snapshot checks now if the given command line flags (`--inline-snapshot=...`) are valid

- `Example(...).run_pytest(raise=snapshot(...))` uses now the flags from the current run and not the flags from the Example.

<a id='changelog-0.14.2'></a>

0.14.2

Fixed

- do not crash when handling raw f-strings (`rf""`,`RF""`,...) (143)

<a id='changelog-0.14.1'></a>

0.14.1

Fixed

- Don't crash for snapshots like `snapshot(f"")` (139)
It first appeared with pytest-8.3.4, but already existed before for cpython-3.11.
f-strings in snapshots are currently not official supported, but they should not lead to crashes.

- skip formatting if black returns an error (138)

<a id='changelog-0.14.0'></a>

0.14.0

Removed

- removed the `"Programming Language :: Python :: Implementation :: PyPy"` classifier which was incorrect, because inline-snapshot can not fix snapshots on pypy.
inline-snapshot now enforces `--inline-snapshot=disable` when used with an implementation other than cpython, which allows it to be used in packages that want to support pypy.

Added

- command line shortcuts can be defined to simplify your workflows. `--review` and `--fix` are defined by default. See the [documentation](https://15r10nk.github.io/inline-snapshot/latest/configuration/) for details.

Changed

- `--inline-snapshot=create/fix/trim/update` will no longer show reports for other categories.
You can use `--inline-snapshot=create,report` if you want to use the old behaviour.

<a id='changelog-0.13.4'></a>

0.13.4

Changed

- use tomli instead of toml (130)

<a id='changelog-0.13.3'></a>

Page 5 of 10

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.