Skip to content

v1.0.3 — warning emission completeness

Choose a tag to compare

@kurushimee kurushimee released this 11 Jun 01:43
508d0a4

The warning-completeness release. The v1.0.2 plugin sessions exposed that the existing LSP test
suite cannot be the single source of truth: 22+ declared warning codes had no emission site
(#29), @warning_ignore missed multi-line targets (#28), and several navigation capabilities
quietly returned nothing on shapes every real project uses. Each fix was verified the same way
the bugs were found — driving every exposed capability against the two acceptance projects (a
243-script OSS project and a 2,338-script production project) and reading what actually comes
back.

Fixed — analyzer warnings (#28, #29)

  • @warning_ignore covers multi-line targets: the ignored-lines table now records Godot's
    annotation→target-header span per target kind (multi-line signatures, initializers,
    for/if/while/match headers, match-branch patterns) instead of a single line, exactly
    as upstream — body lines past the header still warn.
  • 19 missing warning emission sites ported function-for-function from
    gdscript_analyzer.cpp/gdscript_parser.cpp @ 4.6.3-stable: EMPTY_FILE,
    STANDALONE_EXPRESSION, STANDALONE_TERNARY, UNREACHABLE_CODE, UNREACHABLE_PATTERN,
    ASSERT_ALWAYS_TRUE, ASSERT_ALWAYS_FALSE, INTEGER_DIVISION, INCOMPATIBLE_TERNARY,
    UNTYPED_DECLARATION, INFERRED_DECLARATION, REDUNDANT_STATIC_UNLOAD,
    UNASSIGNED_VARIABLE, UNASSIGNED_VARIABLE_OP_ASSIGN, UNUSED_VARIABLE,
    UNUSED_LOCAL_CONSTANT, RETURN_VALUE_DISCARDED, STATIC_CALLED_ON_INSTANCE,
    INT_AS_ENUM_WITHOUT_CAST. Per-code unit tests in gd_analyze/tests/warning_emissions.rs;
    the conformance ratchet holds 300/300. (DEPRECATED_KEYWORD and the 3 deprecated codes have
    no emission site upstream either and stay silent by fidelity; UNSAFE_PROPERTY_ACCESS stays
    deferred deliberately — the attribute lookup cannot yet make that negative claim truthfully.)
  • Warning output order matches apply_pending_warnings: warnings stable-sort by anchor
    line among themselves; errors keep emission order.
  • Untyped rest parameters no longer error: func f(...args): is an inferred Array plus
    UNTYPED_DECLARATION, not a false-positive type error.

Fixed — navigation (found by the real-project capability walk)

  • definition on a dotted method call through a typed var (cel.on_remove()) now jumps to
    the member declaration in the declaring file.
  • callHierarchy/incomingCalls was structurally empty across files: it now uses the same
    project-wide two-phase textual scan as references (Godot's workspace.cpp:472 strategy)
    instead of the interface-level reverse index, which never contains body-only method names.
  • prepareCallHierarchy on a call-site callee prepares the callee (dotted and bare);
    declaration clicks keep the enclosing-function behavior.
  • <Script #N> no longer leaks into cast errors — the script's class_name (or file
    basename) renders instead, matching Godot's DataType::to_string().

Fixed — logging & CI

  • Bridged log::* events render with their real target/file/line (tracing-log feature), so
    GDLS_LOG per-target directives match them.
  • Bounded 500 ms ETXTBSY retry on the auto-dump Godot spawn (transient "Text file busy").
  • Integration tests read responses by skipping interleaved notifications, like a real client.

Changed

  • Background dump timeout raised 60 s → 5 min (the deadline only reaps a wedged Godot child;
    60 s could kill legitimate slow first boots).
  • No background auto-dump when extensionApiPath is pinned (it was pure waste).
  • Acceptance warning baselines re-based for the new emission sites; error baselines hold
    exactly on both acceptance projects, verified per-platform.

Performance

  • The analyzer's unused-variable/parameter/signal sweeps share one per-analysis decl-identifier
    set instead of rebuilding it per declaration (was O(N × tree size) per function with N
    locals).

Install

Download the binary for your platform, unpack it, and point your editor's LSP client at gdls
over stdio (no Godot process needed at runtime):

  • Linux x86_64: gdls-v1.0.3-linux-x86_64.tar.gz
  • Windows x86_64: gdls-v1.0.3-windows-x86_64.zip

Verify downloads with sha256sum -c SHA256SUMS.


Known issues — fixed in v1.0.4:
hover and definition on native classes and members returned degraded labels or nothing
(#34, #35), workspace/symbol anchored every global class at a zero-width line-0 location
(#33), and the analyzer dropped native typing exactly where upstream's class-resolution loop
falls through to the native check — the gap that also kept UNSAFE_PROPERTY_ACCESS deferred
(#32).