Skip to content

Fix file error test with long temporary paths - #1992

Open
booxter wants to merge 1 commit into
fastapi:masterfrom
booxter:unit-too-long-path-rich
Open

booxter wants to merge 1 commit into
fastapi:masterfrom
booxter:unit-too-long-path-rich

Conversation

@booxter

@booxter booxter commented Oct 31, 2026

Copy link
Copy Markdown

Pull Request

Discussion: #1984

Description

We saw this fail in Nix builds: a long temporary directory path may
make Rich wrap cannot-open.txt across lines. The substring assertion
then fails despite a correct error message.

Use a relative filename so the assertion does not depend on the
temporary directory path or display width.

AI Disclaimer

AI transcript

Checklist

  • This PR links to a GitHub Discussion for the proposed code change.
  • I added tests for the change.
  • The new or updated tests fail on the main branch and pass on this PR.
  • Coverage stays at 100%.
  • The documentation explains the change if needed.

We saw this fail in Nix builds: a long temporary directory path may
make Rich wrap cannot-open.txt across lines. The substring assertion
then fails despite a correct error message.

Use a relative filename so the assertion does not depend on the
temporary directory path or display width.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant