question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Invalid option to --combined-json: clone-bin

See original GitHub issue
  • py-solc Version: 3.0.0
  • solc Version: 0.5.0
  • Python Version: 3.5.3
  • OS: Linux debian 9

What was wrong?

solc does not take the system argument “–combined-json” and returns an error “Invalid option to --combined-json: clone-bin”


tried like this: https://stackoverflow.com/questions/50238914/py-solc-and-solidity-imports

root@debian9:~dev/eth/# solc --version    
solc, the solidity compiler commandline interface                                    
Version: 0.5.0-develop.2018.10.17+commit.72b1bb00.mod.Linux.g++    

root@debian9:~dev/eth/# python3.5       
Python 3.5.3 (default, Sep 27 2018, 17:25:39)                                      
[GCC 6.3.0 20170516] on linux                                                      
Type "help", "copyright", "credits" or "license" for more information.             
>>> import os
>>> from solc import compile_files
>>> PROJECT_ROOT = os.getcwd()
>>> compiled_sol = compile_files([os.path.join(PROJECT_ROOT, "bar.sol"), os.path.join(PROJECT_
ROOT, "baz.sol")])                                                                            
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.5/dist-packages/solc/main.py", line 135, in compile_files
    stdoutdata, stderrdata, command, proc = solc_wrapper(**compiler_kwargs)
  File "/usr/local/lib/python3.5/dist-packages/solc/utils/string.py", line 85, in inner
    return force_obj_to_text(fn(*args, **kwargs))
  File "/usr/local/lib/python3.5/dist-packages/solc/wrapper.py", line 165, in solc_wrapper
    stderr_data=stderrdata,
solc.exceptions.SolcError: An error occurred during execution
> command: `solc --combined-json abi,asm,ast,bin,bin-runtime,clone-bin,devdoc,interface,opcode
s,userdoc /root/dev/eth/bar.sol /root/dev/eth/`
> return code: `1`
> stderr:

> stdout:
Invalid option to --combined-json: clone-bin

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:13

github_iconTop GitHub Comments

14reactions
Chiheb-Nexuscommented, Jan 21, 2019

The solution to this problem is:

  • Remove any solc version < 0.4.25: If you’re using Debian/Ubuntu just run: sudo apt-get remove solc
  • Under your virtualenv run: pip install py-solc then python -m solc.install v0.4.25 Now you’ve solc compiler installed under your: $HOME/.py-solc/solc-v0.4.25/bin/solc, all you need to do now is make solc available just by typing it’s name in the terminal. You nned to copy you’re solc file to /usr/bin or /usr/local/bin: cp $HOME/.py-solc/solc-v0.4.25/bin/solc /usr/local/bin/

And you’ll endup with the correct solc version and you’ll not have this error.

2reactions
dbecommented, Dec 3, 2018

From the patch notes of Solidity 5.0: Link

“The --clone-bin and --combined-json clone-bin command line options were removed.”.

Seems like you will have to downgrade your solc version until py-solc changes it’s use of --combined-json clone-bin.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Merge JSON files JSONDecodeError - Stack Overflow
Goal: Merge JSON files into one big file ; Background: I am using the code below taken from here Issue with merging multiple...
Read more >
jsonmerge - PyPI
This Python module allows you to merge a series of JSON documents into a single one. This problem often occurs for example when...
Read more >
OPENJSON (Transact-SQL) - SQL Server - Microsoft Learn
Use OPENJSON to import JSON data into SQL Server, or to convert JSON data ... Without this option, if the property can't be...
Read more >
CopyWebpackPlugin | webpack
If you want to copy files in directory you need use dir option. We try to automatically determine the type so you most...
Read more >
2 Ways to Merge Arrays in JavaScript | SamanthaMing.com
Alternative Concat Syntax; Difference between Spread vs Concat. Example: Dealing with an arbitrary argument. Merge Array with Push; Browser Support ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found