neighbour-hoods / nh-launcher

Creating a group coherence with holochain apps
Other
4 stars 3 forks source link

Feature/112 hc toolchain update #113

Closed pospi closed 11 months ago

pospi commented 1 year ago

Resolves #112.

Additionally merges the upstream https://github.com/holochain-open-dev/membrane-invitations/ module into the repo, as that project is not planned to be actively maintained moving forward.

pospi commented 1 year ago

Executing, but there are API changes in Membrane Invitations to update for. Probably a few other runtime API changes to work through, but getting close.

pospi commented 1 year ago

Major frontend updates afoot for new @holochain-open-dev modules and lit-svelte-stores API updates.

At present 2aeb5f2 is a start and a7d0352 cleans up some unnecessary complexity. There may be more that can / should be streamlined.

In neightbourhood-home.ts, provideWeGroupInfo remains a sortof "adapter" function around the old behaviour which binds a store to a Promise. To me this does feel like a problem with the internal consistency of the MatrixStore API, since fetchWeGroupInfo is a fire-once function which always returns a new Readable store.

The component is firing this side-effect when its StoreSubscriber is first instantiated, effectively operating as a connectedCallback.

Perhaps a cleaner API would be if MatrixStore were to internally cache its NeighbourhoodInfos in a store, and fetchWeGroupInfo simply caused an updated value to be published through that store.

We could then split this out more, and make it more idiomatic Lit.

pospi commented 1 year ago

Oh, I should point out that I am waiting on https://github.com/holochain-open-dev/membrane-invitations/pull/3 before others can test. In the meantime you can build Membrane Invitations yourself on the for-hdk-v0.2.2 branch and pnpm link /path/to/membrane-invitations/ui from the /ui/app directory in this repo.

pospi commented 1 year ago

Invitations related screens now appear to be mostly working, the next set of errors involves the Profiles module.

pospi commented 12 months ago

Upon further investigation the peer signaling issues seem to be inherent to Holochain itself (or some misconfiguration thereof), and not to do with the Invitations zome.

Use of hc sandbox also seems fine with network mem? Not sure. I can't find any working examples in other projects to learn from, and the official Holochain scaffolding tools generated outdated code for the 0.1.x release series.

As best I can figure, signals between peers just aren't getting through.

pospi commented 12 months ago

Aside from these issues, the upgrade appears to be mostly complete. Still to do:

pospi commented 12 months ago

According to some internal knowledge from @adaburrows Holochain core is currently experiencing bugs with peer signals, so we can probably merge this for now and wait for the next release?

The first bullet in the above issue will still cause an error when those 'refresh' buttons are clicked, but given the situation I think that is advantageous to future devs as it means the current state of the system will be more easily surfaced.

pospi commented 12 months ago

Ok so more upstream blockers and two paths forward that I can see:

Option 1: merge now, pursue Holochain 0.3 update later

Option 2: pursue Holochain 0.3 update now as part of this issue

I will fork these repos and keep working on them for now- if we decide to split out the work we can always rebase related commits out.

adaburrows commented 11 months ago

Holochain 0.3 itself is currently on weekly dev builds, which may be unstable. Based on past experience, a force pinned Serde version like I'm seeing in other repos is somewhat of an indicator of instability.

This is because a version change caused backwards incompatible changes in the serialization format, I assume they are doing this in order to make sure that same problem doesn't happen again. But we'd likely need to ask to make sure this is about the chatter I saw about that earlier.

adaburrows commented 11 months ago

Can we talk through this when you wake up and are ready to work? I don't have enough detail from your comments.

adaburrows commented 11 months ago

Updated scripts to configure a completely local WebRTC network.

pospi commented 11 months ago

Tested and working for multi-peer neighbourhoods. There may be lingering Applet installation bugs but we won't know until we can test with a compatible Applet binary.

Ready to merge! :partying_face: