trufflesuite / truffle

:warning: The Truffle Suite is being sunset. For information on ongoing support, migration options and FAQs, visit the Consensys blog. Thank you for all the support over the years.
https://consensys.io/blog/consensys-announces-the-sunset-of-truffle-and-ganache-and-new-hardhat?utm_source=github&utm_medium=referral&utm_campaign=2023_Sep_truffle-sunset-2023_announcement_
MIT License
14.02k stars 2.32k forks source link

Truffle does not forward solidity compilation errors #513

Closed Gustav-Simonsson closed 7 years ago

Gustav-Simonsson commented 7 years ago

Issue

Truffle does not forward solidity compilation errors to the user.

Steps to Reproduce

Create a contract which assigns a value to a variable, then remove the '=' character in the assignment.

Expected Behavior

truffle compile
contracts/mesh.sol:78:18: Error: Expected token Semicolon got 'Identifier'
    uint deposit nodeIdents[msg.sender].deposit;

Actual Results

truffle compile
Compiling ./contracts/mesh.sol...
5
5

/usr/local/lib/node_modules/truffle/node_modules/solc/wrapper.js:48
        throw e;
        ^
abort(5) at Error
    at jsStackTrace (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:1:19718)
    at stackTrace (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:1:19901)
    at abort (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:19:15285)
    at Array.dXb (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:11:585101)
    at Array.tX (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:8:557453)
    at Array.eea (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:6:495332)
    at Object.wOb [as dynCall_ii] (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:11:540050)
    at invoke_ii (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:1:1275129)
    at Array.ixa (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:7:494308)
    at Object.bVb [as dynCall_viii] (/usr/local/lib/node_modules/truffle/node_modules/solc/soljson.js:11:577232)
If this abort() is unexpected, build with -s ASSERTIONS=1 which can give more information.

Environment

tcoulter commented 7 years ago

Hi there.

This issue has been fixed. It was a bug in Solidity! To get the update, upgrade Truffle to the latest version.

Thanks for writing!