Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spec migration #796

Merged
merged 23 commits into from
Mar 16, 2023
Merged

Spec migration #796

merged 23 commits into from
Mar 16, 2023

Conversation

adlerjohn
Copy link
Member

@adlerjohn adlerjohn commented Sep 27, 2022

Ref: #650

Staging branch for specs migration. Draft PR so it can be tracked.

@adlerjohn adlerjohn added the specs directly relevant to the specs label Sep 27, 2022
@adlerjohn adlerjohn self-assigned this Sep 27, 2022
Fixes #792

An initial migration of the existing specs as of
[`e59efd63a2165866584833e91e1cb8a6ed8c8203`](https://github.com/celestiaorg/celestia-specs/tree/e59efd63a2165866584833e91e1cb8a6ed8c8203).
It's expected that there are a few broken links and extra content that
has to be pruned, along with incorrect content. The important thing is
to not miss anything.

Also sets up a CI workflow that will build the book.
@rootulp
Copy link
Collaborator

rootulp commented Sep 28, 2022

hmm I can't merge main into this branch

Screen Shot 2022-09-28 at 2 55 15 PM

I wanted to merge main to pick up the new CODEOWNERS file

@musalbas
Copy link
Member

What's the status of this?

@rootulp
Copy link
Collaborator

rootulp commented Nov 1, 2022

@musalbas apologies for delayed response. @adlerjohn and I triaged issues in #650 today.

I think that the specs-staging branch is already a more accurate representation of the specs than https://celestiaorg.github.io/celestia-specs/latest/index.html so I'd like to merge specs-staging to main ASAP. But if we want to block this merge on updating specs to match the existing implementation, we can block on all the issues in the "Pure specs" section.

rootulp and others added 6 commits November 24, 2022 15:40
Closes #883

Co-authored-by: CHAMI Rachid <chamirachid1@gmail.com>
Part of #1153

Should only be merged if
#1181 is merged
Closes #1120

Co-authored-by: John Adler <adlerjohn@users.noreply.github.com>
Closes #1151

Co-authored-by: John Adler <adlerjohn@users.noreply.github.com>
@musalbas
Copy link
Member

What's the latest with this and generally adding specs to celestia-app/core now?

@rootulp
Copy link
Collaborator

rootulp commented Jan 20, 2023

This branch is the most up to date version of the specs but it's not publicly visible yet. IMO we should merge this branch to main, make it publicly visible, and take down the existing specs site at https://celestiaorg.github.io/celestia-specs/latest/index.html

The remaining specs issues are tracked under #650 . We intend on prioritizing specs and documentation work after the core/app feature freeze for incentivized testnet.

rootulp and others added 5 commits February 8, 2023 15:28
…#1420)

This aims to clarify that the minimum square size in non-interactive
default rules should be a power of 2. For example, for a message of
length 23, the minimum square size is `8*8` (but not `5*5`). (based on a
discussion in Slack)

- [x] NA ~~New and updated code has appropriate documentation~~
- [x] NA ~~New and updated code has new and/or updated testing~~
- [x] Required CI checks are passing
- [x] NA ~~Visual proof for any user facing features like CLI or
documentation updates~~
- [x] NA ~~Linked issues closed with keywords~~
## Motivation 
The table of contents at the top of each file can be a maintenance
burden. We can auto-generate it with
[mdbook-toc](https://github.com/badboy/mdbook-toc).

## Screenshot

Before | After
--- | ---
<img width="500" alt="before"
src="https://user-images.githubusercontent.com/3699047/222535783-8ad53ec3-43db-4e4b-ad8f-ea974061190b.png">
| <img width="479" alt="after"
src="https://user-images.githubusercontent.com/3699047/222535796-39c4172d-79b9-4e64-a492-7a68c37f5381.png">
@cmwaters
Copy link
Contributor

I have some general comments that can possible be followed up at a later point:

  • Can we break up data structures into smaller more self-explanatory files so that parts can be easily accessed in the table of contents. I also think it's less intuitive to explain a spec by just dumping all the data structures that are included in it. Would prefer more of a hierarchical function-orientated tree.
  • Can we add a section explaining how the "celestia app" fits in with the rest of the system and include links so people can be easily redirected if they're interested with something in "celestia node" for example. Furthermore, I think calling it "celestia app" can be better worded. As this isn't the specification of the entire system, rather a component of it, we should look to distinguish it functionally. Call it "celestia data publication specification" (to complement "celestia data availability specfication") if we want to be deliberate about having two networks.
  • I don't think Rationale should be a separate section but should be embedded right next to the part in the spec it refers to. I should read what a certain protocol is and directly after why it is so.
  • It's evident that the specification includes not just novel work specific to Celestia but the components that it is built on top of. There is a lot of work on Tendermint's consensus algorithm (such as block validity, leader selection) and how the validator set is controlled. What about other components like governance, IBC, vesting, upgrades that still seem to be missing. It seems that not all state transition messages have been documented.
  • Is QGB spec somewhere else?
  • Can we have some preamble/context in the top level pages to each of the subpages.
  • Are we sure we want a copy of many of the proto files in the spec as well? These are not the canonical ones that get used in generation and will constantly become outdated.

@rootulp
Copy link
Collaborator

rootulp commented Mar 14, 2023

Overall I'm on-board with basically all of the suggestions you proposed. I think the feedback could be spun out into individual issues that we add to the epic rather than blocking feedback on this PR.

Can we break up data structures into smaller more self-explanatory files

I'm on-board. I agree that the data structures page is long and difficult to read top to bottom so I think multiple logically contained data structures pages would be helpful for readability.

I don't think Rationale should be a separate section but should be embedded right next to the part in the spec it refers to.

Agreed. I think we should move the rationale/message_block_layout section to block_proposer#laying-out-transactions-and-messages

Is QGB spec somewhere else?

Perhaps https://github.com/celestiaorg/celestia-app/blob/main/x/qgb/README.md

Are we sure we want a copy of many of the proto files in the spec as well?

Good question. I think we should not duplicate the proto definitions in the specs unless we have an automated way to update them if the canonical ones change.

@rootulp rootulp self-assigned this Mar 14, 2023
@rootulp rootulp added this to the Mainnet milestone Mar 14, 2023
@rootulp rootulp marked this pull request as ready for review March 14, 2023 17:05
@rootulp rootulp requested review from MSevey and liamsi March 14, 2023 17:05
Copy link
Member

@evan-forbes evan-forbes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are the markdown linter complaints valid?

  ERROR: 2 dead links found!
  [✖] .consensus.md#constants → Status: 400
  [✖] ../rationale/distributing_rewards.md → Status: 400

other than that I think we're okay to merge (and actually merge, not squash!)

we should also add @cmwaters feedback into the spec epic as @rootulp mentioned because I think its really good

@MSevey MSevey requested a review from a team March 14, 2023 22:11
Running make lint locally doesn't catch these errors
@rootulp
Copy link
Collaborator

rootulp commented Mar 15, 2023

are the markdown linter complaints valid?

They are valid but they don't appear when make lint is run locally. They appear resolved after the most recent commit.

Docker / hadolint fails but that occurs on other branches too (potentially b/c Github outage).

@rootulp
Copy link
Collaborator

rootulp commented Mar 15, 2023

Will merge this by EOD tomorrow if no more feedback.

MSevey
MSevey previously approved these changes Mar 16, 2023
Copy link
Member

@MSevey MSevey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

overall looks good to me, didn't review the specs themselves, waiting until they are deployed and we can submit clean up PRs.

@evan-forbes
Copy link
Member

evan-forbes commented Mar 16, 2023

its weird that the docker builds are still failing here despite passing in other PRs, we didn't change anything related here afaict

edit: Rootul fixed it

Co-authored-by: Matthew Sevey <mjsevey@gmail.com>
@rootulp rootulp merged commit b3f0b02 into main Mar 16, 2023
@rootulp rootulp deleted the specs-staging branch October 5, 2023 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
specs directly relevant to the specs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants