Closed fubuloubu closed 2 years ago
Vyper's JSON mode has had support for specifying interface codes every since v0.2.1 release. VVM should allow specifying external interfaces so that external dependencies can be compiled.
As far as I can tell, vvm.main:_compile supports **kwargs to pass through to the vyper-json binary: https://github.com/vyperlang/vvm/blob/1c562ed481c62f706a3b70e2e55675874d23f623/vvm/main.py#L118-L123
vvm.main:_compile
**kwargs
vyper-json
What is needed is to add an interfaces: Dict argument to the following two functions so that they can be called with the relevant interfaces added: https://github.com/vyperlang/vvm/blob/1c562ed481c62f706a3b70e2e55675874d23f623/vvm/main.py#L26-L32 https://github.com/vyperlang/vvm/blob/1c562ed481c62f706a3b70e2e55675874d23f623/vvm/main.py#L75-L81
interfaces: Dict
Turns out I completely missed compile_standard which supports interfaces via input_dict
compile_standard
input_dict
Overview
Vyper's JSON mode has had support for specifying interface codes every since v0.2.1 release. VVM should allow specifying external interfaces so that external dependencies can be compiled.
Specification
As far as I can tell,
vvm.main:_compile
supports**kwargs
to pass through to thevyper-json
binary: https://github.com/vyperlang/vvm/blob/1c562ed481c62f706a3b70e2e55675874d23f623/vvm/main.py#L118-L123What is needed is to add an
interfaces: Dict
argument to the following two functions so that they can be called with the relevant interfaces added: https://github.com/vyperlang/vvm/blob/1c562ed481c62f706a3b70e2e55675874d23f623/vvm/main.py#L26-L32 https://github.com/vyperlang/vvm/blob/1c562ed481c62f706a3b70e2e55675874d23f623/vvm/main.py#L75-L81