Skip to content

Conversation

@AgentEnder
Copy link
Member

Current Behavior

Maven and .NET use a bespoke script to handle skipping an optional native target in case a system is not setup on a dev's machine.

.NET isn't in codeowners

Expected Behavior

This pull request introduces improvements to the build and formatting workflows for the .NET and Maven plugins, streamlining the execution of native targets and updating code ownership assignments. The changes focus on refactoring build scripts to use a unified runner, adding new formatting capabilities for .NET projects, and updating the CODEOWNERS file for clearer team responsibilities.

Build and Format Workflow Improvements

  • Refactored the .NET analyzer build command in packages/dotnet/project.json to use the new run-native-target.js script, replacing the previous direct script invocation. [1] [2]
  • Added new format-native and _format-native targets to packages/dotnet/project.json, enabling verification and fixing of code formatting for the .NET analyzer using dotnet format.

Unified Native Target Runner

  • Introduced the scripts/run-native-target.js script to standardize running native build and install targets, controlled by environment variables for skipping builds.

Maven Plugin Build Refactor

  • Updated the Maven plugin's install workflow in packages/maven/maven-plugin/project.json to use the new native target runner, and removed the obsolete scripts/build-maven-analyzer.js script. [1] [2]

Ownership Updates

  • Updated the CODEOWNERS file to assign .NET-related directories to @FrozenPandaz and @AgentEnder, clarifying team responsibilities.

Related Issue(s)

Fixes #

@vercel
Copy link

vercel bot commented Oct 31, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Updated (UTC)
nx-dev Ready Ready Preview Oct 31, 2025 8:45pm

@netlify
Copy link

netlify bot commented Oct 31, 2025

Deploy Preview for nx-docs ready!

Name Link
🔨 Latest commit b20a071
🔍 Latest deploy log https://app.netlify.com/projects/nx-docs/deploys/69051f898b6b49000816bac0
😎 Deploy Preview https://deploy-preview-33323--nx-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@nx-cloud
Copy link
Contributor

nx-cloud bot commented Oct 31, 2025

View your CI Pipeline Execution ↗ for commit b20a071

Command Status Duration Result
nx run-many -t check-imports check-lock-files c... ✅ Succeeded 1m 40s View ↗
nx affected --targets=lint,test,test-kt,build,e... ✅ Succeeded 1m 2s View ↗
nx-cloud record -- nx-cloud conformance:check ✅ Succeeded 11s View ↗
nx-cloud record -- nx format:check ✅ Succeeded 2s View ↗
nx-cloud record -- nx sync:check ✅ Succeeded <1s View ↗

☁️ Nx Cloud last updated this comment at 2025-10-31 21:07:27 UTC

Copy link
Contributor

@nx-cloud nx-cloud bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nx Cloud has identified a possible root cause for your failed CI:

The test failure for dotnet:test is classified as 'environment_state' rather than 'code_change' for the following reasons:

File System Race Condition:
The error reports that /home/workflows/workspace/packages/nx/src/native/index.d.ts does not exist, but verification confirms the file is present on the filesystem with proper permissions and recent modification timestamps. This discrepancy indicates a timing issue where Jest's ts-jest transformer attempts to stat the file during cache key computation, but the file system operation fails despite the file existing.

Error Location in Test Infrastructure:
The failure occurs in ts-jest's getCacheKey() method, which is part of Jest's caching mechanism that runs before any test code executes. This is test infrastructure failing during setup, not a failure in the test logic or application code being tested.

No Similar Failures on Master Branch:
The similar task failure outputs for the master branch are empty, indicating this same test (dotnet:test) passes successfully on master with the same codebase state. If the PR's code changes caused this failure, we would not expect the test to pass consistently on master.

No Logical Connection to PR Changes:
The PR changes focus on:

  • Adding format-native targets to the dotnet package
  • Introducing a unified run-native-target.js script
  • Removing createProjectRootMappingsFromProjectConfigurations from exports and implementing it locally
  • Updating CODEOWNERS

None of these changes:

  • Modify the failing test file (create-nodes.spec.ts)
  • Alter the nx native bindings or their TypeScript definitions
  • Change Jest or ts-jest configuration
  • Touch the file that cannot be found (packages/nx/src/native/index.d.ts)

Environmental Indicators Present:

  • File system operation failure (ENOENT) despite file existence
  • Timing-sensitive operation (cache key computation requiring multiple file stats)
  • Test infrastructure failure rather than test execution failure
  • Non-deterministic behavior (file exists but cannot be accessed)

The failure exhibits classic symptoms of an environmental timing issue in the test infrastructure, not a legitimate code defect introduced by this pull request.

A code change would likely not resolve this issue, so no action was taken.

Nx CloudView in Nx Cloud ↗


🎓 To learn more about Self Healing CI, please visit nx.dev

@AgentEnder AgentEnder merged commit a5d34fd into master Nov 1, 2025
21 of 22 checks passed
@AgentEnder AgentEnder deleted the chore/dotnet-format branch November 1, 2025 17:30
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