From d31c9ecbe93a5686e5a4d4ce29c455f36d0b6c8e Mon Sep 17 00:00:00 2001 From: Max Isbey <224885523+maxisbey@users.noreply.github.com> Date: Fri, 2 Oct 2026 20:21:32 +0000 Subject: [PATCH] Keep inline-snapshot disabled when pytest runs in a terminal `default-flags = ["disable"]` only covers runs whose stdout is not a terminal. In a terminal outside CI the plugin fell back to its own `default-flags-tui` default (`create`, `review`), stayed active, and the locked version raised `AttributeError: ... has no attribute '_meta'` on every `snapshot(...)` literal that spells the field as `_meta=`. Set `default-flags-tui` to `disable` as well, so a plain `pytest` run behaves the same in a terminal, in a pipe and in CI. Snapshots are still updated with an explicit `--inline-snapshot=create` or `fix`. Fixes #3544 --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 0cd0fb3bf0..8148505417 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -333,4 +333,5 @@ source = [ [tool.inline-snapshot] default-flags = ["disable"] +default-flags-tui = ["disable"] format-command = "ruff format --stdin-filename {filename}"