Repository navigation
Own schemas only through package::, parent:: or self:: (part of #122) - #123
Merged
Merged
Conversation
added 3 commits
November 15, 2026 07:53
Pin core at 14ce546 (import::bare-own-schema-path) and generation and the generators at the CLI's revs. A bare path to one of the package's own schemas is reported with core's own error and fix, from core's check_imports; the "Add use" fix, auto-import and use-path completion write and offer own schemas only as package::.
…9e, comline-typescript d377fbf)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #122: the own-schema-path error with its quick fix, and no more generating bare paths. Groups, the formatter and
[format](the rest of #122) are not in this PR. Rule: Own schemas only through relative paths; core: ComlineProject/core#285 (import::bare-own-schema-path, merged as 14ce546).What changes
14ce546, and generatione22109e, comline-rust2d2c885, comline-typescriptc44b39d, the same revs as the CLI (cli#163), so the tree has onecomline-core. No other source change was needed for core's changes since 868e831.analysis::import_check::bare_own_schema_pathsruns core'scheck_importsover aProjectContextbuilt from the files the server has (the file's own text for the fix, the package's other schemas by namespace) and keepsBARE_OWN_SCHEMA_PATH. Code, message, help and fix are core's, not a second copy of the rule. It goes throughfrom_core, so the fix reaches the editor as the existingfix_actionsquick fix ("Writepackage::types::User"). The mirror stops at ausecore flags, as core does (a bare path to a missing item says only the bare error until it is writtenpackage::). Not run for a dependency's own files; runs without aconfig.idp.use ..." code action, missing-import message and auto-import completion (Candidate::use_path,unimported_item):package::types::Messagefor the package's own schemas; a dependency's orstd's path stays as it is.use-path completion: the top level offers dependencies,package/parent/selfandstd; own schemas are offered underpackage::/parent::/self::, and nothing is offered along a bare path to one. The legacyimportis unchanged.package::. Parsing-only tests (util.rs, theusecontext reader,add_use_edittext) keep their plain text. New tests: the diagnostic (every form, message, fix applied and re-checked, nested, no manifest, relative/dependency/std not flagged, a typo stays unresolved, a dependency's own files), the quick fix, the "Adduse" fix (own and dependency), auto-import detail and edit, and completion (top level, underpackage::, nothing along a bare path).Parity with core
The "did you mean" for
use typse::Usersuggests the baretypesand its fix writes it, which the bare-path error then flags (then fixes). The editor words and offers what core does; tracked in ComlineProject/core#286.CI
Tests run in CI.