Almighty-Alpaca / JetBrains-Discord-Integration

Discord rich presence integration for all JetBrains IDEs
https://plugins.jetbrains.com/plugin/10233-discord-integration
Apache License 2.0
586 stars 64 forks source link

CLion 2023.2.1 Error #372

Closed edgarcnp closed 9 months ago

edgarcnp commented 10 months ago
  Unhandled exception in [StandaloneCoroutine{Cancelling}@a01e51c, Dispatchers.Default]

  java.io.FileNotFoundException: \\?\pipe\discord-ipc-0 (Access is denied)
at java.base/java.io.RandomAccessFile.open0(Native Method)
at java.base/java.io.RandomAccessFile.open(RandomAccessFile.java:344)
at java.base/java.io.RandomAccessFile.<init>(RandomAccessFile.java:259)
at java.base/java.io.RandomAccessFile.<init>(RandomAccessFile.java:213)
at dev.cbyrne.kdiscordipc.core.socket.impl.WindowsSocket.connect(WindowsSocket.kt:23)
at dev.cbyrne.kdiscordipc.core.socket.handler.SocketHandler.connect(SocketHandler.kt:59)
at dev.cbyrne.kdiscordipc.KDiscordIPC.connect(KDiscordIPC.kt:83)
at dev.cbyrne.kdiscordipc.KDiscordIPC.connect$default(KDiscordIPC.kt:76)
at com.almightyalpaca.jetbrains.plugins.discord.plugin.rpc.connection.DiscordIpcConnection$connect$2.invokeSuspend(DiscordIpcConnection.kt:59)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:584)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:793)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:697)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:684)
Suppressed: kotlinx.coroutines.internal.DiagnosticCoroutineContextException: [StandaloneCoroutine{Cancelled}@a01e51c, Dispatchers.Default]
kotlin.UninitializedPropertyAccessException: lateinit property randomAccessFile has not been initialized
    at dev.cbyrne.kdiscordipc.core.socket.impl.WindowsSocket.close(WindowsSocket.kt:28)
    at dev.cbyrne.kdiscordipc.core.socket.handler.SocketHandler.disconnect(SocketHandler.kt:67)
    at dev.cbyrne.kdiscordipc.KDiscordIPC.disconnect(KDiscordIPC.kt:118)
    at com.almightyalpaca.jetbrains.plugins.discord.plugin.rpc.connection.DiscordIpcConnection.disconnectInternal(DiscordIpcConnection.kt:77)
    at com.almightyalpaca.jetbrains.plugins.discord.plugin.rpc.connection.DiscordIpcConnection.dispose(DiscordIpcConnection.kt:81)
    at com.intellij.openapi.util.ObjectTree.runWithTrace(ObjectTree.java:129)
    at com.intellij.openapi.util.ObjectTree.executeAll(ObjectTree.java:161)
    at com.intellij.openapi.util.Disposer.dispose(Disposer.java:262)
    at com.intellij.openapi.util.Disposer.dispose(Disposer.java:250)
    at com.almightyalpaca.jetbrains.plugins.discord.plugin.rpc.RpcService$update$1.invokeSuspend(RpcService.kt:115)
    at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
    at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
    at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:584)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:793)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:697)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:684)
aiscy commented 9 months ago

Hey @edgarcnp. I've been trying to track down the source of this issue for some time, but no luck so far. I just can't reproduce it in any way. Could you attach the output of AccessChk here? .\accesschk64 -lv \.\pipe\discord-ipc-0 when Discord is running. Maybe this will help to locate the problem.

edgarcnp commented 9 months ago

Hey @edgarcnp. I've been trying to track down the source of this issue for some time, but no luck so far. I just can't reproduce it in any way. Could you attach the output of AccessChk here? .\accesschk64 -lv \.\pipe\discord-ipc-0 when Discord is running. Maybe this will help to locate the problem.

Hello @aiscy, here's the output of AccessChk command that you gave, with discord running:

C:\<dir>\AccessChk>.\accesschk64 -lv \.\pipe\discord-ipc-0

Accesschk v6.15 - Reports effective permissions for securable objects
Copyright (C) 2006-2022 Mark Russinovich
Sysinternals - www.sysinternals.com

No matching objects found.

image

aiscy commented 9 months ago

Could you now try to run .\accesschk64 -lv \.\pipe\discord* from a command line with elevated rights?

edgarcnp commented 9 months ago

Could you now try to run .\accesschk64 -lv \.\pipe\discord* from a command line with elevated rights?

image Discord is running when I executed the command in the terminal

FYI, my previous response is also made from a CMD with elevated rights.

dayo05 commented 9 months ago

Just a comment: Can you give the output of one powershell command

[System.IO.Directory]::GetFiles("\\.\\pipe\\")

This command is for to check what rpc pipe has been opened.

You MUST execute this on powershell, not on cmd

edgarcnp commented 9 months ago

Just a comment: Can you give the output of one powershell command

[System.IO.Directory]::GetFiles("\\.\\pipe\\")

This command is for to check what rpc pipe has been opened.

You MUST execute this on powershell, not on cmd

PowerShell 7.3.6
PS C:\Users\user> [System.IO.Directory]::GetFiles("\\.\\pipe\\")
\\.\\pipe\\InitShutdown
\\.\\pipe\\lsass
\\.\\pipe\\ntsvcs
\\.\\pipe\\Winsock2\CatalogChangeListener-5b8-0
\\.\\pipe\\Winsock2\CatalogChangeListener-734-0
\\.\\pipe\\epmapper
\\.\\pipe\\Winsock2\CatalogChangeListener-568-0
\\.\\pipe\\Winsock2\CatalogChangeListener-768-0
\\.\\pipe\\LSM_API_service
\\.\\pipe\\atsvc
\\.\\pipe\\Winsock2\CatalogChangeListener-8-0
\\.\\pipe\\eventlog
\\.\\pipe\\Winsock2\CatalogChangeListener-cac-0
\\.\\pipe\\asuscert
\\.\\pipe\\NvMessageBusBroadcastNVIDIA.Display.Driver
\\.\\pipe\\PIPE_EVENTROOT\CIMV2SCM EVENT PROVIDER
\\.\\pipe\\srvsvc
\\.\\pipe\\Winsock2\CatalogChangeListener-2328-0
\\.\\pipe\\wkssvc
\\.\\pipe\\trkwks
\\.\\pipe\\WiFiNetworkManagerTask
\\.\\pipe\\tapsrv
\\.\\pipe\\StreamSvcPipe
\\.\\pipe\\vmware-usbarbpipe
\\.\\pipe\\Winsock2\CatalogChangeListener-24d0-0
\\.\\pipe\\vmware-authdpipe
\\.\\pipe\\ROUTER
\\.\\pipe\\NvMessageBusBroadcast3775301276
\\.\\pipe\\Winsock2\CatalogChangeListener-5b0-0
\\.\\pipe\\SystemUsageReportSvc_QUEENCREEK\commands
\\.\\pipe\\NvMessageBusBroadcast
\\.\\pipe\\ProtectedPrefix\LocalService\FTHPIPE
\\.\\pipe\\5638df71-9c7b-4681-9b0e-acb2b192737d
\\.\\pipe\\a5054626-9e04-48a9-bf6c-1985e6f39c1b
\\.\\pipe\\CamingCerter_InUserSessionHelperServer
\\.\\pipe\\SQLLocal\SOLARWINDS_ORION
\\.\\pipe\\MSSQL$SOLARWINDS_ORION\sql\query
\\.\\pipe\\NvWksServiceDdisplayPipe
\\.\\pipe\\BraveSoftwareCrashServices\S-1-5-18
\\.\\pipe\\BraveSoftwareCrashServices\S-1-5-18-x64
\\.\\pipe\\{F685F498-BFDE-49D3-8132-D708F76B990E}
\\.\\pipe\\9EA6F070-37D3-424D-84AB-39C2C9FB0621_1
\\.\\pipe\\dotnet-diagnostic-17664
\\.\\pipe\\dotnet-diagnostic-18320
\\.\\pipe\\dotnet-diagnostic-17876
\\.\\pipe\\dotnet-diagnostic-7016
\\.\\pipe\\LOCAL\mojo.17664.18940.6763271135075678521
\\.\\pipe\\crashpad_18944_GAMGUICGSQDEVGWL
\\.\\pipe\\LOCAL\mojo.18944.19244.5786051128115305229
\\.\\pipe\\LOCAL\mojo.18944.19244.7164954968915882171
\\.\\pipe\\LOCAL\mojo.18944.19244.4056318312766568132
\\.\\pipe\\LOCAL\mojo.18944.19244.9507840586623657636
\\.\\pipe\\LOCAL\mojo.18944.19192.17475195630198491438
\\.\\pipe\\dotnet-diagnostic-18924
\\.\\pipe\\dotnet-diagnostic-20256
\\.\\pipe\\mojo.14300.14264.12634367225800631871
\\.\\pipe\\mojo.14300.17036.4522612382568090630
\\.\\pipe\\uv\FFFFFFFF-14300
\\.\\pipe\\mojo.14300.14264.12366841195295110455
\\.\\pipe\\mojo.14300.17036.12871141434354286847
\\.\\pipe\\uv\00000000-14300
\\.\\pipe\\uv\00000001-14300
\\.\\pipe\\3302a3bb-8dc4-4f74-a5bf-219368af6ec0
\\.\\pipe\\uv\00000002-14300
\\.\\pipe\\uv\00000003-14300
\\.\\pipe\\uv\00000004-14300
\\.\\pipe\\AuraPipe1
\\.\\pipe\\ArmouryCrateDeviceMonitor
\\.\\pipe\\mojo.10260.25012.3995603312255810646
\\.\\pipe\\mojo.10260.25012.10091603468535530069
\\.\\pipe\\crashpad_25568_WWKDYEZYDOCISYEX
\\.\\pipe\\mojo.25568.25632.12389889305801041614
\\.\\pipe\\mojo.25568.25632.14358157538313296478
\\.\\pipe\\mojo.25568.25632.4256490184843583779
\\.\\pipe\\mojo.25568.25632.3729243356572646282
\\.\\pipe\\mojo.25568.25608.7837199925951988666
\\.\\pipe\\mojo.25568.25608.6372498856206575153
\\.\\pipe\\mojo.25568.25608.13048859075188389932
\\.\\pipe\\mojo.10260.25012.5024003133977511594
\\.\\pipe\\mojo.10260.25012.13555495951861196744
\\.\\pipe\\crashpad_26796_NDTWQMOLUZTPBDNQ
\\.\\pipe\\mojo.26796.27000.1437807811489607517
\\.\\pipe\\mojo.26796.27000.9679070919877890933
\\.\\pipe\\mojo.26796.27000.9528549452183121319
\\.\\pipe\\mojo.26796.27000.5390386184879132998
\\.\\pipe\\mojo.26796.26800.204221330249924207
\\.\\pipe\\mojo.26796.27000.15151247035772953299
\\.\\pipe\\mojo.26796.27000.4000275394732480921
\\.\\pipe\\mojo.26796.27000.10858145720355993742
\\.\\pipe\\dotnet-diagnostic-28704
\\.\\pipe\\uv\0000000000000002-29032
\\.\\pipe\\uv\0000000000000003-29032
\\.\\pipe\\uv\0000000000000004-29032
\\.\\pipe\\PSHost.133385050278814594.30228.DefaultAppDomain.Rainmeter
\\.\\pipe\\crashpad_13944_PNOYOUFKVMZZATNW
\\.\\pipe\\mojo.13944.15900.2053000787638071218
\\.\\pipe\\mojo.13944.15900.3336788005811082447
\\.\\pipe\\mojo.13944.15900.16465937418413479803
\\.\\pipe\\mojo.13944.12852.1594486325671931010
\\.\\pipe\\cam-service
\\.\\pipe\\rust-ipc-499b9f3f-d2fe-4688-908c-33ed04bde3f6
\\.\\pipe\\rust-ipc-d0c068ef-09c5-40d3-9f51-29f5091a2c1a
\\.\\pipe\\rust-ipc-c74d5ace-e966-4dd3-ab34-9e5e3f3b5de6
\\.\\pipe\\rust-ipc-fb9fac39-6293-42bf-8cca-48e396225672
\\.\\pipe\\rust-ipc-83ff5648-6e66-4439-9e4f-ca31a927b447
\\.\\pipe\\rust-ipc-470b6857-cde2-4999-a009-cd981b1cbb5b
\\.\\pipe\\rust-ipc-48c99877-348d-439a-b364-b0e8867a2a00
\\.\\pipe\\rust-ipc-2fceedd9-e3e0-484b-b599-615e4c91aa67
\\.\\pipe\\rust-ipc-7a566b9e-1d44-435f-bd12-ceec30db432d
\\.\\pipe\\rust-ipc-63511f31-3660-404d-afb2-3491314c9d40
\\.\\pipe\\rust-ipc-4589d0eb-8cc7-4132-8226-8783b2e2af17
\\.\\pipe\\mojo.13944.12852.4194800700466057894
\\.\\pipe\\ZtJaPqDVSNDmGFDPzbuizsByKmT9NbeEEu2IVrVJa2DMJnHUplMxWjadYnf2IcGRGExh4jDH1v6uzOyhnQzK8V09OOaoXsWK98ljZpg4HApDXb9pJTBs0E
\\.\\pipe\\efsrpc
\\.\\pipe\\ShortcutNotifier_26692
\\.\\pipe\\FTA_26692
\\.\\pipe\\ShellEx_26692
\\.\\pipe\\MsFteWds
\\.\\pipe\\crashpad_14932_FFIIAXSKECOLMIJV
\\.\\pipe\\mojo.14932.34992.14993847498544470637
\\.\\pipe\\mojo.14932.34992.10308672145754058297
\\.\\pipe\\mojo.14932.31260.8929260056033951782
\\.\\pipe\\mojo.14932.31260.1796410962575614729
\\.\\pipe\\mojo.14932.34992.13399436746855165252
\\.\\pipe\\mojo.14932.31260.9207624762279885880
\\.\\pipe\\mojo.14932.31260.18139394010433679413
\\.\\pipe\\mojo.14932.31260.6773373889901212301
\\.\\pipe\\mojo.14932.34992.13895863044861029601
\\.\\pipe\\mojo.14932.31260.7260544165537749035
\\.\\pipe\\mojo.14932.31260.2639184464424576474
\\.\\pipe\\mojo.26796.27000.7700311775128912615
\\.\\pipe\\mojo.26796.27000.9715846241929816178
\\.\\pipe\\mojo.26796.27000.4625261406862240097
\\.\\pipe\\mojo.25568.25632.11740408708158444959
\\.\\pipe\\mojo.25568.25608.242843623864000012
\\.\\pipe\\mojo.25568.25632.6042434563998507640
\\.\\pipe\\mojo.25568.25608.8031615911129534334
\\.\\pipe\\W32TIME_ALT
\\.\\pipe\\chrome.sync.43904.27216.4207965994
\\.\\pipe\\discord-ipc-0
\\.\\pipe\\DiscordHook_Log_0
\\.\\pipe\\mojo.26796.26800.17336738703336589577
\\.\\pipe\\mojo.26796.27000.7871026479192901912
\\.\\pipe\\mojo.26796.27000.11921215820140212792
\\.\\pipe\\mojo.26796.27000.9068073479922767638
\\.\\pipe\\mojo.26796.27000.5776918673112574537
\\.\\pipe\\crashpad_30092_HHIOCWSODQCTNQEB
\\.\\pipe\\LOCAL\mojo.30092.12192.11378587505551672612
\\.\\pipe\\LOCAL\mojo.30092.12192.16225529286750229611
\\.\\pipe\\LOCAL\mojo.30092.15356.10914335439817815653
\\.\\pipe\\LOCAL\mojo.30092.15356.4069926856681291954
\\.\\pipe\\LOCAL\mojo.30092.12192.2034985954833256284
\\.\\pipe\\LOCAL\mojo.30092.15356.4763101394949390363
\\.\\pipe\\LOCAL\mojo.external_task_manager_30092
\\.\\pipe\\DiscordHook_Log_15152
\\.\\pipe\\crashpad_36536_GWNDSATZARNRXWFD
\\.\\pipe\\mojo.36536.41664.9223956598504335066
\\.\\pipe\\mojo.36536.41664.12163804997468591578
\\.\\pipe\\mojo.36536.41664.9258579136464686431
\\.\\pipe\\mojo.36536.41664.18381219169780303636
\\.\\pipe\\mojo.36536.41664.17512883535242113855
\\.\\pipe\\mojo.36536.41664.16494873572163008453
\\.\\pipe\\mojo.36536.41664.10089738182088704834
\\.\\pipe\\mojo.36536.41664.4660924265757610885
\\.\\pipe\\mojo.36536.41664.1321503008511504681
\\.\\pipe\\mojo.36536.1808.1839441176021268404
\\.\\pipe\\mojo.36536.1808.2732708109369891917
\\.\\pipe\\mojo.36536.1808.1485409126898225033
\\.\\pipe\\mojo.36536.41664.13265924441852406683
\\.\\pipe\\mojo.36536.41664.3924162776016766688
\\.\\pipe\\mojo.36536.1808.2795162092733116741
\\.\\pipe\\mojo.36536.1808.13947480986388159799
\\.\\pipe\\mojo.36536.1808.3799173079449509
\\.\\pipe\\mojo.36536.1808.15669114386280505677
\\.\\pipe\\mojo.36536.1808.12915633585173214306
\\.\\pipe\\mojo.36536.1808.8014066974338069373
\\.\\pipe\\mojo.36536.41664.17530654683613496012
\\.\\pipe\\mojo.36536.1808.3988727379731459417
\\.\\pipe\\mojo.36536.1808.7200950632549621250
\\.\\pipe\\mojo.36536.1808.13953546773299241889
\\.\\pipe\\mojo.36536.1808.18408814604044964076
\\.\\pipe\\mojo.36536.1808.6663187030625803180
\\.\\pipe\\mojo.36536.1808.13500458912183270167
\\.\\pipe\\mojo.36536.41664.3052739323277122851
\\.\\pipe\\mojo.36536.1808.10365643342891639029
\\.\\pipe\\mojo.36536.1808.17070708305367965090
\\.\\pipe\\mojo.36536.41664.9925678437649541759
\\.\\pipe\\mojo.36536.41664.7098569688411321634
\\.\\pipe\\mojo.36536.41664.5761722930581242221
\\.\\pipe\\mojo.36536.1808.17842985143659019063
\\.\\pipe\\mojo.36536.1808.9921314743833282542
\\.\\pipe\\mojo.36536.1808.16650593511983153720
\\.\\pipe\\mojo.36536.1808.14532419580533440694
\\.\\pipe\\mojo.36536.1808.4128497702305573428
\\.\\pipe\\mojo.36536.1808.6356236302068999527
\\.\\pipe\\mojo.36536.41664.6300527955305367538
\\.\\pipe\\mojo.36536.1808.3072763791003537742
\\.\\pipe\\mojo.36536.1808.17503249182923544578
\\.\\pipe\\mojo.36536.1808.16610094897540600393
\\.\\pipe\\mojo.36536.1808.10040713891439628927
\\.\\pipe\\mojo.36536.1808.8663677275627788395
\\.\\pipe\\mojo.36536.41664.10981382685578808933
\\.\\pipe\\mojo.36536.1808.8386932486188803571
\\.\\pipe\\mojo.36536.41664.6392869149616824530
\\.\\pipe\\mojo.36536.1808.4510737961713926684
\\.\\pipe\\mojo.36536.1808.14174667030332637349
\\.\\pipe\\mojo.36536.1808.13473067119347059232
\\.\\pipe\\mojo.36536.1808.15524146281373969501
\\.\\pipe\\mojo.36536.1808.9137199567536625312
\\.\\pipe\\mojo.36536.1808.3282739329821789568
\\.\\pipe\\mojo.36536.1808.16670442664573364499
\\.\\pipe\\mojo.36536.1808.5639567995403713451
\\.\\pipe\\mojo.36536.1808.5064792207095622432
\\.\\pipe\\dotnet-diagnostic-39460
\\.\\pipe\\PSHost.133385397419170073.39460.DefaultAppDomain.pwsh
aiscy commented 9 months ago

Could you now try to run .\accesschk64 -lv \.\pipe\discord* from a command line with elevated rights?

image Discord is running when I executed the command in the terminal

FYI, my previous response is also made from a CMD with elevated rights.

Could you also execute .\accesschk64 -lv \pipe\, then find a section that starts with \\.\Pipe\discord-ipc-0 and then copy it here?

edgarcnp commented 9 months ago

Could you now try to run .\accesschk64 -lv \.\pipe\discord* from a command line with elevated rights?

image Discord is running when I executed the command in the terminal FYI, my previous response is also made from a CMD with elevated rights.

Could you also execute .\accesschk64 -lv \pipe\, then find a section that starts with \\.\Pipe\discord-ipc-0 and then copy it here?

\\.\Pipe\discord-ipc-0
  DESCRIPTOR FLAGS:
      [SE_DACL_PRESENT]
      [SE_SELF_RELATIVE]
  OWNER: PC\user
  [0] ACCESS_ALLOWED_ACE_TYPE: NT AUTHORITY\SYSTEM
        FILE_ALL_ACCESS
  [1] ACCESS_ALLOWED_ACE_TYPE: BUILTIN\Administrators
        FILE_ALL_ACCESS
  [2] ACCESS_ALLOWED_ACE_TYPE: PC\user
        FILE_ALL_ACCESS
  [3] ACCESS_ALLOWED_ACE_TYPE: Everyone
        FILE_LIST_DIRECTORY
        FILE_READ_ATTRIBUTES
        FILE_READ_DATA
        FILE_READ_EA
        SYNCHRONIZE
        READ_CONTROL
  [4] ACCESS_ALLOWED_ACE_TYPE: NT AUTHORITY\ANONYMOUS LOGON
        FILE_LIST_DIRECTORY
        FILE_READ_ATTRIBUTES
        FILE_READ_DATA
        FILE_READ_EA
        SYNCHRONIZE
        READ_CONTROL
edgarcnp commented 9 months ago

image Suddenly the plugin works when I open CLion today.