Search Unity

Bug No connection could be made because the target machine actively refused it 127.0.0.1:56776

Discussion in 'Scripting' started by Yerendi, May 30, 2023.

  1. Yerendi

    Yerendi

    Joined:
    Mar 11, 2016
    Posts:
    18
    Hi,
    I have problem with debugging. When I try to attach debugger (localy, normal editor debugging) from Visual Studio 2022 then VS console says: No connection could be made because the target machine actively refused it 127.0.0.1:56776.

    Already tried:
    - reboot PC few times
    - Reinstall Unity, VS
    - Reinstall VS tools from package manager
    - VSCode, Rider (same problem)
    - netstat -ano | findstr :56776, no results
    - setx UNITY_NOPROXY localhost,127.0.0.1
    - fixing C:\Windows\System32\drivers\etc\host
    - disabling antyvir
    - disabling firewall
    - removing library
    - creating new project

    Code Optimization in preferences is set to Debug.
    Do you have any idea what can be wrong?
     
    Last edited: May 31, 2023
    syim likes this.
  2. Yerendi

    Yerendi

    Joined:
    Mar 11, 2016
    Posts:
    18
    I've forced Unity and VS to launch as admin. Unity pops up a warning that it should not be launched as admin, but when ignored everything is working :D