Holochain-in-Action 8 - Conductor & Sandbox Demo - Basic UI implemented and connected to hApp

In this video we will walk you through:
00:00:00 Intro
00:03:51 What is conductor?
00:13:00 Play with Holochain CLI and Sandbox
00:28:32 Create DNA and hApp bundle
00:36:27 Install and run hApp in Conductor using Sandbox
00:45:17 creating a basic UI project step by step.
01:03:38 connect UI to hApp and call zome function


These sessions are mostly suitable for programmers and designers, so if you would like to participate you need to fill-out this application in advance.

Apply for ā€œHolochain in Actionā€ meetings!

2 Likes

Hi @hedayat i have tried to start the peershare happ. Should the current version in (GitHub - holochain-in-action/peer-share) work?

The sandbox gives me the following error when i press the button in the web UI.

[nix-shell:~/peer-share/holo-layer]$ hc s run -p=8900

Conductor ready.
hc-sandbox: Running conductor on admin port 40627
hc-sandbox: Attaching app port 8900
hc-sandbox: App port attached at 8900
hc-sandbox: Connected successfully to a running holochain
Jun 25 11:05:18.583 ERROR wasm_trace: peershare::__who_am_i_extern:zomes/peershare/src/lib.rs:13 output_type = "core::result::Result<holo_hash::hash::HoloHash<holo_hash::hash_type::primitive::Agent>, holochain_wasmer_common::result::WasmError>"; bytes = [161, 32]; Deserialize("invalid type: string \" \", expected unit")

The webapp seems to run fine and i can open it in the browser:

[nix-shell:~/peer-share/client-basic]$ npm start

> client-basic@1.0.0 start /home/student/peer-share/client-basic
> concurrently --kill-others "npm run build" "npm run serve" 

[0] 
[0] > client-basic@1.0.0 build /home/student/peer-share/client-basic
[0] > webpack --watch
[0] 
[1] 
[1] > client-basic@1.0.0 serve /home/student/peer-share/client-basic
[1] > webpack serve
[1] 
[0] asset index.js 178 KiB [compared for emit] (name: main)
[0] runtime modules 1.13 KiB 5 modules
[0] modules by path ./node_modules/ 149 KiB
[0]   modules by path ./node_modules/@msgpack/msgpack/dist.es5+esm/ 70.8 KiB
[0]     modules by path ./node_modules/@msgpack/msgpack/dist.es5+esm/*.mjs 58.8 KiB 10 modules
[0]     modules by path ./node_modules/@msgpack/msgpack/dist.es5+esm/utils/*.mjs 11.9 KiB 5 modules
[0]   modules by path ./node_modules/@holochain/conductor-api/lib/ 15 KiB
[0]     modules by path ./node_modules/@holochain/conductor-api/lib/api/*.js 1.99 KiB 4 modules
[0]     modules by path ./node_modules/@holochain/conductor-api/lib/websocket/*.js 12.2 KiB 4 modules
[0]     ./node_modules/@holochain/conductor-api/lib/index.js 842 bytes [built] [code generated]
[0]   ./node_modules/buffer/index.js 57 KiB [built] [code generated]
[0]   ./node_modules/base64-js/index.js 3.84 KiB [built] [code generated]
[0]   ./node_modules/ieee754/index.js 2.1 KiB [built] [code generated]
[0]   ./node_modules/isomorphic-ws/browser.js 542 bytes [built] [code generated]
[0] ./src/index.js 1.35 KiB [built] [code generated]
[0] webpack 5.38.1 compiled successfully in 508 ms
[1] ā„¹ ļ½¢wdsļ½£: Project is running at http://localhost:8080/
[1] ā„¹ ļ½¢wdsļ½£: webpack output is served from /dist/
[1] ā„¹ ļ½¢wdsļ½£: Content not from webpack is served from ./dist
[1] ā„¹ ļ½¢wdmļ½£: asset index.js 526 KiB [emitted] (name: main)
[1] runtime modules 1.25 KiB 6 modules
[1] cacheable modules 486 KiB
[1]   modules by path ./node_modules/@msgpack/msgpack/dist.es5+esm/ 70.8 KiB
[1]     modules by path ./node_modules/@msgpack/msgpack/dist.es5+esm/*.mjs 58.8 KiB 10 modules
[1]     modules by path ./node_modules/@msgpack/msgpack/dist.es5+esm/utils/*.mjs 11.9 KiB 5 modules
[1]   modules by path ./node_modules/webpack-dev-server/client/ 20.9 KiB 10 modules
[1]   modules by path ./node_modules/@holochain/conductor-api/lib/ 15 KiB 9 modules
[1]   modules by path ./node_modules/html-entities/lib/*.js 61 KiB 5 modules
[1]   modules by path ./node_modules/url/ 37.4 KiB 3 modules
[1]   modules by path ./node_modules/querystring/*.js 4.51 KiB 3 modules
[1]   modules by path ./node_modules/webpack/hot/ 1.42 KiB
[1]     ./node_modules/webpack/hot/emitter.js 75 bytes [built] [code generated]
[1]     ./node_modules/webpack/hot/log.js 1.34 KiB [built] [code generated]
[1] ./node_modules/webpack/hot/ sync nonrecursive ^\.\/log$ 170 bytes [built] [code generated]
[1] webpack 5.38.1 compiled successfully in 798 ms
[1] ā„¹ ļ½¢wdmļ½£: Compiled successfully.

Any clues that can direct me into the right direction?

1 Like

Hi @wwo

I fixed the bug and pushed the changes to UI. Fetch project and re-run again.

The issue was about Payload. There was extra space in Payload TextBox so always there was an empty string sending to zome function while functions didnā€™t wait for any input parameter.

Thanks for testing and sharing.

1 Like

Thank you for your answer. I just tried it now it works. :smiley: :+1:

1 Like