Skip to content

[pyrefly] Keep auto-import for fuzzy local matches - #4394

Open
lyydsheep wants to merge 1 commit into
facebook:mainfrom
lyydsheep:codex/issue-4288-fuzzy-autoimport
Open

[pyrefly] Keep auto-import for fuzzy local matches#4394
lyydsheep wants to merge 1 commit into
facebook:mainfrom
lyydsheep:codex/issue-4288-fuzzy-autoimport

Conversation

@lyydsheep

Copy link
Copy Markdown

Fixes #4288

Allow auto-import completion when local results only match the typed name fuzzily, while preserving the existing gate for prefix-matching local results.

Validation:

  • cargo test -p pyrefly autoimport_completion_not_blocked_by_fuzzy_local -- --nocapture
  • cargo test -p pyrefly test::lsp::completion -- --nocapture (110 passed)
  • python3 test.py --no-test --no-tensor-shapes --no-conformance --no-jsonschema

The local .scratch planning files are intentionally not part of this PR.

Run auto-import completion when local symbols only match fuzzily, so external symbols remain discoverable without changing exact local completion behavior.
@meta-cla meta-cla Bot added the cla signed label Aug 1, 2026
@github-actions github-actions Bot added the size/s label Aug 1, 2026
@meta-codesync

meta-codesync Bot commented Aug 1, 2026

Copy link
Copy Markdown
Contributor

This pull request has been imported. If you are a Meta employee, you can view this in D114460500. (Because this pull request was imported automatically, there will not be any future comments.)

@lyydsheep
lyydsheep marked this pull request as ready for review August 2, 2026 04:14
@github-actions
github-actions Bot requested a review from NathanTempest August 2, 2026 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

pyrefly LSP: similar symbol in opened file prevents auto-import

2 participants