Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to install/use dotnet framework.

See original GitHub issue

Related to #27

I am having this same issue OliverRC was having in the previous issue. We have kind of a weird configuration though:

We are setting up docker containers that will work as build agents using the teamcity docker image. We’re installing some dependencies inside of that container, one of them being autorest.

autorest seems to install correctly but upon invoking it during a dotnet build, we receive the following:

EXEC : error : Package '' - '2.0.367' failed to install: [/root/git/services/Api/Api.Client.csproj]
    dotnet-2.0.0@1.4.4 postinstall: node -e "/*PostInstall: Installs platform-specific .NET framework */try{require('./dist/app.js')}catch(e){}"
  Exit status 1

The real issue seems to be during the post install script for the dotnet-2.0.0 package, so this might be better suited for that github repo.

Node version: 8.11.3 npm version: 5.7.0 OS: Ubuntu 16.04

installing dotnet-2.0.0 directly throws the same error.

I have attempted @fearthecowboy’s recommendation from the previous issue and installed autorest globally and ran autorest --reset

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

csingecommented, Aug 23, 2018

I had this similar issue on Windows and fixed it by

  • removing dotnet core 2.0 runtime (since I had the 2.1 SDKs anyways)
  • Removed autorest via npm and then used yarn instead

npm remove -g autorest

My project setup look like this

  "scripts": {
    "postinstall": "./node_modules/.bin/autorest --reset",
    "start": "./node_modules/.bin/autorest --clear-output-folder --input-file=http://localhost:51462/swagger/v1/swagger.json --csharp --output-folder=autogen/csharp --namespace=Test.Utils"
  "dependencies": {
    "autorest": "^2.0.4280"
disophisiscommented, Sep 6, 2018

Weirdly, going down the yarn route has worked out for me. It seems that I had an npmrc folder in /usr/etc. Deleting that directory seems to have fixed things. I’m not sure why that directory being there was causing problems, though. Yarn’s --verbose switch is what led to me discovering that.

Prior to deleting the directory, I tried setting permissions on it, but it didn’t seem to make any difference.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshoot blocked .NET Framework installations and ...
The most likely cause of this message is that a preview or RC version of the .NET Framework was installed. Uninstall the preview...
Read more >
dispatch-cli: Unable to install/use dotnet framework #1352
Installed the .NET Core Runtime via the Visual Studio Installer. When running npm install -g botdispatch , it throws an error on the...
Read more >
Troubleshooting: Installing .NET Framework 3.5
First, you can check if the component is already installed on your device. Go to Control Panel > Programs > Turn Windows features...
Read more >
Unable to install .NET Framework 3.5 on Windows 10 computer
Open the start menu. · Type in "Windows Features" and press Enter. · Select the ".NET Framework 3.5" check box. Windows Features ·...
Read more >
Can not install "npm install -g botdispatch" on Azure app ...
I was trying to install botdispatch npm module as a part of bot framework 4 on Azure app service on Linux and I...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found