Skip to content

Cannot deploy walk2earn.wasm in the w3bstream node #4

@tw0l1

Description

@tw0l1

Hello All,

I wanted to play around with walk2earn example so I deployed my own local w3bstream node and compiled the walk2earn binary. But when I try to deploy it in the w3bstream project I get the following error related to incompatible ws_call_contract function definition.

a:panic: incompatible import type for env::ws_call_contract Caused by: function types incompatible: expected func of type (i32, i32, i32, i32) -> (i32), found func of type (i32, i32, i32, i32, i32) -> (i32); calltrace:goroutine 628 [running]: runtime/debug.Stack() /usr/local/go/src/runtime/debug/stack.go:24 +0x65 github.com/machinefi/w3bstream/pkg/depends/kit/sqlx.Task.Run.func1() /w3bstream/pkg/depends/kit/sqlx/tx_task.go:17 +0x7a panic({0x18cb780, 0xc0004c2490}) /usr/local/go/src/runtime/panic.go:884 +0x212 github.com/machinefi/w3bstream/pkg/modules/vm.NewInstance({0x1b23840, 0xc0005d6150}, {0xc0002948e0, 0x1e}, 0xc0001190f0?) /w3bstream/pkg/modules/vm/instance_new.go:25 +0x1fa github.com/machinefi/w3bstream/pkg/modules/deploy.CreateInstance.func4({0x1b28100?, 0xc00038bf00?}) /w3bstream/pkg/modules/deploy/deploy.go:66 +0x38 github.com/machinefi/w3bstream/pkg/depends/kit/sqlx.Task.Run(0x1b22ff0?, {0x1b28100?, 0xc00038bf00?}) /w3bstream/pkg/depends/kit/sqlx/tx_task.go:20 +0x72 github.com/machinefi/w3bstream/pkg/depends/kit/sqlx.(*Tasks).Do(0xc000564d88) /w3bstream/pkg/depends/kit/sqlx/tx_task.go:61 +0x20a github.com/machinefi/w3bstream/pkg/modules/deploy.CreateInstance({0x1b23840, 0xc0005a3a10}, 0xc0003afbb8) /w3bstream/pkg/modules/deploy/deploy.go:68 +0x5a5 github.com/machinefi/w3bstream/cmd/srv-applet-mgr/apis/deploy.(*CreateInstance).Output(0xc0003afbb0, {0x1b23840, 0xc0005a3410}) /w3bstream/cmd/srv-applet-mgr/apis/deploy/pos.go:28 +0xa9 github.com/machinefi/w3bstream/pkg/depends/kit/httptransport.(*RouteHandler).ServeHTTP(0xc00069b770, {0x1b20ff0, 0xc0000ae280}, 0xc0006f7800) /w3bstream/pkg/depends/kit/httptransport/route_handler.go:86 +0x7f6
...

w3bstream deploy yaml:
..
w3bapp:
image: ${WS_BACKEND_IMAGE:-ghcr.io/machinefi/w3bstream:v1.0.0}
..
w3bstream-studio:
image: ${WS_STUDIO_IMAGE:-ghcr.io/machinefi/w3bstream-studio:v1.0.2}

Is the example outdated?

Best regards,
Tomek

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions