Skip to content

.editorconfig in subdirectory is sometimes ignored #48187

@jrmajor

Description

@jrmajor

Reproduction steps

I've managed to write a failing test: 9faf1ed.

In that scenario, d/d.rs should have indent size of 1, as specified in d/.editorconfig. Currently it is 3, which seems to be inherited from the root .editorconfig.

Interestingly, b/b.rs correctly uses settings from b/.editorconfig. I'm not sure what makes it not work for d/d.rs.

Current vs. Expected behavior

Current behavior: .editorconfig in subdirectory is sometimes ignored.
Expected behavior: .editorconfig in subdirectory has higher precedence than the root .editorconfig.

Zed version and system specs

Zed: v0.221.5+stable.141.03bfbf242c57f7fdb45708d63d74182898edf2c5 (Zed)
OS: macOS 26.2
Memory: 16 GiB
Architecture: aarch64

Attach Zed log file

No response

Relevant Zed settings

No response

Relevant Keymap

No response

(for AI issues) Model provider details

No response

If you are using WSL on Windows, what flavor of Linux are you using?

None

Metadata

Metadata

Assignees

No one assigned

    Labels

    state:needs triagetriage is not complete: no `area:*` label, or no `priority:*`/`frequency:*` for Bugs/Crashes

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions