Skip to content

Comments

Add specs package#514

Merged
maurelian merged 20 commits intomasterfrom
feat/specs
Apr 22, 2021
Merged

Add specs package#514
maurelian merged 20 commits intomasterfrom
feat/specs

Conversation

@maurelian
Copy link
Contributor

@maurelian maurelian commented Apr 20, 2021

Description

This PR moves specifications from a private repo to here. Things I think reviewers should focus on:

  1. Identifying factually incorrect information.
  2. Identifying information that is going to change in the near future (I will add a note in the specs to reflect it).
    If you respond with 'Request changes', please indicate what you would require to approve. :)

Responses to some comments/questions I anticipate

1. What's up with these files that have no substantive content?

I have included a couple files that are effectively empty (or have their content commented out). Per the note in these files, I would like to keep them as a place holder.

2. Where is the content to describe how X works?

Please DO leave these comments so I can prioritize the areas most in need of specification. However, IMO completeness is shouldn't be a requirement to merge this in.

3. What going on in /l2geth?

The content there was written by others in the previous repo. I think it's useful to bring this in for the geth team. I'm open to splitting it out into another location, if there is a clear proposal, otherwise would prefer just to get it in here.

@changeset-bot
Copy link

changeset-bot bot commented Apr 20, 2021

🦋 Changeset detected

Latest commit: 0a3caa3

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@eth-optimism/specs Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@maurelian maurelian changed the title Feat/specs Add a specification package Apr 20, 2021
@maurelian maurelian marked this pull request as draft April 20, 2021 18:54
l2geth/ @smartcontracts @tynes @karlfloersch
packages/specs/l2geth/ @smartcontracts @tynes @karlfloersch
packages/contracts/ @smartcontracts @ben-chain @maurelian
packages/specs/protocol/ @smartcontracts @ben-chain @maurelian
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I moved packages/contracts/ up to make the relationship between the specs and the implementation locations more obvious.

* @notice Specifies from which L1 rollup queue this transaction originated from.
* @return _queueOrigin Address of the ovmL1QUEUEORIGIN within the current message context.
* @notice Specifies from which source (Sequencer or Queue) this transaction originated from.
* @return _queueOrigin Enum indicating the ovmL1QUEUEORIGIN within the current message context.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Just a comment I noticed needed improvement while doing this work.

@@ -0,0 +1,109 @@
# Sequencer specs
Copy link
Contributor Author

Choose a reason for hiding this comment

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

/seqencer had it's own top level dir in the specs repo. I moved it into /l2geth here. I supposed I could have done:

mv l2geth/sequencer/* l2geth
rm -rf sequencer

But this felt like a more conservative approach to content written by others.

},
"scripts": {
"format": "yarn prettier --write ./**/*.md",
"format:check": "yarn prettier --check ./**/*.md"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

  1. I intend for format:check to run in CI, but haven't set that up yet.

  2. I know that yarn prettier --check ./**/*.md looks funny. Why not just prettier --check **/*.md, honestly I'm not sure why, but that and every other variation of this script I tried failed to run on all md files up and down the tree.

},
"scripts": {
"format": "yarn prettier --write \"{l2geth,protocol}/**/*.md\"",
"format:check": "yarn prettier --check \"{l2geth,protocol}/**/*.md\"",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

  1. I realize the glob string seems like overkill, but I couldn't get anything else to hit all the md files up and down the tree.
  2. my intention is for format:check to run in CI, but I haven't set that up.

@@ -0,0 +1,19 @@
# Accounts

This document is a WIP. It is kept here to maintain a consistent structure mirroring the [implementation directory](../../../contracts/contracts/optimistic-ethereum/OVM/).
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I hope to complete this document thoroughly in the near future, but would like to include it as a placeholder.
If it's a blocker, I can remove it.

@@ -0,0 +1,348 @@
# Optimistic Ethereum Data Structures
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Feel free to leave a comment here where you think a variable name should change, but IMO actually updating it should be reserved for a new PR.

@maurelian maurelian marked this pull request as ready for review April 20, 2021 18:58
@maurelian maurelian requested review from gakonst and snario April 20, 2021 19:07
@maurelian maurelian changed the title Add a specification package Add a specifics package Apr 20, 2021
@tynes
Copy link
Contributor

tynes commented Apr 20, 2021

The content there was written by others in the previous repo. I think it's useful to bring this in for the geth team. I'm open to splitting it out into another location, if there is a clear proposal, otherwise would prefer just to get it in here.

I'm on board with leaving it in and agree with renaming it to l2geth

@tynes
Copy link
Contributor

tynes commented Apr 20, 2021

I made an update to l2geth here: ethereum-optimism/specs#31

I can open a PR against this or wait until this is merged in, whatever is easier for @maurelian getting this in

@maurelian maurelian changed the title Add a specifics package Add specs package Apr 20, 2021
Copy link
Contributor

@gakonst gakonst left a comment

Choose a reason for hiding this comment

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

Please:

  1. pull this to the top level directory (not under packages), and add it to the global yarn workspace.
  2. mark the package as private so that it does not get published by accident

Have the protocol changes been approved by @ben-chain? ethereum-optimism/specs#30 is still a draft.

Separately:
It seems like transaction-indexer refers to the DTL so should be moved outside of l2geth, and the transaction-ingestor refers to L2geth's SyncService so should be renamed to that?

@maurelian
Copy link
Contributor Author

maurelian commented Apr 21, 2021

OK, will move to root of repo.

Have the protocol changes been approved by @ben-chain? ethereum-optimism/specs#30 is still a draft.

There should not be protocol changes in here yet. For now I've aimed to describe the protocol as is.
Changes to the spec can be made and reviewed in separate PRs.

"l2geth",
"integration-tests"
"integration-tests",
"specs"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@gakonst is this change sufficient to "add it to the global yarn workspace" as requested?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes!

@maurelian maurelian requested a review from gakonst April 22, 2021 03:49
"l2geth",
"integration-tests"
"integration-tests",
"specs"
Copy link
Contributor

Choose a reason for hiding this comment

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

Yes!

maurelian and others added 2 commits April 22, 2021 08:09
Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
Copy link
Collaborator

@ben-chain ben-chain left a comment

Choose a reason for hiding this comment

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

Woot woot, Let's Get This Merged!

@maurelian maurelian merged commit 318857e into master Apr 22, 2021
@maurelian maurelian deleted the feat/specs branch April 22, 2021 19:41
InoMurko referenced this pull request in omgnetwork/optimism May 25, 2021
* chore: import specs

fix: accurately describe ovmL1TXORIGIN

more specs

* chore: rename to match structure of contracts

words

* chore: move to packages

* chore: add package.json

fix location of package.json

* docs: rename processes dir to components

words

* docs: remove empty specs dir

* docs: move sequencer into l2geth

* chore: assign code owners to specs

* chore: add prettier

* docs: polish bridge and actors section

docs: polish

* chore: add format:check script

* docs: fixup readme

* chore: fix prettier config

* fix: json linting

* chore: add changeset

* Update packages/specs/protocol/components/execution.md

* chore: move specs to root

* chore: make private, add to yarn workspaces

* Update specs/package.json

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>

* fix: formatting

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
bap2pecs pushed a commit to babylonlabs-io/optimism that referenced this pull request Jul 31, 2024
theochap pushed a commit that referenced this pull request Jan 15, 2026
fixes #513

---------

Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de>
emhane pushed a commit that referenced this pull request Feb 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants