Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: not able to deploy contract at remote server #139

Open
qiuhuiming opened this issue Dec 27, 2021 · 1 comment
Open

Error: not able to deploy contract at remote server #139

qiuhuiming opened this issue Dec 27, 2021 · 1 comment

Comments

@qiuhuiming
Copy link

qiuhuiming commented Dec 27, 2021

I try to set up the quorum network at my remote server using Docker according to "https://github.com/synechron-finlabs/quorum-maker/wik".

In order to access the Web UI, I changed the docker-compose.yml through adding the "ports" argument. For example:

  node1:
    container_name: node1
    image: syneblock/quorum-maker:2.6.0_2.6.5
    working_dir: /node1
    command: ["bash" , "start.sh"]
    volumes:
      - ./node1:/node1
      - ./node1:/home
      - ./node1:/master
    networks:
      vpcbr:
        ipv4_address: 10.50.0.2
    ports:
        - 22002:22004

And then I accessed http:<my_server_ip>:22002 and succeed. However, I failed to upload the contract file.

image

The docker log is like this:

node1    | 2021/12/27 10:08:23 http: panic serving 59.78.44.70:58522: interface conversion: interface {} is nil, not map[string]interface {}
node1    | goroutine 2432 [running]:
node1    | net/http.(*conn).serve.func1(0xc00018e960)
node1    | 	/usr/local/go/src/net/http/server.go:1801 +0x147
node1    | panic(0x8693a0, 0xc00020dce0)
node1    | 	/usr/local/go/src/runtime/panic.go:975 +0x3e9
node1    | github.com/synechron-finlabs/quorum-maker-nodemanager/contractcompiler.Compile(0xc0002b5f00, 0xf, 0xc0001d2cf0, 0x1, 0x1, 0x7ffcaee20f21, 0x16, 0xc000029300, 0xc0000a4240, 0xc0000a41e0, ...)
node1    | 	/go/src/github.com/synechron-finlabs/quorum-maker-nodemanager/contractcompiler/ContractCompiler.go:58 +0xdb1
node1    | github.com/synechron-finlabs/quorum-maker-nodemanager/service.(*NodeServiceImpl).deployContract(0xc000096260, 0xc0001d2cf0, 0x1, 0x1, 0xc0001d2cb0, 0x1, 0x1, 0x0, 0x7ffcaee20f21, 0x16, ...)
node1    | 	/go/src/github.com/synechron-finlabs/quorum-maker-nodemanager/service/NodeService.go:721 +0x307
node1    | github.com/synechron-finlabs/quorum-maker-nodemanager/service.(*NodeServiceImpl).DeployContractHandler(0xc000096260, 0x95f6c0, 0xc00019e620, 0xc00045ac00)
node1    | 	/go/src/github.com/synechron-finlabs/quorum-maker-nodemanager/service/NodeServiceHandler.go:401 +0x712
node1    | net/http.HandlerFunc.ServeHTTP(0xc000096a60, 0x95f6c0, 0xc00019e620, 0xc00045ac00)
node1    | 	/usr/local/go/src/net/http/server.go:2042 +0x44
node1    | github.com/gorilla/mux.(*Router).ServeHTTP(0xc0000be000, 0x95f6c0, 0xc00019e620, 0xc00045a300)
node1    | 	/go/src/github.com/gorilla/mux/mux.go:210 +0xd3
node1    | net/http.serverHandler.ServeHTTP(0xc00019e000, 0x95f6c0, 0xc00019e620, 0xc00045a300)
node1    | 	/usr/local/go/src/net/http/server.go:2843 +0xa3
node1    | net/http.(*conn).serve(0xc00018e960, 0x960840, 0xc000062f40)
node1    | 	/usr/local/go/src/net/http/server.go:1925 +0x8ad
node1    | created by net/http.(*Server).Serve
node1    | 	/usr/local/go/src/net/http/server.go:2969 +0x36c
@qiuhuiming
Copy link
Author

I see what the problem is. My contract file requires different compiler version. I found this by executing this command in the container of node1:

solc --combined-json abi,bin <my_filename>

Then I see the output is not JSON format with the version problem, so this line will panic.

8601CF0EFDD597DE0EC8E3FD7E79150A

I think it is neccesary to handle this exception and gracefully response to the web brower.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant