solcjs --standard-json - TypeError: Second argument needs to be a buffer
See original GitHub issueHello,
solcjs --standard-json myinput.json
doesn’t work. See the error bellow.
$ echo "{}" | solcjs --standard-json
/usr/local/lib/node_modules/solc/node_modules/graceful-fs/polyfills.js:144
throw er
^
TypeError: Second argument needs to be a buffer
at Object.fs.readSync (fs.js:681:18)
at Object.readSync (/usr/local/lib/node_modules/solc/node_modules/graceful-fs/polyfills.js:138:28)
at Object.<anonymous> (/usr/local/lib/node_modules/solc/solcjs:65:18)
at Module._compile (module.js:569:30)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:503:32)
at tryModuleLoad (module.js:466:12)
at Function.Module._load (module.js:458:3)
at Function.Module.runMain (module.js:605:10)
at startup (bootstrap_node.js:158:16)
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:12 (6 by maintainers)
Top Results From Across the Web
ethereum/solidity - Gitter
Hi, I am using truffle and I have developed two contracts. The second contract needs the address of the first contract as input....
Read more >Using the Compiler — Solidity 0.8.17 documentation
The process will always terminate in a “success” state and report any errors via the JSON output. The option --base-path is also processed...
Read more >Solidity Documentation - Read the Docs
docker run ethereum/solc:stable --standard-json < input.json > output.json ... vous devriez forker Solidity et ajouter votre fork comme un second dépot.
Read more >Code not compiling in nodejs,throws out an unexpected error ...
In my case the problem was that the File.sol was raw solidity smart contract, but you need to put Compiler Standard Input JSON...
Read more >Documentation - Ethers.js
They offer a standard JSON-RPC interface and have fairly high capacity without the ... A second optional parameter allows API keys to be...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@axic i tried to fix the tests here https://github.com/ethereum/solc-js/pull/229, would love to be a be able to use standard jsons 😄 thanks
@axic , what’s your disposition on this issue and the proposed fix?
I’m using the changes from @tzapu 's PR #229 , which seem to include your own changes as well, and it’s all working for my purposes.
I’d love to see the fix merged into master so that I can go into production with my own development that’s depending on it, and I see @snd and others are waiting on it as well.
Are there any reservations you have? Is there anything we can do to help facilitate?