)]}'
{
  "commit": "1321aa43ce2bd5a4bef38c571f723882fe6b8520",
  "tree": "0d60cd56d273c75a499d61993dfa6e474ebd3c6c",
  "parents": [
    "5bec107f7329d8f72739cbbaaba7c92965f19ae4"
  ],
  "author": {
    "name": "Jia Chen",
    "email": "grievejia@meta.com",
    "time": "Fri Aug 28 10:34:32 2026 -0700"
  },
  "committer": {
    "name": "meta-codesync[bot]",
    "email": "215208954+meta-codesync[bot]@users.noreply.github.com",
    "time": "Fri Aug 28 10:34:32 2026 -0700"
  },
  "message": "Preserve parameter references in unopened files\n\nSummary:\nAn earlier change fixed incoming call hierarchy for files that the client did not open. It requested `Require::Everything` for every file that depends on the target module. This made the required ASTs available. However, the same helper also serves find references and find implementations. Those requests then performed full analysis on every dependent file.\n\nD117389890 (PR) limits that work. Incoming call hierarchy performs full analysis only on files that reference the target. Type hierarchy performs full analysis on its candidate files. Most find-reference requests and all find-implementation requests use only the retained index. This keeps incoming call hierarchy correct and makes common reference requests faster.\n\nD117389890 leaves one correctness problem. Parameter references do not use only the index. To find a keyword argument such as `greet(message\u003d\"Hello\")`, Pyrefly scans the caller AST. It also uses bindings to confirm that the keyword resolves to the selected parameter. An unopened file has neither at `Require::Indexing`. Find references therefore omits the keyword argument. Rename can change the parameter definition but leave `message\u003d` unchanged in the unopened caller.\n\nThis diff requests `Require::Everything` for all dependent files only when the selected definition is a parameter. Other definitions keep the index-only path from D117389890. This restores parameter references and rename without removing the main performance improvement.\n\nThis diff also removes a duplicate type-hierarchy request for `Require::Everything`. The caller already makes the same request before it reads the candidate files.\n\nThe tests cover parameter references and parameter rename in an unopened caller file. The call hierarchy test now has two unopened caller files. This verifies that one batch prepares every selected caller file.\n\nReviewed By: stroxler\n\nDifferential Revision: D117455220\n\nfbshipit-source-id: f8ba135ace020fbcd0e4ba9b0e7509773ba832be\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "798006df5984611d9f5fd84dc9b27ada2647ca9a",
      "old_mode": 33188,
      "old_path": "pyrefly/lib/lsp/non_wasm/server.rs",
      "new_id": "9b40b4155f88d96818acd63ea2d4b8a843f2ad36",
      "new_mode": 33188,
      "new_path": "pyrefly/lib/lsp/non_wasm/server.rs"
    },
    {
      "type": "modify",
      "old_id": "6981890e6cd73ca325b0d80a1bdd1877b85e3c9f",
      "old_mode": 33188,
      "old_path": "pyrefly/lib/state/lsp.rs",
      "new_id": "5fe7dabb60822cd8de7149a2a70120d6049d27f7",
      "new_mode": 33188,
      "new_path": "pyrefly/lib/state/lsp.rs"
    },
    {
      "type": "modify",
      "old_id": "21d426912d0e2b664ce1cdeab0b7aec7611a1b29",
      "old_mode": 33188,
      "old_path": "pyrefly/lib/test/lsp/lsp_interaction/call_hierarchy.rs",
      "new_id": "ca07b74611cde5b845d2a56f8871e37233a8b179",
      "new_mode": 33188,
      "new_path": "pyrefly/lib/test/lsp/lsp_interaction/call_hierarchy.rs"
    },
    {
      "type": "modify",
      "old_id": "702b6545194f12dfe667a82509f513ed5899ee16",
      "old_mode": 33188,
      "old_path": "pyrefly/lib/test/lsp/lsp_interaction/references.rs",
      "new_id": "0c48014f7d779393ecd51b28aa13ce5c56195011",
      "new_mode": 33188,
      "new_path": "pyrefly/lib/test/lsp/lsp_interaction/references.rs"
    },
    {
      "type": "modify",
      "old_id": "b7bfd564caf51fa88e008df40ff47cb9ba8f5df5",
      "old_mode": 33188,
      "old_path": "pyrefly/lib/test/lsp/lsp_interaction/rename.rs",
      "new_id": "e6385e96c2715a941ae6e31811df94edaeb3cea4",
      "new_mode": 33188,
      "new_path": "pyrefly/lib/test/lsp/lsp_interaction/rename.rs"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "f2a6fe87996d6da2cf2f06338f02d85d0f04a5af",
      "new_mode": 33188,
      "new_path": "pyrefly/lib/test/lsp/lsp_interaction/test_files/call_hierarchy_test/caller_extra.py"
    }
  ]
}
