Repository navigation
merge: reconcile upstream through a3fdb920 - #470
Conversation
…the package appears later (colbymchenry#2507) `from fastapi import FastAPI` reaches `fastapi/applications.py` through `fastapi/__init__.py`, which re-exports it and declares no node named `FastAPI`. While that `__init__.py` was missing, or before it gained the re-export, the calls through the name failed and were parked under the name, which the package file that then appears or changes never carries. A fresh index linked them; a sync never did. An unaliased from-import of a module in the project's own folders is now parked under the module's key, as an aliased one is (colbymchenry#2501): a relative import, or an absolute one whose dotted path, or the package holding it, is a project folder at any depth. An outside package's names (`from django.db.models import Q`) keep their tails, since on netbox they would crowd 'module:models', 'module:urls' and others past the retry ceiling. colbymchenry#2450's by-name lookup still finds every parked ref by its own name. Two limits made the restored package's importers wait anyway: - A module key gets a retry ceiling of its own, 5,000 rather than the 500 a name tail has. A large population under a module key is every importer of a package that was missing, not noise: fastapi's 1,069 `from fastapi import ...` refs, Django's 2,257 under 'module:urls'. - The CG-33 rebind's per-name ceiling counts only the edges that existed before the retry. Relinking every `from django.urls import path` pushed `path` over it, so the `path` edges the sync's new definitions moved were never rebound; the retry's own edges are still rebound under a name that stays below it, as before. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Priority: ⬇️ Low Merge Risk | ⚪ Minimal · up to
|
| Check name | Status | Explanation |
|---|---|---|
| Description Check | Check skipped - CodeRabbit’s high-level summary is enabled. | |
| Title check | The title clearly identifies the primary change: reconciling the fork with upstream through commit a3fdb92. | |
| Linked Issues check | Check skipped because no linked issues were found for this pull request. | |
| Out of Scope Changes check | Check skipped because no linked issues were found for this pull request. | |
| Suppressions Explained | PASS: The pull request adds no lint, type-check, or compiler suppression directive. The changed files contain no added eslint-disable, @ts-ignore, @ts-expect-error, #[allow(...)], noqa, or i… |
|
| User-Visible Changes Documented | The diff changes Python import-resolution and retry behavior, database helpers, tests, a golden fixture, CHANGELOG.md, and the fork commit reference in README.md. It does not add, remove, or rename a … |
✨ Finishing Touches
-
📝 Generate docstrings
-
-
- Commit to this branch
- Create a new PR
-
🧪 Generate unit tests (beta)
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Comment @coderabbitai help to get the list of available commands.
There was a problem hiding this comment.
All reported issues were addressed across 9 files
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
Merges upstream
mainthrougha3fdb920(colbymchenry#2507: a Python import of a name a package re-exports links when the package appears later) intofork/consolidated. Upstream moved again right after #469 landed, so the hourly deploy would hold back again until this lands.What changed
import-resolver.tsconflicted. Merged by hand: upstream's project-module check for unaliased imports, next to the fork's file-aware external-import check. Two memo clears upstream lists (pythonModuleFileMemos,PY_MODULE_SYMBOLS) are not carried because the fork has no such maps; onlyPROJECT_FOLDER_SUFFIXESis.src/index.tsconflicted because theCodeGraphclass lives insrc/codegraph.tson the fork. Upstream's three small edits there (last edge id before the failed-reference retry, passed to the stale-edge rebind) are applied tosrc/codegraph.ts;src/index.tsstays the fork's.queries.ts,reference-tail.ts,extraction/index.tsand the upstream test merged cleanly.a3fdb920.Golden dump
torture-multilang.dumpchanges one line: the unresolved Python importthingintorture.pynow waits undermodule:relativeinstead ofthing. That is the behavior colbymchenry#2507 adds (a reference waits for its module so a later package file relinks it).Evidence
Full suite: 694 files, 8,886 passed, 39 skipped, exit 0. Typecheck clean. The upstream sync test file passes. No resolver or kernel code changed in this PR, so no precision or link-count run.
README rows checked: upstream merge point (changed); no other row quotes this area.
Summary by cubic
Merges upstream
mainthrougha3fdb920intofork/consolidated, bringing upstream's fix that links a Python import of a name a package re-exports when the package appears later. The fork now sits on a newer upstream base.Behaviorally,
from fastapi import FastAPI(wherefastapi/__init__.pyre-exports the name from a deeper module) now links when that__init__.pyis added after importers were indexed, or gains the re-export in a later edit. Before, calls through the name stayed unlinked until re-index. Two retry-ceiling adjustments support this: module keys get their own ceiling of 5,000 (vs 500 for name tails, since a large population under a module key is every importer of a restored package, not noise), and the stale-edge rebind's per-name ceiling counts only edges that existed before the failed-ref retry, so relinking everyfrom django.urls import pathno longer pushespathover the ceiling and leaves the new definitions' edges unrebound.Merge notes
import-resolver.tsconflicted and was merged by hand: upstream's project-module check for unaliased imports sits next to the fork's file-aware external-import check.src/codegraph.ts, where the fork'sCodeGraphclass lives;src/index.tsstays the fork's.module:relativeinstead of its own name, which is the new behavior upstream adds.Written for commit 978b2bd. Summary will update on new commits.
Summary by CodeRabbit