diffctx 1.18.1__tar.gz → 1.18.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (175) hide show
  1. {diffctx-1.18.1 → diffctx-1.18.3}/CHANGELOG.md +190 -1
  2. {diffctx-1.18.1 → diffctx-1.18.3}/Cargo.lock +12 -13
  3. {diffctx-1.18.1 → diffctx-1.18.3}/PKG-INFO +7 -4
  4. {diffctx-1.18.1 → diffctx-1.18.3}/README.md +6 -3
  5. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/Cargo.toml +2 -2
  6. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/README.md +6 -3
  7. diffctx-1.18.3/crates/diffctx-native/src/bindings.rs +1167 -0
  8. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/candidate_files.rs +45 -1
  9. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/git.rs +1 -1
  10. diffctx-1.18.3/crates/diffctx-native/src/container.rs +53 -0
  11. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/discovery.rs +37 -9
  12. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/base.rs +1 -6
  13. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/history/cochange.rs +20 -19
  14. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/c_family.rs +2 -2
  15. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/javascript.rs +4 -4
  16. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/python.rs +69 -10
  17. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/tags.rs +21 -1
  18. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/fragmentation.rs +38 -6
  19. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/git.rs +584 -167
  20. diffctx-1.18.3/crates/diffctx-native/src/hook.rs +1768 -0
  21. diffctx-1.18.3/crates/diffctx-native/src/impact.rs +1848 -0
  22. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/in_memory_harness.rs +4 -1
  23. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/lib.rs +3 -0
  24. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/locate.rs +87 -12
  25. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/main.rs +34 -8
  26. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/parsers/mod.rs +1 -1
  27. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/parsers/tree_sitter_strategy.rs +67 -1
  28. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/pipeline.rs +341 -38
  29. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/postpass.rs +23 -4
  30. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/pybridge.rs +76 -4
  31. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/render.rs +5 -0
  32. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/resource.rs +223 -22
  33. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/run_provenance.rs +8 -3
  34. diffctx-1.18.3/crates/diffctx-native/src/source.rs +150 -0
  35. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/token_corpus.rs +4 -1
  36. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/types.rs +20 -0
  37. {diffctx-1.18.1 → diffctx-1.18.3}/pyproject.toml +2 -2
  38. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/_app.py +2 -1
  39. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/_diffctx.pyi +13 -1
  40. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/_native/pipeline.py +2 -0
  41. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/cli.py +69 -27
  42. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/mcp/__main__.py +1 -1
  43. diffctx-1.18.3/src/diffctx/mcp/launch.py +32 -0
  44. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/mcp/server.py +22 -21
  45. diffctx-1.18.3/src/diffctx/version.py +1 -0
  46. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/writer.py +6 -2
  47. diffctx-1.18.1/crates/diffctx-native/src/hook.rs +0 -803
  48. diffctx-1.18.1/crates/diffctx-native/src/impact.rs +0 -937
  49. diffctx-1.18.1/src/diffctx/version.py +0 -1
  50. {diffctx-1.18.1 → diffctx-1.18.3}/Cargo.toml +0 -0
  51. {diffctx-1.18.1 → diffctx-1.18.3}/LICENSE +0 -0
  52. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/analytics.rs +0 -0
  53. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/change_class.rs +0 -0
  54. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/analytics.rs +0 -0
  55. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/bm25.rs +0 -0
  56. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/budget.rs +0 -0
  57. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/category_weights.rs +0 -0
  58. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/edge_weights.rs +0 -0
  59. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/env_overrides.rs +0 -0
  60. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/extensions.rs +0 -0
  61. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/filtering.rs +0 -0
  62. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/fragmentation.rs +0 -0
  63. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/graph_filtering.rs +0 -0
  64. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/importance.rs +0 -0
  65. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/limits.rs +0 -0
  66. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/mod.rs +0 -0
  67. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/mode.rs +0 -0
  68. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/needs.rs +0 -0
  69. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/parsers.rs +0 -0
  70. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/render.rs +0 -0
  71. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/scoring.rs +0 -0
  72. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/selection.rs +0 -0
  73. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/tokenization.rs +0 -0
  74. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/config/weights.rs +0 -0
  75. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/core.rs +0 -0
  76. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/config_edges/build_system.rs +0 -0
  77. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/config_edges/cicd.rs +0 -0
  78. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/config_edges/docker.rs +0 -0
  79. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/config_edges/generic.rs +0 -0
  80. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/config_edges/helm.rs +0 -0
  81. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/config_edges/kubernetes.rs +0 -0
  82. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/config_edges/mod.rs +0 -0
  83. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/document/mod.rs +0 -0
  84. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/history/mod.rs +0 -0
  85. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/mod.rs +0 -0
  86. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/ansible.rs +0 -0
  87. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/bazel.rs +0 -0
  88. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/cargo_edges.rs +0 -0
  89. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/clojure.rs +0 -0
  90. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/css.rs +0 -0
  91. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/dart.rs +0 -0
  92. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/dbt.rs +0 -0
  93. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/dotnet.rs +0 -0
  94. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/elixir.rs +0 -0
  95. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/erlang.rs +0 -0
  96. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/go.rs +0 -0
  97. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/graphql.rs +0 -0
  98. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/haskell.rs +0 -0
  99. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/julia.rs +0 -0
  100. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/jvm.rs +0 -0
  101. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/latex.rs +0 -0
  102. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/lua.rs +0 -0
  103. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/mod.rs +0 -0
  104. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/nim.rs +0 -0
  105. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/nix.rs +0 -0
  106. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/ocaml.rs +0 -0
  107. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/openapi.rs +0 -0
  108. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/perl.rs +0 -0
  109. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/php.rs +0 -0
  110. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/prisma.rs +0 -0
  111. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/protobuf.rs +0 -0
  112. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/r_lang.rs +0 -0
  113. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/ruby.rs +0 -0
  114. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/rust_lang.rs +0 -0
  115. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/shell.rs +0 -0
  116. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/sql.rs +0 -0
  117. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/swift.rs +0 -0
  118. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/terraform.rs +0 -0
  119. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/semantic/zig.rs +0 -0
  120. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/similarity/lexical.rs +0 -0
  121. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/similarity/mod.rs +0 -0
  122. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/structural/containment.rs +0 -0
  123. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/structural/mod.rs +0 -0
  124. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/structural/sibling.rs +0 -0
  125. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/edges/structural/testing.rs +0 -0
  126. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/effective_config.rs +0 -0
  127. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/excerpt.rs +0 -0
  128. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/facts/mod.rs +0 -0
  129. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/facts/scala.rs +0 -0
  130. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/filtering.rs +0 -0
  131. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/graph.rs +0 -0
  132. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/graph_export.rs +0 -0
  133. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/interval.rs +0 -0
  134. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/languages.rs +0 -0
  135. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/mode.rs +0 -0
  136. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/parsers/config_parser.rs +0 -0
  137. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/parsers/generic.rs +0 -0
  138. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/parsers/markdown.rs +0 -0
  139. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/paths.rs +0 -0
  140. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/peak_rss.rs +0 -0
  141. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/ppr.rs +0 -0
  142. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/project_graph.rs +0 -0
  143. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/provenance.rs +0 -0
  144. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/sanitize.rs +0 -0
  145. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/scoring.rs +0 -0
  146. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/select.rs +0 -0
  147. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/signatures.rs +0 -0
  148. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/stopwords/code.txt +0 -0
  149. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/stopwords/docs.txt +0 -0
  150. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/stopwords.rs +0 -0
  151. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/test_rng.rs +0 -0
  152. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/testfiles.rs +0 -0
  153. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/tokenizer.rs +0 -0
  154. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/utility/boltzmann.rs +0 -0
  155. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/utility/importance.rs +0 -0
  156. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/utility/mod.rs +0 -0
  157. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/utility/needs.rs +0 -0
  158. {diffctx-1.18.1 → diffctx-1.18.3}/crates/diffctx-native/src/utility/objective.rs +0 -0
  159. {diffctx-1.18.1 → diffctx-1.18.3}/rust-toolchain.toml +0 -0
  160. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/__init__.py +0 -0
  161. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/__main__.py +0 -0
  162. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/_native/__init__.py +0 -0
  163. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/_native/graph_analytics.py +0 -0
  164. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/_native/graph_export.py +0 -0
  165. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/_native/project_graph.py +0 -0
  166. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/clipboard.py +0 -0
  167. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/ignore.py +0 -0
  168. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/logger.py +0 -0
  169. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/mcp/__init__.py +0 -0
  170. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/mcp/fetch.py +0 -0
  171. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/mcp/legacy.py +0 -0
  172. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/mcp/security.py +0 -0
  173. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/py.typed +0 -0
  174. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/tokens.py +0 -0
  175. {diffctx-1.18.1 → diffctx-1.18.3}/src/diffctx/tree.py +0 -0
@@ -7,6 +7,193 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [1.18.3] - 2026-10-04
11
+
12
+ ### Added
13
+
14
+ - `--symbol NAME` (or `PATH:NAME`) and the MCP `symbol` parameter: impact
15
+ without a diff — where a name is defined, who calls it, and the tests that
16
+ reach each caller, including calls from its own file. The questions an agent
17
+ asks before it has changed anything used to have no answer but `grep` (#336).
18
+ - `--diff staged` (also `--diff=--cached`) and MCP `diff_ref="staged"`: the
19
+ index captured once as a tree is the whole current side of the run — the
20
+ changed files, the callers, their imports, the test files, the stale
21
+ references — whatever the disk says. An unborn branch is diffed against the
22
+ empty tree of the repository's object format, an unmerged index is an error,
23
+ an empty index diff reads "No changes to analyse.", and impact names the
24
+ snapshot (`index_tree`, "staged changes (index tree …)") (#354).
25
+ - `diffctx-mcp --version` / `-v`, and `diffctx mcp --version` (#334).
26
+ - Plugin hook: a grep/rg/ag/`git grep` or Grep-tool search for a name the
27
+ pending change edits is answered once with that name's callers and tests,
28
+ or one line saying nothing outside calls it (#337). Every hook run, and a
29
+ launch that never reached diffctx, leaves one line in
30
+ `<cache>/diffctx/hook.log`, so a silent hook can be told from a failed one (#338).
31
+
32
+ ### Changed
33
+
34
+ - Impact resolves callers through import bindings in Python and JS/TS
35
+ (#343, #344, #349, #353). A reference is a caller when the import it goes
36
+ through lands on the changed file — relative and absolute Python imports,
37
+ `import … as`, `from … import … as`, package re-exports, ES imports,
38
+ `require`, `export … from`, and `tsconfig` `paths` read as data; a method
39
+ call when its receiver is `self`/`this` in that class or a subclass, the
40
+ class itself, or a variable constructed or annotated as it. Same-named
41
+ modules (`shop/pricing.py` vs `legacy/pricing.py`, two `App.tsx`), duplicate
42
+ source roots and unrelated receivers (`update.message`) no longer pass, and
43
+ an alias call (`took()` for `elapsed`) does — in the graph too, so pack and
44
+ locate see it. A reference whose import or receiver cannot be resolved is a
45
+ possible caller (`evidence: "candidate"`, `reason`), listed after the
46
+ resolved ones and counted in the header; other languages keep the name
47
+ model and say so. A call through a parameter shadowing the import is not a
48
+ caller; passing a function on is a `reference`; the chunks of one function,
49
+ and a file's module-level code, are one caller with its `sites`.
50
+ - A name defined in many files of a language without a binding model, and a
51
+ Rust method implementing a trait (reachable through `dyn Trait`), say
52
+ `callers not resolved` instead of being dropped; a qualified `--symbol
53
+ path:name` resolves whatever the global definition count. An empty impact
54
+ reads "No resolved static callers outside the diff in the analysed scope."
55
+ - Plugin hook (#342): an answer is keyed by its result identity — the
56
+ analyser version, the checkout, the base commit and every changed path's
57
+ final blob id — so every spelling of one snapshot shares it and any new
58
+ byte, a caller's edit included, is answered at once; there is no time
59
+ window. An answer is recorded as delivered only when it is returned; a run
60
+ that timed out is retried, at most twice per identity, and never counts as
61
+ a review; a partial answer is retried within the same bound. A commit gets
62
+ a reminder only when its target is exactly what was shown. A view the agent
63
+ does not read whole is no inspection: `git diff | grep`, `|&`, `--stat`,
64
+ `--name-only`, `--quiet` (but `--stat --patch`, `--exit-code` and `||` are);
65
+ `git add … && git commit`, `-a` and pathspec commits are labelled as a
66
+ preview, and the commit that lands is reviewed after it when it differs. A
67
+ git command hidden in `$(…)`, backticks or `sh -c` is logged as
68
+ `unsupported-syntax`. The automatic answer is fitted to 600 tokens with
69
+ possible callers folded into a count; a search for an edited name never
70
+ answers "nothing calls it" for a symbol whose callers were not resolved.
71
+ - Test labels say what static analysis shows: "reachable from tests: X" (via
72
+ a caller, within two call hops), "no static test link found", "no static
73
+ test link (its file has tests)" — never execution coverage, which a closing
74
+ line states.
75
+
76
+ - MCP: `diffctx_context` defaults to `mode="impact"`. Its description and the
77
+ server instructions promise what a change reaches outside its diff; a call
78
+ that omitted `mode` got a locate ranking without reverse discovery, missed
79
+ the callers it asked for and read `tests: 0` (#335). `mode="locate"` and the
80
+ `fragment_ids` flow are unchanged.
81
+ - Impact names deleted files and counts them, and lists the lines outside the
82
+ change that still name a deleted or renamed path — a Dockerfile `COPY`, a
83
+ workflow step, an import (#313, #347). The markdown says "uncommitted
84
+ changes" or "staged changes" instead of "HEAD".
85
+ - Impact's test labels: a caller is "tested by X" when a test reaches it
86
+ directly or through up to two callers ("via f"); UNTESTED only when a test
87
+ reaches its file but not it; otherwise "no test found". A test edge to the
88
+ file no longer counts as the caller's guard (#348, half of #312).
89
+ - A commit of a change whose impact was already shown gets one line naming
90
+ it instead of silence; `--amend` reviews the index against `HEAD~1` (#346).
91
+ - Coverage: `partial` only when a limit touched what the answer is about — a
92
+ run-wide stop, or a per-file limit on a changed file, a selected file or a
93
+ code file importing a changed module. `limited_files` names them; graph caps
94
+ every repository hits go to `capped` and print nothing (#306).
95
+ - Python: an import confirms the calls of the whole file, not of the fragment
96
+ that holds it, so a changed function's callee and callers clear the naming
97
+ floor; discovery follows the changed files' own imports and no longer pulls
98
+ in a whole package for an ancestor import (#317, #339, #341).
99
+ - Locate's serialized answer fits `--budget` (the overflow pointer list, which
100
+ the MCP surface strips, is not charged) (#300).
101
+
102
+ ### Fixed
103
+
104
+ - An explicit range is analysed from its own head: the discovery universe is
105
+ the head tree's file list (`ls-tree`), and discovery, the edge builders and
106
+ the fragment reader read that tree, never the checked-out files. A file
107
+ added after the range's head no longer becomes context, one deleted only on
108
+ disk is still there, and a read the snapshot cannot serve is not filled from
109
+ the disk. Impact computes the base, the commit bounds and the
110
+ stale-reference search from the resolved range, so a duration window such
111
+ as `24h` no longer asks git about a revision named `24h` (#354).
112
+ - A stalled git can no longer hang a run (#356). Every git child gets what is
113
+ left of the run's one deadline rather than a fresh full `--timeout`; its
114
+ pipes are read on their own threads, so neither the child nor a descendant
115
+ holding a pipe can hold the caller; on Unix the child's whole process group
116
+ is killed. A `cat-file --batch` stream that timed out or lost framing is
117
+ discarded, never reused, and the file is re-read through `git show`. A read
118
+ the deadline interrupted is reported (`deadline`) instead of being replaced
119
+ by the disk's copy. MCP cancellation and the MCP deadline now stop the native
120
+ run and kill its git children (`cancelled`); the corpus harness ends a run
121
+ whose case exceeds its limit, naming the case.
122
+ - `diffctx-mcp` from a base install (no `[mcp]` extra) died on
123
+ `import anyio` with a traceback; it now answers `--help`/`--version` and
124
+ otherwise names the extra to install, exit 3. The release smoke installs the
125
+ base package into a fresh venv and checks both (#333).
126
+ - The plugin's session start removes the binaries 1.18.1 and earlier
127
+ downloaded into `$CLAUDE_PLUGIN_DATA/bin` — 61 MB per version that no update
128
+ ever deleted.
129
+ - A release whose GitHub tag is pruned after CD no longer loses its npm
130
+ publish: `publish-extras` checks out the release commit, re-creates a
131
+ missing tag, publishes a release that turned into a draft, and downloads
132
+ assets by id (#332).
133
+ - Impact: a name inside a string literal or comment is not a call, and a
134
+ dotted call to a module-level definition counts only through its own module
135
+ — `re.search` is not a call to a changed `search` (#345); a caller importing
136
+ a class through its package (`from models import Steps`) is found (#351).
137
+ - Reverse discovery reads Go/Kotlin/Swift `func`/`fun` and Java/C# methods,
138
+ ignores indented locals and counts each document once per name (#319).
139
+ - Co-change history is read before the range's head, under the git timeout,
140
+ with non-ASCII paths intact: a historical range no longer depends on what is
141
+ checked out (#340).
142
+ - Locate lists a file as unparsed only when this build has a grammar for it;
143
+ SQL, Kotlin or `.txt` changes no longer read `confidence 0.0` (#330).
144
+ `.php3`–`.php7` and `.phps` reach the PHP grammar.
145
+ - The plugin hook dropped shell redirections into the git arguments, so
146
+ `git commit -m x 2>&1 | tail` reviewed the whole dirty tree.
147
+ - The tags fallback no longer links code by syntax words (`self`, `None`,
148
+ `int`, `public`).
149
+ - The in-memory harness marks changed files that yield no fragment (#321).
150
+
151
+ ## [1.18.2] - 2026-10-01
152
+
153
+ ### Changed
154
+
155
+ - **The Claude plugin no longer downloads anything but its pinned package.**
156
+ The directory runs only code from the reviewed repository or a package
157
+ pinned to an exact version, and refused 1.18.1 for fetching the release
158
+ binary at session start. The git hooks now run `diffctx hook <event>` from
159
+ `uvx diffctx[mcp]==<version>` — the MCP server's own pinned launch, so the
160
+ environment its start cached is the one the hook finds, `--offline` on the
161
+ commit path. The session start only warms that cache in the background and
162
+ names the command; `diffctx-install.sh` and `plugin/checksums.json` are
163
+ gone. The PyPI package gains the `diffctx hook` subcommand the native
164
+ binary had. The skills' no-MCP fallback names the same exact version
165
+ instead of a `<version>` placeholder, and the release bumps it.
166
+
167
+ ### Fixed
168
+
169
+ - 1.18.1's impact listed every resource cap as a limit, so the fragment and
170
+ edge caps nearly every repository hits printed `(partial: …)` and made the
171
+ hook speak on every commit; only the deadline, a truncated reverse
172
+ discovery and a capped candidate universe can lose a caller, and only those
173
+ are listed (#306).
174
+ - A test file named for a schema (`test_context_schema.py`) is no longer
175
+ reported as a schema contract.
176
+ - Impact: a changed module-level `export const f = (…) => …` is a changed
177
+ symbol whose importers are its callers; it used to read "Nothing outside the
178
+ diff depends on this change" (#324).
179
+ - Impact: "Contracts changed" lists an exported symbol only when its
180
+ declaration moved; a body-only edit is what its callers already say (#325).
181
+ A decorated export (`@Component({…}) export class …`) is public, and its
182
+ decorator is not mistaken for the declaration.
183
+ - The hook's "already reviewed" markers are per session: a change one session
184
+ was shown used to be silence for every other session for a day. A manual
185
+ `--mode impact` run still silences the hook on the same content, for 15
186
+ minutes (#323).
187
+ - `diffctx hook` from the PyPI package writes its answer as UTF-8: Windows'
188
+ cp1252 stdout turned the answer's dashes into bytes Claude Code cannot
189
+ read, and a character cp1252 lacks made the hook silent.
190
+ - `uv.lock`: urllib3 2.8.0 (GHSA-gh4c-6fx4-qh6g, GHSA-vxq7-64xx-v4gw,
191
+ GHSA-8988-9cw3-xx77) and virtualenv 21.14.1 (GHSA-94p9-xgh2-xp45,
192
+ GHSA-9h9j-4vrj-gf7g), both development-only.
193
+ - The hook no longer guesses the repository behind `cd $VAR`, `cd ~/…` or
194
+ `git -C "$REPO"`: a directory only the shell can expand is skipped instead
195
+ of reviewing whatever repository the agent's cwd is.
196
+
10
197
  ## [1.18.1] - 2026-09-30
11
198
 
12
199
  ### Fixed
@@ -1716,7 +1903,9 @@ Earlier releases shipped as `treemapper`; see
1716
1903
  <https://github.com/nikolay-e/diffctx/releases> for the corresponding GitHub
1717
1904
  release notes (`1.0.0` through `1.6.1`).
1718
1905
 
1719
- [Unreleased]: https://github.com/nikolay-e/diffctx/compare/v1.18.1...HEAD
1906
+ [Unreleased]: https://github.com/nikolay-e/diffctx/compare/v1.18.3...HEAD
1907
+ [1.18.3]: https://github.com/nikolay-e/diffctx/compare/v1.18.2...v1.18.3
1908
+ [1.18.2]: https://github.com/nikolay-e/diffctx/compare/v1.18.1...v1.18.2
1720
1909
  [1.18.1]: https://github.com/nikolay-e/diffctx/compare/v1.18.0...v1.18.1
1721
1910
  [1.18.0]: https://github.com/nikolay-e/diffctx/compare/v1.17.0...v1.18.0
1722
1911
  [1.17.0]: https://github.com/nikolay-e/diffctx/compare/v1.16.0...v1.17.0
@@ -96,13 +96,13 @@ checksum = "c4512299f36f043ab09a583e57bceb5a5aab7a73db1805848e8fef3c9e8c78b3"
96
96
 
97
97
  [[package]]
98
98
  name = "bstr"
99
- version = "1.12.1"
99
+ version = "1.13.1"
100
100
  source = "registry+https://github.com/rust-lang/crates.io-index"
101
- checksum = "63044e1ae8e69f3b5a92c736ca6269b8d12fa7efe39bf34ddb06d102cf0e2cab"
101
+ checksum = "6bb31b46c14244e20ee9984b11bf5c992b91fb6939fea616e3512c8baecdbe5f"
102
102
  dependencies = [
103
103
  "memchr",
104
104
  "regex-automata",
105
- "serde",
105
+ "serde_core",
106
106
  ]
107
107
 
108
108
  [[package]]
@@ -194,7 +194,7 @@ checksum = "d0a5c400df2834b80a4c3327b3aad3a4c4cd4de0629063962b03235697506a28"
194
194
 
195
195
  [[package]]
196
196
  name = "diffctx"
197
- version = "1.18.1"
197
+ version = "1.18.3"
198
198
  dependencies = [
199
199
  "aho-corasick",
200
200
  "anyhow",
@@ -303,9 +303,9 @@ checksum = "5692dd7b5a1978a5aeb0ce83b7655c58ca8efdcb79d21036ea249da95afec2c6"
303
303
 
304
304
  [[package]]
305
305
  name = "fancy-regex"
306
- version = "0.17.0"
306
+ version = "0.19.2"
307
307
  source = "registry+https://github.com/rust-lang/crates.io-index"
308
- checksum = "72cf461f865c862bb7dc573f643dd6a2b6842f7c30b07882b56bd148cc2761b8"
308
+ checksum = "d301f5bf187b3c295fce6468d3875037a0bccc5f6b151c63cac2f85babf21912"
309
309
  dependencies = [
310
310
  "bit-set",
311
311
  "regex-automata",
@@ -886,18 +886,18 @@ dependencies = [
886
886
 
887
887
  [[package]]
888
888
  name = "thiserror"
889
- version = "2.0.20"
889
+ version = "2.0.21"
890
890
  source = "registry+https://github.com/rust-lang/crates.io-index"
891
- checksum = "ec86235f5fcc2a73650310756d2ac5b138a5780bbbdfae3eeccec992c435ba4f"
891
+ checksum = "09e52cb86a36cede5cb101bf8908837b3e4c6e5e59fe7fd85c23fb56200d189e"
892
892
  dependencies = [
893
893
  "thiserror-impl",
894
894
  ]
895
895
 
896
896
  [[package]]
897
897
  name = "thiserror-impl"
898
- version = "2.0.20"
898
+ version = "2.0.21"
899
899
  source = "registry+https://github.com/rust-lang/crates.io-index"
900
- checksum = "bc04cd3e1236dd4a98afca4569f2deb3f120e5422a4023be2cb683f8486292af"
900
+ checksum = "fe5197923287db20a58125f0bc85c062f7f2c892de97b18c356f9efb14b28524"
901
901
  dependencies = [
902
902
  "proc-macro2",
903
903
  "quote",
@@ -915,15 +915,14 @@ dependencies = [
915
915
 
916
916
  [[package]]
917
917
  name = "tiktoken-rs"
918
- version = "0.12.0"
918
+ version = "0.12.1"
919
919
  source = "registry+https://github.com/rust-lang/crates.io-index"
920
- checksum = "027853bbf8c7763b77c5c595f1c271c7d536ced7d6f83452911b944621e57fc2"
920
+ checksum = "2aeff724640cfe13037336ddf35befdffd2909cbdb65cf041cc8a4cf8c584cfa"
921
921
  dependencies = [
922
922
  "anyhow",
923
923
  "base64",
924
924
  "bstr",
925
925
  "fancy-regex",
926
- "lazy_static",
927
926
  "regex",
928
927
  "rustc-hash",
929
928
  ]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: diffctx
3
- Version: 1.18.1
3
+ Version: 1.18.3
4
4
  Classifier: Development Status :: 5 - Production/Stable
5
5
  Classifier: Environment :: Console
6
6
  Classifier: Intended Audience :: Developers
@@ -265,9 +265,12 @@ With `pip install 'diffctx[mcp]'` already done, replace the
265
265
  `uvx --from 'diffctx[mcp]' diffctx-mcp` tail with plain `diffctx-mcp`.
266
266
 
267
267
  The server exposes one tool, `diffctx_context`, that assistants call when
268
- reviewing PRs, explaining changes, or investigating broken tests. It ranks the
269
- code that explains a diff, then reads only the fragments the assistant picked —
270
- two calls that pay for the selection instead of a whole pack. The wider
268
+ reviewing PRs, explaining changes, or investigating broken tests. By default it
269
+ answers what a change reaches outside its diff — callers, the tests that reach
270
+ them, changed contracts — in under 2k tokens; `symbol` asks the same of a name
271
+ with no change at all. `mode=locate` ranks the code that explains a diff and
272
+ `fragment_ids` then reads only the fragments the assistant picked — two calls
273
+ that pay for the selection instead of a whole pack. The wider
271
274
  `get_tree_map` and `get_file_context` tools are opt-in via
272
275
  `DIFFCTX_MCP_LEGACY_TOOLS=1`. Filesystem confinement via
273
276
  `DIFFCTX_ALLOWED_PATHS`: see [SECURITY.md](SECURITY.md).
@@ -206,9 +206,12 @@ With `pip install 'diffctx[mcp]'` already done, replace the
206
206
  `uvx --from 'diffctx[mcp]' diffctx-mcp` tail with plain `diffctx-mcp`.
207
207
 
208
208
  The server exposes one tool, `diffctx_context`, that assistants call when
209
- reviewing PRs, explaining changes, or investigating broken tests. It ranks the
210
- code that explains a diff, then reads only the fragments the assistant picked —
211
- two calls that pay for the selection instead of a whole pack. The wider
209
+ reviewing PRs, explaining changes, or investigating broken tests. By default it
210
+ answers what a change reaches outside its diff — callers, the tests that reach
211
+ them, changed contracts — in under 2k tokens; `symbol` asks the same of a name
212
+ with no change at all. `mode=locate` ranks the code that explains a diff and
213
+ `fragment_ids` then reads only the fragments the assistant picked — two calls
214
+ that pay for the selection instead of a whole pack. The wider
212
215
  `get_tree_map` and `get_file_context` tools are opt-in via
213
216
  `DIFFCTX_MCP_LEGACY_TOOLS=1`. Filesystem confinement via
214
217
  `DIFFCTX_ALLOWED_PATHS`: see [SECURITY.md](SECURITY.md).
@@ -1,6 +1,6 @@
1
1
  [package]
2
2
  name = "diffctx"
3
- version = "1.18.1"
3
+ version = "1.18.3"
4
4
  edition = "2024"
5
5
  rust-version = "1.85"
6
6
  description = "Selects the minimum code an LLM needs to review a git diff: walks the dependency graph outward from changed lines and stops when extra context stops paying for itself"
@@ -110,7 +110,7 @@ tree-sitter-graphql = { version = "0.2", optional = true }
110
110
  tree-sitter-dart = { version = "0.2", optional = true }
111
111
  tree-sitter-prisma-io = { version = "1.6", optional = true }
112
112
  tree-sitter-svelte-ng = { version = "1.0", optional = true }
113
- tiktoken-rs = "=0.12.0"
113
+ tiktoken-rs = "=0.12.1"
114
114
  rayon = "1.10"
115
115
  serde = { version = "1", features = ["derive", "rc"] }
116
116
  serde_json = { version = "1", features = ["preserve_order"] }
@@ -206,9 +206,12 @@ With `pip install 'diffctx[mcp]'` already done, replace the
206
206
  `uvx --from 'diffctx[mcp]' diffctx-mcp` tail with plain `diffctx-mcp`.
207
207
 
208
208
  The server exposes one tool, `diffctx_context`, that assistants call when
209
- reviewing PRs, explaining changes, or investigating broken tests. It ranks the
210
- code that explains a diff, then reads only the fragments the assistant picked —
211
- two calls that pay for the selection instead of a whole pack. The wider
209
+ reviewing PRs, explaining changes, or investigating broken tests. By default it
210
+ answers what a change reaches outside its diff — callers, the tests that reach
211
+ them, changed contracts — in under 2k tokens; `symbol` asks the same of a name
212
+ with no change at all. `mode=locate` ranks the code that explains a diff and
213
+ `fragment_ids` then reads only the fragments the assistant picked — two calls
214
+ that pay for the selection instead of a whole pack. The wider
212
215
  `get_tree_map` and `get_file_context` tools are opt-in via
213
216
  `DIFFCTX_MCP_LEGACY_TOOLS=1`. Filesystem confinement via
214
217
  `DIFFCTX_ALLOWED_PATHS`: see [SECURITY.md](SECURITY.md).