full-blockchain-solidity-course-py icon indicating copy to clipboard operation
full-blockchain-solidity-course-py copied to clipboard

Solc problem from lesson 4. I keep getting this when i run the code using python deploy.py I'm using windows 10, don't know if that's the problem, please help i've been on this for 3 days. I've added this line: install_solc("0.6.0").

Open oloridama opened this issue 2 years ago • 13 comments

Traceback (most recent call last): File "C:\Users\3\demos\web3_py_simple_storage\deploy.py", line 6, in install_solc(_solc_version) File "C:\Users\3\AppData\Local\Programs\Python\Python39\lib\site-packages\solcx\install.py", line 466, in install_solc raise exc File "C:\Users\3\AppData\Local\Programs\Python\Python39\lib\site-packages\solcx\install.py", line 459, in install_solc _validate_installation(version, solcx_binary_path) File "C:\Users\3\AppData\Local\Programs\Python\Python39\lib\site-packages\solcx\install.py", line 636, in _validate_installation raise SolcInstallationError( solcx.exceptions.SolcInstallationError: Downloaded binary would not execute, or returned unexpected output.

oloridama avatar Jun 10 '22 17:06 oloridama

having the same issue here. It worked fine on windows 8.1 but when i shifted to windows 10 it gives the same error

taaha161 avatar Jun 13 '22 17:06 taaha161

having the same issue here. It worked fine on windows 8.1 but when i shifted to windows 10 it gives the same error

Did you find a way around it? Cause I'm stuck, I may skip the lesson to lesson 5

oloridama avatar Jun 13 '22 18:06 oloridama

having the same issue here. It worked fine on windows 8.1 but when i shifted to windows 10 it gives the same error

Did you find a way around it? Cause I'm stuck, I may skip the lesson to lesson 5

Still haven't found a way around it. I dont think just skipping to lesson 5 would be a good idea because we cannot work with python if we cant install the solidity compiler. I wonder if someone could get Patrick to respond this

taaha161 avatar Jun 13 '22 18:06 taaha161

having the same issue here. It worked fine on windows 8.1 but when i shifted to windows 10 it gives the same error

Did you find a way around it? Cause I'm stuck, I may skip the lesson to lesson 5

Still haven't found a way around it. I dont think just skipping to lesson 5 would be a good idea because we cannot work with python if we cant install the solidity compiler. I wonder if someone could get Patrick to respond this

I just tagged him on Twitter, hopefully he'll take a look

oloridama avatar Jun 14 '22 08:06 oloridama

Problem solved by installing node.js and after which I ran in terminal "npm install -g solc" Code finally ran!!

oloridama avatar Jun 15 '22 16:06 oloridama

Problem solved by installing node.js and after which I ran in terminal "npm install -g solc" Code finally ran!!

Download node.js for windows here https://nodejs.org/en/

oloridama avatar Jun 15 '22 17:06 oloridama

Problem solved by installing node.js and after which I ran in terminal "npm install -g solc" Code finally ran!!

FINALLY! You are a genius! I wonder what the issue was installing it with pip though?

taaha161 avatar Jun 15 '22 18:06 taaha161

Yeah pip is a management system that installs packages written in python and found in python package index

oloridama avatar Jun 15 '22 19:06 oloridama

I was having the same issue. I installed the solc compiler from npm. Did you add it somewhere in the brownie-config.yaml file?

kriti0102 avatar Oct 06 '22 16:10 kriti0102

I was having the same issue. I installed the solc compiler from npm. Did you add it somewhere in the brownie-config.yaml file?

Nope! Didn't add to config. I just installed node.js first to my windows machine before installing solc globally from npm.

oloridama avatar Oct 06 '22 16:10 oloridama

Ok so how did brownie know which solc compiler to use?

kriti0102 avatar Oct 06 '22 17:10 kriti0102

Ok so how did brownie know which solc compiler to use?

Have you added this line to your deploy script? from solcx import compile_standard, install_solc

oloridama avatar Oct 06 '22 17:10 oloridama

Ok so how did brownie know which solc compiler to use?

Click here to view the updated deploy script and compare with yours.

oloridama avatar Oct 06 '22 17:10 oloridama