Solidity: Unknown exception during compilation.

Created on 17 Jun 2016  路  16Comments  路  Source: ethereum/solidity

hi,
i have error for
eth.compile.solidity("contract Test { }");
i have:

solc: exit status 1
Unknown exception during compilation.

    at web3.js:3119:20
    at web3.js:6023:15
    at web3.js:4995:36
    at <anonymous>:1:1
$ solc --version
solc, the solidity compiler commandline interface
Version: 0.3.5-0/RelWithDebInfo-Linux/g++/Interpreter
$ sudo apt-cache policy solc libethereum
solc:
  Install茅聽: 1.2.9~xenial-0ubuntu1
  Candidat聽: 1.2.9~xenial-0ubuntu1
 Table de version聽:
 *** 1.2.9~xenial-0ubuntu1 500
        500 http://ppa.launchpad.net/ethereum/ethereum/ubuntu xenial/main amd64 Packages
        100 /var/lib/dpkg/status
libethereum:
  Install茅聽: 1.2.9~xenial-0ubuntu1
  Candidat聽: 1.2.9~xenial-0ubuntu1
 Table de version聽:
 *** 1.2.9~xenial-0ubuntu1 500
        500 http://ppa.launchpad.net/ethereum/ethereum/ubuntu xenial/main amd64 Packages
        100 /var/lib/dpkg/status

i haven't this problem if use
libethereum_1.2.8-xenial-0ubuntu1_amd64.deb
solc_1.2.8-xenial-0ubuntu1_amd64.deb

$ cat /etc/debian_version 
stretch/sid

$ uname --all
Linux XXX 4.6.0-1-amd64 #1 SMP Debian 4.6.1-1 (2016-06-06) x86_64 GNU/Linux

Most helpful comment

WOHOOO! :-)

All 16 comments

This is a known issue and will be fixed with the next release (it should already be fixed in the develop ppa).

ok thx
i use dev ppa

$ sudo apt-cache policy solc libethereum
solc:
  Install茅聽: 1.2.8-SNAPSHOT--20160612-f169b0d~xenial-0ubuntu1
  Candidat聽: 1.2.8-SNAPSHOT--20160612-f169b0d~xenial-0ubuntu1
 Table de version聽:
 *** 1.2.8-SNAPSHOT--20160612-f169b0d~xenial-0ubuntu1 500
        500 http://ppa.launchpad.net/ethereum/ethereum-dev/ubuntu xenial/main amd64 Packages
        100 /var/lib/dpkg/status
libethereum:
  Install茅聽: 1.2.8-SNAPSHOT--20160612-f169b0d~xenial-0ubuntu1
  Candidat聽: 1.2.8-SNAPSHOT--20160612-f169b0d~xenial-0ubuntu1
 Table de version聽:
 *** 1.2.8-SNAPSHOT--20160612-f169b0d~xenial-0ubuntu1 500
        500 http://ppa.launchpad.net/ethereum/ethereum-dev/ubuntu xenial/main amd64 Packages
        100 /var/lib/dpkg/status

my problem not resolved
and solc_1.2.8-xenial-0ubuntu1_amd64.deb has been deleted in the PPA

any news here?

Many users affected... Any update ?

Will take a look. As a workaround, please use other ways to invoke the compiler, e.g. via the npm package, browser-solidity or by directly invoking solc.

Thanks @chriseth for looking into this!
I would also like to derail this ticket into asking if there is the possibility to keep older versions in the ppa, too? We use solc in testing of pyethereum and being able to pin to an older version right now, would make life a lot easier.

@konradkonrad you are basically requesting a feature for the ppa/apt itself - we do not delete older versions. I think you can use apt to install packages with a specific version instead of the latest.

hey @chriseth !

I think you can use apt to install packages with a specific version instead of the latest.

Yeah, that's what I meant. Usually I find other versions with apt-cache show <pkgname>, and can install versions with apt-get install <pkgname>=<version>. For solc from the ethereum-ppa however, I can only find one version. I have honestly no idea why that is the case though.
Here is an example:

for docker-engine

$ apt-cache show docker-engine|grep Version
Version: 1.11.2-0~wheezy
Version: 1.11.1-0~wheezy
Version: 1.11.0-0~wheezy
Version: 1.10.3-0~wheezy
Version: 1.10.2-0~wheezy
Version: 1.10.1-0~wheezy
Version: 1.10.0-0~wheezy
Version: 1.9.1-0~wheezy
Version: 1.9.0-0~wheezy
Version: 1.8.3-0~wheezy
Version: 1.8.2-0~wheezy
Version: 1.8.1-0~wheezy
Version: 1.8.0-0~wheezy
Version: 1.7.1-0~wheezy
Version: 1.7.0-0~wheezy
Version: 1.6.2-0~wheezy
Version: 1.6.1-0~wheezy
Version: 1.6.0-0~wheezy
Version: 1.5.0-0~wheezy

for solc

$ apt-cache show solc | grep Version
Version: 1.2.9~trusty-0ubuntu1

One more update here:
with the ethereum-dev repository enabled, there is one old version available:

$ apt-cache show solc|grep Version
Version: 1.2.9~trusty-0ubuntu1
Version: 1.2.8-SNAPSHOT--20160612-f169b0d~trusty-0ubuntu1

Unfortunately, the error is in there, too:

$ apt-get install solc=1.2.8-SNAPSHOT--20160612-f169b0d~trusty-0ubuntu1 libethereum=1.2.8-SNAPSHOT--20160612-f169b0d~trusty-0ubuntu1
$ echo "contract Test {}"|solc
Unknown exception during compilation.

Okay, I guess what I want is not possible with a ppa:

Packages you publish in your PPA will remain there until you remove them, they're superseded by another package that you upload or the version of Ubuntu against which they're built becomes obsolete.
https://help.launchpad.net/Packaging/PPA

and sorry for derailing even further...

@chriseth Thanks for looking at this issue. This bug have been breaking tutorials for new users (and many other setups) for the last 10 days - for instance https://github.com/gmtDevs/atom-ethereum-interface/issues/10 .

I guess solidity developers are putting their energy to solve The DAO issues right now, but meanwhile please try to keep stuff working.

I can confirm, that in the ethereum-dev ppa the issue has been fixed, i.e. this longliner will install a working solc SNAPSHOT in a blank ubuntu trusty:

apt-get update && \
apt-get install -y software-properties-common && \
add-apt-repository -y ppa:ethereum/ethereum && \
add-apt-repository -y ppa:ethereum/ethereum-dev && \
apt-get update && \
apt-get install -y solc

this gives:

$ echo "contract Test {}"|solc
$ solc --version
solc, the solidity compiler commandline interface
Version: 0.3.5-0/RelWithDebInfo-Linux/g++/Interpreter
$ apt-cache policy solc
solc:
  Installed: 1.2.9-SNAPSHOT--20160627-c15f818~trusty-0ubuntu1
  Candidate: 1.2.9-SNAPSHOT--20160627-c15f818~trusty-0ubuntu1
  Version table:
 *** 1.2.9-SNAPSHOT--20160627-c15f818~trusty-0ubuntu1 0
        500 http://ppa.launchpad.net/ethereum/ethereum/ubuntu/ trusty/main amd64 Packages
        100 /var/lib/dpkg/status
     1.2.9-SNAPSHOT--20160623-3f03819~trusty-0ubuntu1 0
        500 http://ppa.launchpad.net/ethereum/ethereum-dev/ubuntu/ trusty/main amd64 Packages

you can update xenial ppa?

Is it fixed now, @konradkonrad ?
@codati xenial should be updated now

yes thx

WOHOOO! :-)

Was this page helpful?
0 / 5 - 0 ratings