0

I have been researching this issue for hours now but none of the solutions have worked so far.

I have followed the various instructions in this post, but none of them worked: An error occurred attempting to determine the process id of dotnet.exe which is hosting your application. One or more error occured

Here is what my current launchSettings look like:

{
  "iisSettings": {
    "windowsAuthentication": true,
    "anonymousAuthentication": true,
    "iisExpress": {
      "applicationUrl": "http://localhost:51763/",
      "sslPort": 44324
    }
  },
  "profiles": {
    "IIS Express": {
      "commandName": "IISExpress",
      "launchBrowser": true,
      "environmentVariables": {
        "ASPNETCORE_ENVIRONMENT": "Development"
      }
    },
    "HydroAuth.Admin": {
      "commandName": "Project",
      "launchBrowser": true,
      "environmentVariables": {
        "ASPNETCORE_ENVIRONMENT": "Development"
      },
      "applicationUrl": "http://localhost:51764/"
    }
  }
}

What have I tried so far?

  • Deleted the localhost certificates via Manage user certificates.
  • Launched the app successfully in CTRL+F5 which has worked and I managed to reinstall the certificates: enter image description here
  • Disabled SSL which just broke everything, re-enabled it but still doesn't debug.
  • Looked at the IIS config but there was nothing out of the ordinary there, port 44324 was enabled.
  • Multiple VS restarts and PC restarts.

Questions

  • Am I missing something obvious?
  • Any other settings to check?

Restrictions

  • Due to how the previous developer set the project up I am unable to mess with the port number as they are saved somewhere on a db that checks against them.
  • Running the project without IIS Express results in a de-authentication through Microsoft OAuth.

Thank you for any advice in advance!

BenjaminD
  • 29
  • 1
  • 7

1 Answers1

0

There is a workaround, it's not very clean but does the job for now.

I hope if anyone else runs into this issue may find this useful.

  1. Step one is to run the project without debug like before.
  2. In VS head to (top toolbar) Debug>Attach to Process... enter image description here
  3. Find dotnet.exe and click Attach. enter image description here

This should allow you to debug the code, it might not work as well as native debug, but for now it will have to do.

BenjaminD
  • 29
  • 1
  • 7