truffle migrate gives cryptic error message when node has no accounts

Created on 7 Jun 2017  路  11Comments  路  Source: trufflesuite/truffle

  • [x] I've asked for help in the Truffle Gitter before filing this issue.

Issue

What the issue is, in broad strokes.

Steps to Reproduce

  • Run new geth instance with no accounts on it
  • Run truffle migrate on some truffle project
    You get:

Expected Behavior

An error message saying "your node has no accounts", or something better

Actual Results

Error: Expected parameter 'from' not passed to function.

Environment

  • Operating System: Ubuntu
  • Truffle version: 3.2.5
  • Ethereum client: geth
  • node version: 8.0.0
  • npm version: 5.0.2
stale

All 11 comments

Hmmm, mine has accounts on it (testrpc) and I also get this issue. Very cryptic indeed. Did adding accounts actually solve it for you?

Seems to be some weird issue in node or something... https://gitter.im/ConsenSys/truffle?at=58d3fbe3caf143ab665362ee

A system restart fixed it for me.

I hit the similar error and fixed it after reinstalling the testRPC.

Having the same problem with active accounts on top of a geth node with rpc turned on. Any idea how else to fix? I read the gitter conversation but restarting has not helped. Tried both node 6 and 7 (via docker image), same result.

I ran into this same issue when running the testrpc. It turned out that I had geth running in another tab (connected to the testnet)... as soon as I stopped geth it was able to migrate without any issue! Hope this saves others - turns out you can't have geth _and_ testrpc running at once (makes sense, really, since both bind to port 8545 and truffle probably doesn't know where you want to migrate to).

Hi all,

I also encountered the issue when running truffle migrate. The error message I have is:

Error: Expected parameter 'solc' not passed to function.

I solved it my introducing a 'solc' entry in truffle.js:

'solc': '/usr/local/bin/solc',

It seems that truffle-expect is checking truffle-config opject and throw error when certain expected key is not found.

HTH

I had the original issue that @maraoz had. It is fixed by opening a geth console and calling personal.newAccount()

This error is due to testrpc being used by a third party instance such as geth or parity and when no accounts are present. To resolve, simply exit/stop these services.

I'm getting this error on Ubuntu 16 running geth with an account created in Ethereum Wallet. Account has been unlocked on geth attach and I can even check the balance. Putting 'from: ' yields a 'Error: unknown account'

Thank you for raising this issue! It has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. If you would like to keep this issue open, please respond with information about the current state of this problem.

There has been no new activity on this issue since it was marked as stale 7 days ago, so it is being automatically closed. If you'd like help with this or a different problem, please open a new issue. Thanks!

Was this page helpful?
0 / 5 - 0 ratings