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

Aspire on NixOS cant find dotnet - sdk #331

Open
klowdo opened this issue Jan 8, 2025 · 0 comments
Open

Aspire on NixOS cant find dotnet - sdk #331

klowdo opened this issue Jan 8, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@klowdo
Copy link

klowdo commented Jan 8, 2025

Describe the bug
Maybe a very niche issue.. but on nixos where all packages are located in the nix-store by its hash key.
when i start a test or debug a test with the Aspire Test host i get that no dotnet versions are installed.

My guess is that the "test" part of this plugin does not forward DOTNET_ROOT env.
When i remove the plugin i can run the tests through test runner

To Reproduce
Steps to reproduce the behavior:

  1. Create a Default aspire project template with xunit tests
  2. Uncomment the test
  3. Run this test
  4. Open Run Tool
  5. See error

Expected behavior
It should start the test as normal

Screenshots
image

Reproducing sample
Link to a test project to reproduce the bug.

Logs

....SessionEnvironmentVariable(key=DOTNET_ROOT, value=/nix/store/9hffmv5slb1lgrzx5lrabgbsvd9vvv49-dotnet-wrapped-combined)
2025-01-08 13:23:11,069 [1141813]  FINER - #c.j.r.a.s.SessionExecutableFactory - Browser settings for runnable project (/home/klowdo/dev/Customer/Project/CustomerProject.Host/CustomerProject.Host.csproj): com.intellij.ide.browsers.StartBrowserSettings@22518e0c
2025-01-08 13:23:11,070 [1141814]   INFO - c.j.r.r.RiderAsyncProgramRunner - Launching configuration null
2025-01-08 13:23:11,126 [1141870]   INFO - #c.j.r.r.c.HotReloadProgramRunnerCallback - Create DotNetRunHotReloadProcess. Pipe: d681b8bc-02c3-4693-a5b8-c75a35a48599
2025-01-08 13:23:11,126 [1141870]   INFO - #c.j.r.d.e.DotNetHotReloadManager - add runtime hot reload process
2025-01-08 13:23:11,127 [1141871]   INFO - #c.j.r.d.e.DotNetHotReloadManager - Waiting for a running operation to be ready, current state: NotInitialize
2025-01-08 13:23:11,127 [1141871]   INFO - #c.j.r.d.e.DotNetHotReloadManager - Calling an action in runAfterReady, StartInitialize state is set to hot reload
2025-01-08 13:23:11,127 [1141871]   INFO - #c.j.r.d.e.DotNetHotReloadManager - hot reload session is null, create...
2025-01-08 13:23:11,128 [1141872]   INFO - #c.j.r.d.e.DotNetHotReloadManager - hot reload session created
2025-01-08 13:23:11,134 [1141878]  FINER - #c.j.r.a.s.SessionManager - Aspire session process was started (id: 4f10c892-21d7-46ee-84c4-2994d19b4ac0)
2025-01-08 13:23:11,138 [1141882]  FINER - #c.j.r.a.s.SessionHostManager - Aspire session log received (4f10c892-21d7-46ee-84c4-2994d19b4ac0, false, /home/klowdo/dev/Customer/Project/CustomerProject.Host/bin/Debug/net9.0/CustomerProject.Host
)
2025-01-08 13:23:11,138 [1141882]  FINER - #c.j.r.a.s.SessionHostManager - Aspire session started (4f10c892-21d7-46ee-84c4-2994d19b4ac0, 34937)
2025-01-08 13:23:11,149 [1141893]  FINER - #c.j.r.a.s.SessionHostManager - Aspire session log received (4f10c892-21d7-46ee-84c4-2994d19b4ac0, false, You must install .NET to run this application.␍
␍
App: /home/klowdo/dev/Customer/Project/CustomerProject.Host/bin/Debug/net9.0/CustomerProject.Host␍
Architecture: x64␍
App host version: 9.0.0␍
.NET location: Not found␍
␍
Learn more:␍
https://aka.ms/dotnet/app-launch-failed␍
␍
Download the .NET runtime:␍
https://aka.ms/dotnet-core-applaunch?missing_runtime=true&arch=x64&rid=linux-x64&os=nixos.24.11&apphost_version=9.0.0␍
)
2025-01-08 13:23:11,151 [1141895]  FINER - #c.j.r.a.s.SessionManager - Stopping session 4f10c892-21d7-46ee-84c4-2994d19b4ac0 (131, null)
2025-01-08 13:23:11,151 [1141895]   INFO - #c.j.r.r.c.HotReloadProgramRunnerCallback - DotNetRunHotReloadProcess lifetime is terminated. Pipe: d681b8bc-02c3-4693-a5b8-c75a35a48599
2025-01-08 13:23:11,151 [1141895]  FINER - #c.j.r.a.s.SessionHostManager - Aspire session terminated (4f10c892-21d7-46ee-84c4-2994d19b4ac0, 131)
2025-01-08 13:23:11,153 [1141897]   INFO - #c.j.r.d.e.DotNetHotReloadSession - Process id not defined, pipe name: d681b8bc-02c3-4693-a5b8-c75a35a48599
2025-01-08 13:23:11,153 [1141897]   INFO - #c.j.r.d.e.DotNetHotReloadManager - Action call in runAfterReady completed
2025-01-08 13:23:11,153 [1141897]   INFO - #c.j.r.d.e.DotNetHotReloadManager - Start terminate hot reload session
2025-01-08 13:23:11,153 [1141897]   INFO - #c.j.r.d.e.DotNetHotReloadManager - ready: false, state: StartInitialize
2025-01-08 13:23:11,153 [1141897]   INFO - #c.j.r.d.e.DotNetHotReloadManager - DotNetHotReloadSession is terminated
2025-01-08 13:23:11,153 [1141897]   INFO - #c.j.r.d.e.DotNetHotReloadManager - NotInitialize state is set to hot reload
2025-01-08 13:23:11,153 [1141897]  FINER - #c.j.r.a.s.SessionHostManager - Aspire session log received (4f10c892-21d7-46ee-84c4-2994d19b4ac0, false, 
Process finished with exit code 131.)
2025-01-08 13:23:11,168 [1141912]   INFO - #c.j.d.ProcessInfoApi - Plugin backend file linux-x64/libJetBrains.Common.ProcessInfoApi.so found in DotFiles: /nix/store/fwl32776ixjdd072ks1yq8yd7zffxfvn-rider-2024.3.3/rider/plugins/dotCommon/DotFiles/linux-x64/libJetBrains.Common.ProcessInfoApi.so
2025-01-08 13:23:11,170 [1141914]   WARN - #c.j.d.m.s.SessionsController - Failed to start monitoring session for /home/klowdo/dev/Customer/Project/CustomerProject.Host/bin/Debug/net9.0/CustomerProject.Host
java.lang.RuntimeException: Can't get path from symlink: No such file or directory (system:2)
[location] = ./dotCommon/Native/Shared/include/jb/system/linux/detail_proc_utils.hpp(33)
[function] = std::filesystem::path jb::detail_proc_utils::read_link(const char *const)
	at com.jetbrains.dotCommon.ProcessInfoApi.getProcessExecutable(Native Method)
	at com.jetbrains.dpa.monitoring.ProcessInfo$Companion.create(ProcessInfo.kt:20)
	at com.jetbrains.dpa.monitoring.sessions.Session.<init>(Session.kt:99)
	at com.jetbrains.dpa.monitoring.services.SessionsController.startSession(SessionsController.kt:34)
	at com.jetbrains.dpa.monitoring.listeners.BasicMonitoringExecutionListener$handleStartViaDpaRunner$2$1.invokeSuspend(BasicMonitoringExecutionListener.kt:64)
	at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
	at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:104)
	at com.intellij.openapi.application.impl.DispatchedRunnable.run(DispatchedRunnable.kt:44)
	at com.intellij.openapi.application.TransactionGuardImpl.runWithWritingAllowed(TransactionGuardImpl.java:236)
	at com.intellij.openapi.application.TransactionGuardImpl.access$100(TransactionGuardImpl.java:25)
	at com.intellij.openapi.application.TransactionGuardImpl$2.run(TransactionGuardImpl.java:218)
	at com.intellij.openapi.application.impl.FlushQueue.runNextEvent(FlushQueue.java:117)
	at com.intellij.openapi.application.impl.FlushQueue.flushNow(FlushQueue.java:43)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:318)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:781)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:728)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:722)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:400)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:87)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:750)
	at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.kt:675)
	at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.kt:573)
	at com.intellij.ide.IdeEventQueue.dispatchEvent$lambda$18$lambda$17$lambda$16$lambda$15(IdeEventQueue.kt:355)
	at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:857)
	at com.intellij.ide.IdeEventQueue.dispatchEvent$lambda$18$lambda$17$lambda$16(IdeEventQueue.kt:354)
	at com.intellij.ide.IdeEventQueueKt.performActivity$lambda$2$lambda$1(IdeEventQueue.kt:1045)
	at com.intellij.openapi.application.WriteIntentReadAction.lambda$run$0(WriteIntentReadAction.java:24)
	at com.intellij.openapi.application.impl.AnyThreadWriteThreadingSupport.runWriteIntentReadAction(AnyThreadWriteThreadingSupport.kt:128)
	at com.intellij.openapi.application.impl.ApplicationImpl.runWriteIntentReadAction(ApplicationImpl.java:916)
	at com.intellij.openapi.application.WriteIntentReadAction.compute(WriteIntentReadAction.java:55)
	at com.intellij.openapi.application.WriteIntentReadAction.run(WriteIntentReadAction.java:23)
	at com.intellij.ide.IdeEventQueueKt.performActivity$lambda$2(IdeEventQueue.kt:1045)
	at com.intellij.ide.IdeEventQueueKt.performActivity$lambda$3(IdeEventQueue.kt:1054)
	at com.intellij.openapi.application.TransactionGuardImpl.performActivity(TransactionGuardImpl.java:109)
	at com.intellij.ide.IdeEventQueueKt.performActivity(IdeEventQueue.kt:1054)
	at com.intellij.ide.IdeEventQueue.dispatchEvent$lambda$18(IdeEventQueue.kt:349)
	at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.kt:395)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:207)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:128)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:117)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:105)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:92)
2025-01-08 13:23:24,148 [1154892]   INFO - #c.j.r.a.b.RiderAnAction - Executing ReSharper action 'UnitTestSession.Abort'
2025-01-08 13:23:24,163 [1154907]   INFO - #c.j.r.a.RdClientActionPresentationUpdateHost - >> Begin backend 'UnitTestSession.Abort' action session
2025-01-08 13:23:24,199 [1154943]  FINER - #c.j.r.a.s.SessionHostLauncher - Killing Aspire session host process
2025-01-08 13:23:24,241 [1154985]   INFO - c.j.r.f.S.Server - ServerSocket: start terminating lifetime
2025-01-08 13:23:24,243 [1154987]   INFO - c.j.r.f.S.Server - ServerSocket: termination finished
2025-01-08 13:23:24,243 [1154987]   INFO - #c.j.r.a.RdClientActionPresentationUpdateHost - << End backend 'UnitTestSession.Abort' action session
2025-01-08 13:23:26,142 [1156886]   INFO - #c.j.r.a.b.RiderAnAction - Executing ReSharper action 'UnitTestSession.Abort'
2025-01-08 13:23:26,142 [1156886]   INFO - #c.j.r.a.RdClientActionPresentationUpdateHost - >> Begin backend 'UnitTestSession.Abort' action session
2025-01-08 13:23:26,146 [1156890]   INFO - #c.j.r.a.RdClientActionPresentationUpdateHost - << End backend 'UnitTestSession.Abort' action session
2025-01-08 13:23:32,190 [1162934]   WARN - #c.i.u.Alarm - Do not create alarm without coroutineScope: com.intellij.openapi.application.ClipboardAnalyzeListener.applicationActivated(ClipboardAnalyzeListener.java:31)
2025-01-08 13:23:32,190 [1162934]   WARN - #c.i.u.Alarm - Do not create alarm without coroutineScope: com.intellij.openapi.application.ClipboardAnalyzeListener.applicationActivated(ClipboardAnalyzeListener.java:31)
2025-01-08 13:23:32,474 [1163218]   WARN - #c.i.u.Alarm - Do not create alarm without coroutineScope: com.intellij.openapi.application.ClipboardAnalyzeListener.applicationActivated(ClipboardAnalyzeListener.java:31)
2025-01-08 13:23:32,475 [1163219]   WARN - #c.i.u.Alarm - Do not create alarm without coroutineScope: com.intellij.openapi.application.ClipboardAnalyzeListener.applicationActivated(ClipboardAnalyzeListener.java:31)
2025-01-08 13:23:32,691 [1163435]   WARN - #c.i.u.Alarm - Do not create alarm without coroutineScope: com.intellij.openapi.application.ClipboardAnalyzeListener.applicationActivated(ClipboardAnalyzeListener.java:31)
2025-01-08 13:23:32,691 [1163435]   WARN - #c.i.u.Alarm - Do not create alarm without coroutineScope: com.intellij.openapi.application.ClipboardAnalyzeListener.applicationActivated(ClipboardAnalyzeListener.java:31)
2025-01-08 13:23:33,005 [1163749]   INFO - #c.i.s.SettingsSyncBridge - Couldn't obtain event lock. Will retry later
2025-01-08 13:23:34,005 [1164749]   INFO - #c.i.s.SettingsSyncBridge - Couldn't obtain event lock. Will retry later

System information:

  • OS: NixOS
  • .NET version: 9
  • JetBrains Rider version: 2024.3.3
  • Aspire plugin version: 1.6.4

Additional context
Not very many people running nix os and developing dotent application

@klowdo klowdo added the bug Something isn't working label Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant