Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error encountered while installing disco environment in Windows #172

Open
ann-sherin opened this issue Jan 26, 2023 · 6 comments
Open

Error encountered while installing disco environment in Windows #172

ann-sherin opened this issue Jan 26, 2023 · 6 comments

Comments

@ann-sherin
Copy link
Collaborator

Expected behavior
DISCO environment should be installed when running command:
pip install NREL-disco

Actual behavior
Installation fails with error:
Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/

To Reproduce
Steps to reproduce the behavior:

  • Open Anaconda prompt (or any command line window on Windows)
  • Follow installation steps as shown here (https://nrel.github.io/disco/installation.html). Error is encountered at the step where we run the command pip install NREL-disco

Additional context

@daniel-thom
Copy link
Collaborator

@ann-sherin I know this is frustrating, but there's not much we can do about it. I've seen this error and the user gets a very clear message that says, "go to this link and install this software." Do you have any suggestions? It's possible that if all dependent packages are stored in conda, we could avoid the need to build. But we have so many 3rd-party dependencies, I'm not even sure that would work.

@ann-sherin
Copy link
Collaborator Author

You are right. It usually is pretty clear on what the issue is. And is easy to fix by going to the link and installing.

My sense is that for this particular issue - it would not work at all on Windows if we don't have the Microsoft Build Tools software installed. (which is a pretty big install ~9GB). Because it was such a big install, I wasnt sure if I should install it or try to find a work around
And so is this something that we should mention in the documentation or someplace (faqs)?
Note: I dont know how generalizable this issue is - like do other Windows users face this too....

I just wanted to make a note of this issue in case someone else faces this.

@bpalmintier
Copy link
Collaborator

Perhaps it's worth adding the need to have Microsoft build tools installed (for Windows--maybe something similar for Mac or other?) to the DISCO installation notes?

@ppaudyal-nrel
Copy link

Following up on this issue, I encountered the same error while installing Disco on Windows. I followed the process of installing Microsoft build tools, however, I still get the error "ERROR: Could not build wheels for multidict, which is required to install pyproject.toml-based projects"
I get the error for this step : pip install -e .
Attached is the snippet of the error that I see. Could you please help with this issue @daniel-thom @ann-sherin ?
error_installing_disco_1
error_installing_disco_2

@daniel-thom
Copy link
Collaborator

@ppaudyal-nrel It seems like your installation of the MS Build Tools did not work.

The cause of this issue is this chain of dependences: disco -> pydss -> aiohttp -> multidict. Disco users (and most pydss users) do not need aiohttp, so I've opened a PR in PyDSS to remove this requirement: NREL/PyDSS#120

Here are your options:

  • Wait for a new version of PyDSS (1-3 business days, most likely).
  • Try to figure out why the MS Build Tools didn't work.
  • Clone the PyDSS repository locally, remove the aiohttp* dependencies, either manually or by checking out the branch in my PR, then install PyDSS locally through pip install -e <path-to-your-pydss-repo>. There will no longer be a dependency on multidict.
  • Install disco through pip.

@daniel-thom
Copy link
Collaborator

A workaround for this issue is to install multidict through conda and then install disco.

conda install -c conda-forge multidict

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants