Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use dotnet 8.x in pre-commits to fix flaky failures #6083

Merged
merged 1 commit into from
Mar 14, 2024

Conversation

alex-mccarthy-unity
Copy link
Collaborator

Proposed change(s)

The 8.x release should contain dotnet/runtime#90342 which fixes dotnet/runtime#80619.

I hope this will fix flaky failures like https://github.com/Unity-Technologies/ml-agents/actions/runs/8268945605/job/22623023348 of the form:

dotnet-format............................................................Failed
- hook id: dotnet-format
- exit code: 1

System.IO.IOException: The system cannot open the device or file specified. : 'NuGet-Migrations'
   at System.Threading.Mutex.CreateMutexCore(Boolean initiallyOwned, String name, Boolean& createdNew)
   at System.Threading.Mutex..ctor(Boolean initiallyOwned, String name)
   at NuGet.Common.Migrations.MigrationRunner.Run(String migrationsDirectory)
   at Microsoft.DotNet.Configurer.DotnetFirstTimeUseConfigurer.Configure()
   at Microsoft.DotNet.Cli.Program.ConfigureDotNetForFirstTimeUse(IFirstTimeUseNoticeSentinel firstTimeUseNoticeSentinel, IAspNetCertificateSentinel aspNetCertificateSentinel, IFileSentinel toolPathSentinel, Boolean isDotnetBeingInvokedFromNativeInstaller, DotnetFirstRunConfiguration dotnetFirstRunConfiguration, IEnvironmentProvider environmentProvider, Dictionary`2 performanceMeasurements)
   at Microsoft.DotNet.Cli.Program.ProcessArgs(String[] args, TimeSpan startupTime, ITelemetry telemetryClient)
   at Microsoft.DotNet.Cli.Program.Main(String[] args)

Useful links (Github issues, JIRA tickets, ML-Agents forum threads etc.)

Types of change(s)

  • Bug fix
  • New feature
  • Code refactor
  • Breaking change
  • Documentation update
  • Other (please describe)

Checklist

  • Added tests that prove my fix is effective or that my feature works
  • Updated the changelog (if applicable)
  • Updated the documentation (if applicable)
  • Updated the migration guide (if applicable)

Other comments

The 8.x release should contain dotnet/runtime#90342 which fixes dotnet/runtime#80619.

I hope this will fix flaky failures like https://github.com/Unity-Technologies/ml-agents/actions/runs/8268945605/job/22623023348 of the form:
```
dotnet-format............................................................Failed
- hook id: dotnet-format
- exit code: 1

System.IO.IOException: The system cannot open the device or file specified. : 'NuGet-Migrations'
   at System.Threading.Mutex.CreateMutexCore(Boolean initiallyOwned, String name, Boolean& createdNew)
   at System.Threading.Mutex..ctor(Boolean initiallyOwned, String name)
   at NuGet.Common.Migrations.MigrationRunner.Run(String migrationsDirectory)
   at Microsoft.DotNet.Configurer.DotnetFirstTimeUseConfigurer.Configure()
   at Microsoft.DotNet.Cli.Program.ConfigureDotNetForFirstTimeUse(IFirstTimeUseNoticeSentinel firstTimeUseNoticeSentinel, IAspNetCertificateSentinel aspNetCertificateSentinel, IFileSentinel toolPathSentinel, Boolean isDotnetBeingInvokedFromNativeInstaller, DotnetFirstRunConfiguration dotnetFirstRunConfiguration, IEnvironmentProvider environmentProvider, Dictionary`2 performanceMeasurements)
   at Microsoft.DotNet.Cli.Program.ProcessArgs(String[] args, TimeSpan startupTime, ITelemetry telemetryClient)
   at Microsoft.DotNet.Cli.Program.Main(String[] args)
```
Copy link
Collaborator

@miguelalonsojr miguelalonsojr left a comment

Choose a reason for hiding this comment

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

Let it fly!

@miguelalonsojr miguelalonsojr merged commit fb2af76 into develop Mar 14, 2024
7 checks passed
@delete-merged-branch delete-merged-branch bot deleted the fix-flaky-pre-commit-dotnet-upgrade branch March 14, 2024 09:45
@alex-mccarthy-unity
Copy link
Collaborator Author

Unfortunately, we still see the same failure after this change :( https://github.com/Unity-Technologies/ml-agents/actions/runs/8278579680/job/22651228262

@Namanl2001
Copy link

Namanl2001 commented Mar 26, 2024

@alex-mccarthy-unity I'm facing the same issue with v8.0.2

did you find or know of any workaround for this? thanks!

@alex-mccarthy-unity
Copy link
Collaborator Author

@alex-mccarthy-unity I'm facing the same issue with v8.0.2

did you find or know of any workaround for this? thanks!

Unfortunately I don't know of any solutions :( I've found that retrying failed tasks has a good chance of the retry succeeding, but I know that that's an unsatisfying workaround.

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.

IOException running NuGet-Migrations during tests in dotnet CLI first run
3 participants