Closed jasagredo closed 1 year ago
The following are my notes from the discussion we had about migrating the issues. We also thought to ping MPJ and @abailly-iohk for their thoughts on this issue.
You can click "Transfer issue" to move an issue from one repo to another. The gh
exe also lets you do so programmatically: https://fig.io/manual/gh/issue/transfer
Using that Transfer feature results in several nice behaviors:
The only downside is that occurrences of old issue numbers outside of GitHub metadata cannot be automatically updated.
sed
on eg our code, for example, but there's probably plenty (not the majority, but still plenty) of "#XXX" strings without the ouroboros-network
prefix in the wild old: Slack messages, personal text files, Google Docs, Jira? :grimacing:, etcThe "perfect" scenario would be:
ouroboros-network
was. https://fig.io/manual/gh/issue/comment)The only remaining risk of ambiguity would then be among issues created after the migration: Networking will eventually create a Issue numbered 5000 and so will Consensus too. But that is inevitable (unless we artificially inflate our counts to start at 100000 for new issues etc :grimacing:)
I'd say the biggest risk of that "perfect" plan is if our list of issues to transfer was incomplete. If we missed one during the original attempt, then when we later Transfer it, there's now way for it to end up having the same number in the new repository (because we already "consumed" that number with a "dummy" issue).
I think migrating PRs is less of a concern; there aren't as many of them.
We probably do have commit messages that refer to Issue and/or PR "#30" for example. But there's nothing we can do about that.... except create a dummy Issues (from my above comment) that link to the corresponding ouroboros-network
Issue or PR instead of just being deleted.
These are the two PRs that implement this migration:
I'm closing this as complete. We can always refer back to it.
Since the beginning, the consensus layer of Cardano has co-existed with the network layer. However, as we progress towards a more Open-Source structure, it happens to be a good moment to part sides with the Network layer.
Also, Consensus grew organically into many packages that although they split nicely the functionality in “separate parts”, they become quite difficult to keep in sync. We made the decision to distribute those packages in bundles but that is just an artificial grouping (not completely artificial though) that Cabal doesn’t understand. Therefore problems started appearing as bundles were broken and supposedly impossible situations took place.
So now we took the decision to make a big reorganization and at the same time migrate the code to a new repository.
Structure
The package structure will now be as follows:
ouroboros-consensus
: Contains the core definitions of the Consensus Layer.consensus-testlib
: what previously was the library ofouroboros-consensus-test
mock-block
: definition of a simple mock Ledger for testingtutorials
: toy implementations of Block definitions that implement the necessary typeclasses defined by the Consensus libraryconsensus-test
: what previously was thetest-consensus
test-suite. Tests the Consensus core librarystorage-test
: what previously was thetest-storage
test-suite. Tests our ChainDB implementationmempool-bench
: a benchmark of the time it takes to add transactions to a mempoolouroboros-consensus-protocol
: defines Praos and TPraos protocols which implement the Protocol instances from Consensus. It has a small test sublibrary.ouroboros-consensus-cardano
: defines Blocks for Byron, Shelley and Cardano. In particular this has absorbed all the previous Cardano packages (ouroboros-consensus-(byron|shelley|cardano)
) as well as their test packages, test-suites,ouroboros-consensus-cardano-tools
.ouroboros-consensus-diffusion
: defines the NodeKernel and the booting up sequence for the node, as well as configuration options. It also boots the Network miniprotocols so it is the glue between Consensus and Network. As ThreadNet tests require things from this library, they now live here in several test-suites.The graph of dependencies for the implementation packages is as follows:
This reorganization will impact downstream clients and there will be some time of adaptation.
Steps of the migration