Skip to content

Revert #130 and fix CI/CD pipeline#133

Merged
LakshyAAAgrawal merged 6 commits intomicrosoft:mainfrom
LakshyAAAgrawal:fix/cicd-pipeline-and-revert-130
Apr 9, 2026
Merged

Revert #130 and fix CI/CD pipeline#133
LakshyAAAgrawal merged 6 commits intomicrosoft:mainfrom
LakshyAAAgrawal:fix/cicd-pipeline-and-revert-130

Conversation

@LakshyAAAgrawal
Copy link
Copy Markdown
Collaborator

@LakshyAAAgrawal LakshyAAAgrawal commented Apr 9, 2026

Summary

Root causes fixed

Problem Fix
pytest==7.3.1 crashes on Python 3.12+ (removed ast.Str) Pin CI to Python 3.12, use pytest>=7.4.0
Old workflow only set up Go+Ruby, ran ALL tests blindly Per-language parallel jobs, each with proper runtime deps
Publish workflow missing runtimes, ran from forks Add all runtimes, add github.repository guard
Kotlin hover test: KLS NullPointerException (Gradle perms in CI) Mark as xfail(strict=False)

Additional fixes ported from #130 (the useful parts)

  • server.py: race condition in process tree signaling (parent.children() can throw if children exit mid-iteration)
  • Ruby tests: use set comparison for non-deterministic symbol ordering
  • Timeout test: handle concurrent.futures.TimeoutError for Python <3.11
  • requirements.txt: align jedi-language-server to 0.41.3 (matching pyproject.toml)

Test plan

  • All per-language CI jobs pass (Python, Go, Ruby, TS/JS, Rust, Java, Kotlin, Dart, clangd, C#, timeout)
  • Kotlin hover xfail does not block the pipeline
  • Publish workflow test job passes with all runtimes

Closes #132

LakshyAAAgrawal and others added 4 commits April 9, 2026 19:33
This reverts commit b07b682, reversing
changes made to ee0f6dc.
The CI/CD pipeline was broken by multiple issues:

1. Python version drift: `python-version: "3.x"` now resolves to Python
   3.14 on GitHub Actions, but `pytest==7.3.1` crashes on Python 3.12+
   (removed `ast.Str`). Fix: pin Python to 3.12 and use `pytest>=7.4.0`.

2. Incomplete runtime setup: the old test/publish workflows only set up
   Go+Ruby+Python but ran ALL tests. Tests for other languages relied on
   self-downloading binaries or silently failed. Fix: split test workflow
   into per-language jobs, each with proper runtime dependencies.

3. Publish workflow: lacked runtimes for most languages and would run
   tests from forks. Fix: add all runtimes and fork protection.

4. Kotlin hover test flaky: the Kotlin Language Server throws
   NullPointerException when Gradle has permission issues in CI. Fix:
   mark as xfail (the bug is in KLS, not multilspy).

Additional fixes ported:
- server.py: race condition in process tree signaling (children can exit
  between listing and signaling)
- Ruby tests: use set comparison for non-deterministic symbol ordering
- Timeout test: handle concurrent.futures.TimeoutError for Python <3.11
- requirements.txt: update jedi-language-server to 0.41.3 (matches
  pyproject.toml), use flexible pytest/pytest-asyncio versions
- chmod +x only sets owner execute bit; the KLS runs gradle/mvn as the
  runner user which may not be the owner. Use chmod a+x instead.
- Add verification that gradle/mvn are actually runnable after chmod.
- Remove xfail from Kotlin hover test since the root cause is fixed.
- Restore accidentally deleted comments in publish workflow.
Replace per-language parallel jobs with a single test job that sets up
all runtimes. Most language servers self-download their binaries, so
adding a new language server requires no CI changes.

Test across Python 3.10, 3.12, and 3.14 to verify compatibility with
all current production versions, instead of pinning to a single version.
@LakshyAAAgrawal LakshyAAAgrawal force-pushed the fix/cicd-pipeline-and-revert-130 branch from d9e04a8 to 9a218cc Compare April 9, 2026 21:09
Remove Rust, Java JDK, and Gradle setup action from CI — these servers
(rust-analyzer, Eclipse JDTLS, Kotlin LS) self-download their own
binaries and JRE. Installing them in CI masks setup failures.

Only keep system-level deps for servers that require them:
- go + gopls (Gopls checks for pre-installed binaries)
- ruby (Solargraph installs itself via gem if missing)
- node + npm (TypeScript LS installs via npm)
- dotnet (OmniSharp checks dotnet version)

Keep runner workarounds that fix environment issues:
- Remove broken JDK installations that interfere with JDTLS
- Fix gradle/mvn permissions for KLS classpath resolution
The Kotlin Language Server throws NullPointerException on hover when
Gradle classpath resolution fails. chmod a+x on /usr/bin/gradle fixes
shell access but not JVM subprocess access (likely runner security
policy). The failure is non-deterministic: on this CI run, 3.10 and
3.14 passed all Kotlin tests while 3.12 failed only the sync hover.

This is a KLS bug (NullPointerException with incomplete classpath),
not a multilspy bug. Mark both async and sync hover tests as
xfail(strict=False) so they pass when they work and don't block CI
when they don't.
@LakshyAAAgrawal LakshyAAAgrawal force-pushed the fix/cicd-pipeline-and-revert-130 branch from baad43f to 0964bcd Compare April 9, 2026 21:39
@LakshyAAAgrawal LakshyAAAgrawal merged commit 75184ea into microsoft:main Apr 9, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants