Giter Club home page Giter Club logo

Comments (22)

anpaz avatar anpaz commented on May 19, 2024 8

@tirdtoon @ayush1999 @desireevl if dotnet-iqsharp works, as a workaround you should be able to run this command to install the kernel:

dotnet-iqsharp install --user --path-to-tool="$(which dotnet-iqsharp)"

Optionally, if there is a Dockerfile in our samples repository that you can use to create a Docker image and get you started. The image is setup you can run Q# from C#/Python/Jupyter.

from iqsharp.

cgranade avatar cgranade commented on May 19, 2024 3

@ayush1999 This can happen sometimes if you haven't restarted your shell since installing the .NET Core SDK. Can you check if ~/.dotnet/tools is on your $PATH? Thanks!

from iqsharp.

ayush1999 avatar ayush1999 commented on May 19, 2024 3

@cgranade Any updates on this?

from iqsharp.

chopinvan avatar chopinvan commented on May 19, 2024 3

I'm trying to follow the guidelines mentioned in https://docs.microsoft.com/en-us/quantum/install-guide/python?view=qsharp-preview to install the iqsharp kernel, but I get a No executable found matching command "dotnet-install" when installing it (using dotnet iqsharp install).

ayush99@ayush99:~/quant$ dotnet tool install -g Microsoft.Quantum.IQSharp
Tool 'microsoft.quantum.iqsharp' is already installed.
ayush99@ayush99:~/quant$ dotnet install iqsharp
No executable found matching command "dotnet-install"

Use this

dotnet iqsharp install --user

Because Jupyter can not run under Sudo mode, but without sudo mode you can not write into Jupyter notebook directory. So, you need to make file writing local

from iqsharp.

cgranade avatar cgranade commented on May 19, 2024

Thanks for the report! It looks like you may have run dotnet install iqsharp instead of dotnet iqsharp install?

from iqsharp.

ayush1999 avatar ayush1999 commented on May 19, 2024

@cgranade I still get the same error:

ayush99@ayush99:~$ dotnet iqsharp install
No executable found matching command "dotnet-iqsharp"

from iqsharp.

ayush1999 avatar ayush1999 commented on May 19, 2024

I manually added it to my path: export PATH="/home/ayush99/.dotnet/tools:$PATH", however I still get the same error. (Which is strange, I can see the executable in my path, not sure why it isn't recognized.)

from iqsharp.

cgranade avatar cgranade commented on May 19, 2024

That is odd, agreed. Typically, when you run a global tool using syntax like dotnet iqsharp, that looks for a dotnet-iqsharp executable. Can you run dotnet-iqsharp --version (with the dash)? If not, if you use the explicit path to the dotnet-iqsharp executable in ~/.dotnet/tools, does that work to run dotnet-iqsharp --version?

from iqsharp.

ayush1999 avatar ayush1999 commented on May 19, 2024

@cgranade I can run dotnet-iqsharp --version:

ayush99@ayush99:~$ dotnet-iqsharp --version
Language kernel: 0.5.1902.2802
Jupyter core: 1.0.0.0

Is there any other possible reason that dotnet iqsharp might not be recognizing the executable?

from iqsharp.

cgranade avatar cgranade commented on May 19, 2024

That's definitely odd, would you be willing to provide some more diagnostic information? Specifically, the output of dotnet --info and platform (e.g.: lsb_release -a from Linux) could be quite useful. Thanks!

from iqsharp.

ayush1999 avatar ayush1999 commented on May 19, 2024

Sure:

ayush99@ayush99:~$ dotnet --info
.NET Core SDK (reflecting any global.json):
 Version:   2.2.105
 Commit:    7cecb35b92

Runtime Environment:
 OS Name:     ubuntu
 OS Version:  18.04
 OS Platform: Linux
 RID:         ubuntu.18.04-x64
 Base Path:   /usr/share/dotnet/sdk/2.2.105/

Host (useful for support):
  Version: 2.2.3
  Commit:  6b8ad509b6

.NET Core SDKs installed:
  2.2.105 [/usr/share/dotnet/sdk]

.NET Core runtimes installed:
  Microsoft.AspNetCore.All 2.2.3 [/usr/share/dotnet/shared/Microsoft.AspNetCore.All]
  Microsoft.AspNetCore.App 2.2.3 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 2.2.3 [/usr/share/dotnet/shared/Microsoft.NETCore.App]

To install additional .NET Core runtimes or SDKs:
  https://aka.ms/dotnet-download


ayush99@ayush99:~$ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 18.04.2 LTS
Release:	18.04
Codename:	bionic

from iqsharp.

tirdtoon avatar tirdtoon commented on May 19, 2024

I have the same problem...on ubuntu 18.04

from iqsharp.

isaacy avatar isaacy commented on May 19, 2024

I ran into this but when I re-ran this nder the Anacorda prompt it worked!

from iqsharp.

ImanRahmanRI avatar ImanRahmanRI commented on May 19, 2024

I have encounter the similar problem. But, in my case I solve it with installed .Net again with the builds apps version that compatible with visual studio 2017

from iqsharp.

cgranade avatar cgranade commented on May 19, 2024

@tirdtoon @ayush1999 @desireevl My apologies, but I haven't been able to reproduce the issue on my end. If you have any other information you provide, I would greatly appreciate it. Are you able to run other .NET Core Global Tools (e.g.: dotnet-cowsay)? Thanks for the help diagnosing this!

from iqsharp.

anpaz avatar anpaz commented on May 19, 2024

Looks like dotnet-iqsharp works, but dotnet iqsharp doesn't work, is that correct @ayush1999?
If so, looks like a problem on how dotnet is findind sub-commands in Ubuntu, looks like in this environment is not looking yet for subcommands in global tools.

@cgranade , do you have any objections if we change the tool name to be just iqsharp? Looking at global tools documentation, that'w how is documented on how to create custom tools.

from iqsharp.

gauss1314 avatar gauss1314 commented on May 19, 2024

@tirdtoon @ayush1999 @desireevl if dotnet-iqsharp works, as a workaround you should be able to run this command to install the kernel:

dotnet-iqsharp install --user --path-to-tool="$(which dotnet-iqsharp)"

Optionally, if there is a Dockerfile in our samples repository that you can use to create a Docker image and get you started. The image is setup you can run Q# from C#/Python/Jupyter.

Thank you, it saved my time! But I want to know how do you find this solution? It is a dotnet bug or jupyter ?

from iqsharp.

sdf94 avatar sdf94 commented on May 19, 2024

I am running into the same issue.
~ SarahsAdventure$ dotnet tool install -g Microsoft.Quantum.IQSharp Tool 'microsoft.quantum.iqsharp' is already installed. ~ SarahsAdventure$ dotnet iqsharp install --user No executable found matching command "dotnet-iqsharp"

from iqsharp.

BrokenDuck avatar BrokenDuck commented on May 19, 2024

Here is the link to a stack exchange post where someone says that this problem may be caused by iqsharp not being supported by .net core 3.1.100. Is this true, if so the documentation, README.md should be updated accordingly.

from iqsharp.

l2learner-devops avatar l2learner-devops commented on May 19, 2024

@anpaz-msft Thanks for your workaround to install the kernel, it worked. Kudos.

from iqsharp.

rmshaffer avatar rmshaffer commented on May 19, 2024

Closing out this old issue, since it appears that solutions or workarounds exist for the problems reported here.

If anyone is having an issue with IQ# kernel installation on recent builds (particularly since March, when support for .NET Core 3.1 was added), please open a new issue with details of your configuration and the error you are hitting. Thank you!

from iqsharp.

rmshaffer avatar rmshaffer commented on May 19, 2024

Also see this issue for details on the underlying problem with adding the global tool path to the system path: dotnet/sdk#9353

from iqsharp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.