v2.7.5 (#589)
Co-authored-by: Bastien <bastien.baret@gmail.com> Co-authored-by: Clément Sirieix <clement.sirieix@mistral.ai> Co-authored-by: Julien Legrand <72564015+JulienLGRD@users.noreply.github.com> Co-authored-by: Kim-Adeline Miguel <51720070+kimadeline@users.noreply.github.com> Co-authored-by: Mathias Gesbert <mathias.gesbert@mistral.ai> Co-authored-by: Pierre Rossinès <pierre.rossines@mistral.ai> Co-authored-by: Quentin <quentin.torroba@mistral.ai> Co-authored-by: Vincent G <10739306+VinceOPS@users.noreply.github.com> Co-authored-by: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
parent
e9a9217cc8
commit
e1a25caa52
85 changed files with 2830 additions and 594 deletions
14
AGENTS.md
14
AGENTS.md
|
|
@ -134,6 +134,20 @@ guidelines:
|
|||
- uv run script.py to run a script within the uv environment
|
||||
- uv run pytest (or any other python tool) to run the tool within the uv environment
|
||||
|
||||
- title: "Safe File Reading"
|
||||
description: >
|
||||
When reading files from disk, prefer the helpers in `vibe.core.utils.io` over raw
|
||||
`Path.read_text()`, `Path.read_bytes().decode()`, or `open()` calls:
|
||||
- `read_safe(path)` — synchronous read with automatic encoding detection.
|
||||
- `read_safe_async(path)` — async equivalent (anyio-based).
|
||||
- `decode_safe(raw)` — decode an already-read `bytes` object.
|
||||
These functions try UTF-8 first, then BOM detection, the locale encoding, and
|
||||
`charset_normalizer` (lazily, only when cheaper candidates fail). They return a
|
||||
`ReadSafeResult(text, encoding)` so callers always get valid `str` output without
|
||||
having to handle encoding errors manually.
|
||||
Use `raise_on_error=True` only when the caller must distinguish corrupt files from
|
||||
valid ones; the default (`False`) replaces undecodable bytes with U+FFFD.
|
||||
|
||||
- title: "Imports in Cursor (no Pylance)"
|
||||
description: >
|
||||
Cursor's built-in Pyright does not offer the "Add import" quick fix (Ctrl+.). To add a missing import:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue