consensus-shipyard / ipc

🌳 Spawn multi-level trees of customized, scalable, EVM-compatible networks with IPC. L2++ powered by FVM, Wasm, libp2p, IPFS/IPLD, and CometBFT.
https://ipc.space
Apache License 2.0
44 stars 39 forks source link

Solidify this repo #512

Closed raulk closed 10 months ago

raulk commented 10 months ago

At last, the IPC codebase is in a monorepo -- and the build and CI both work! This issue tracks a bunch of follow-ups to solidify the structure and usage of this repo.

Repos cleanup

Build and CI

Non-code reorg

Code reorg

Here's a concrete code tree proposal, let's discuss in comments.

/
|__ infra
|__ docs
|__ contracts
|__ cli # binary crate containing the ipc cli
|
|__ ipc
| |__ wallet # former ipc/identity; this is a wallet library containing keystores, key types, wallet, etc.; using the opportunity to adjust naming to be more descriptive
| |__ provider
| |__ api # former ipc/sdk; these contain external IPC API types; SDK tends to imply "developer SDK", which this isn't
| |__ types # former fvm-utils/primitives; these contain basic types; some may move to ipld/types (e.g. Hamt, Cid, etc.)
|
|__ ipld
| |__ resolver # ipld-resolver
|
|__ fendermint
| |__ abci
| |__ app
| |__ crypto
| |__ ...
|
|__ testing # former ipc/testing, to be refactored later

Update infra scripts

Some infra scripts are outdated, e.g. the current ipc/scripts/install_infra.sh still clones fendermint. Need to figure these out in detail.

aakoshh commented 10 months ago

types # former fvm-utils/primitives; these contain basic types; some may move to ipld/types (e.g. Hamt, Cid, etc.)

I agree that they aren't ipc specific. Where to put this was exactly my question when I first suggested this in https://github.com/filecoin-project/builtin-actors/issues/489

ipld/types sounds better to me, although we should clean up the error types to remove references to fil_actor_runtime, which was one of the reasons I never imported these, even though we could use it in fendermint_vm_actor_interfaces for example.

fridrik01 commented 10 months ago

@raulk What do you mean with "Restore the correct name for the Fendermint Docker image"? Not sure I know exactly what that details

jsoares commented 10 months ago

consensus-shipyard/ipc (rename to ipc-libs first, to free up the ipc name)

Note that this will break old issue referencing (i.e. if there's something in the newipc-monoreporeferencingipc#21`, GH won't be able to redirect and will instead link to a wrong issue). I agree it's the right thing to do, mind you, just something to keep in mind. If we really wanted to preserve this, we should rewrite references first, but it's probably not worth it.

Unrelated: I also went ahead and closed the old GitHub projects, given the move to Linear.