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

Clean up pretty much everything #380

Merged
merged 4 commits into from
Dec 17, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build-test-lint-batch-submitter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

strategy:
matrix:
node: [ '10' ]
node: [ '10', '12', '14' ]

steps:
- uses: actions/checkout@v2
Expand Down
64 changes: 0 additions & 64 deletions .github/workflows/build-test-lint-core-db.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/build-test-lint-core-utils.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

strategy:
matrix:
node: [ '10' ]
node: [ '10', '12', '14' ]

steps:
- uses: actions/checkout@v2
Expand Down
63 changes: 0 additions & 63 deletions .github/workflows/build-test-lint-gas-profiler.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/build-test-lint-ovm-toolchain.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

strategy:
matrix:
node: [ '10' ]
node: [ '10', '12', '14' ]

steps:
- uses: actions/checkout@v2
Expand Down
5 changes: 1 addition & 4 deletions lerna.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
{
"version": "independent",
"packages": [
"packages/contracts/*",
"packages/core-db/*",
"packages/core-utils/*",
"packages/ovm-toolchain/*",
"packages/provider/*",
"packages/rollup-core/*",
"packages/rollup-services/*"
"packages/batch-submitter/*"
],
"command": {
"publish": {
Expand Down
7 changes: 2 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"pkgparse:core": "echo ${PKGS:-'*'} | sed -e 's#,# @eth-optimism/#g' -e 's#^#@eth-optimism/#'",
"pkgparse:integration": "echo ${PKGS:-'*'} | sed -e 's#,# @eth-optimism-test/#g' -e 's#^#@eth-optimism-test/#'",
"lint": "wsrun -p $(yarn --silent run pkgparse) --parallel --exclude-missing lint",
"fix": "wsrun -p $(yarn --silent run pkgparse) --fast-exit --parallel --exclude-missing fix",
"lint:fix": "wsrun -p $(yarn --silent run pkgparse) --fast-exit --parallel --exclude-missing lint:fix",
"clean": "wsrun -p $(yarn --silent run pkgparse) -r --fast-exit --parallel --exclude-missing clean",
"clean_modules": "rm -rf node_modules && find ./packages -type d -maxdepth 2 -name \"node_modules\" -exec rm -r {} +",
"clean_manual": "find ./packages -type d -maxdepth 2 -name \"build\" -exec rm -r {} +",
Expand All @@ -23,7 +23,7 @@
"test": "yarn test:core && yarn test:integration",
"coverage": "wsrun -p $(yarn --silent run pkgparse:core) --fast-exit --parallel --no-prefix --exclude-missing --timeout 5000 coverage",
"build": "yarn run patch && lerna link && wsrun -p $(yarn --silent run pkgparse) -r --fast-exit --stages --exclude-missing build",
"all": "yarn clean && yarn build && yarn test && yarn fix && yarn lint",
"all": "yarn clean && yarn build && yarn test && yarn lint:fix && yarn lint",
"release": "yarn clean && yarn run build && lerna publish --force-publish --exact -m \"chore(@ethereum-optimism) publish %s release\"",
"release:patch": "yarn clean && yarn build && lerna version prerelease --yes && lerna publish from-package --yes --force-publish -m \"chore(@ethereum-optimism) publish %s release\"",
"release:rc": "yarn clean && yarn build && lerna version prerelease --yes && lerna publish from-package --yes --force-publish --npm-tag=rc -m \"chore(@ethereum-optimism) publish %s release\"",
Expand All @@ -34,9 +34,6 @@
"patch:waffle": "sed -ie 's!Ganache.GanacheOpts!any!g' node_modules/ethereum-waffle/dist/waffle.d.ts ||:"
},
"repository": "git+https://github.com/ethereum-optimism/optimism-monorepo.git",
"engines": {
"node": "10"
},
"keywords": [
"plasma",
"group",
Expand Down
5 changes: 1 addition & 4 deletions packages/batch-submitter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,10 @@
"start": "node ./exec/run-batch-submitter.js",
"build": "tsc -p .",
"clean": "rimraf build/",
"fix": "prettier --config ../../prettier-config.json --write 'index.ts' 'src/**/*.ts'",
"lint": "tslint --format stylish --project .",
"lint:fix": "prettier --config ../../prettier-config.json --write 'index.ts' 'src/**/*.ts'",
"test": "buidler test --show-stack-traces"
},
"engines": {
"node": "10"
},
"keywords": [
"optimism",
"ethereum",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import { expect } from '../setup'

/* External Imports */
import { ethers } from '@nomiclabs/buidler'
import { Signer, ContractFactory, Contract } from 'ethers'
import { getContractInterface } from '@eth-optimism/contracts'
import { smockit, MockContract } from '@eth-optimism/smock'
import { Signer, ContractFactory, Contract, BigNumber } from 'ethers'
import { remove0x, getLogger } from '@eth-optimism/core-utils'

/* Internal Imports */
Expand Down Expand Up @@ -113,6 +113,8 @@ describe('TransactionBatchSubmitter', () => {
AddressManager.address,
FORCE_INCLUSION_PERIOD_SECONDS
)
await unwrapped_OVM_CanonicalTransactionChain.init()

OVM_CanonicalTransactionChain = new CanonicalTransactionChainContract(
unwrapped_OVM_CanonicalTransactionChain.address,
getContractInterface('OVM_CanonicalTransactionChain'),
Expand Down Expand Up @@ -175,12 +177,12 @@ describe('TransactionBatchSubmitter', () => {
nextQueueElement.timestamp - 1
)
let receipt = await batchSubmitter.submitNextBatch()
let logData = remove0x(receipt.logs[0].data)
let logData = remove0x(receipt.logs[1].data)
expect(parseInt(logData.slice(64 * 0, 64 * 1), 16)).to.equal(0) // _startingQueueIndex
expect(parseInt(logData.slice(64 * 1, 64 * 2), 16)).to.equal(0) // _numQueueElements
expect(parseInt(logData.slice(64 * 2, 64 * 3), 16)).to.equal(6) // _totalElements
receipt = await batchSubmitter.submitNextBatch()
logData = remove0x(receipt.logs[0].data)
logData = remove0x(receipt.logs[1].data)
expect(parseInt(logData.slice(64 * 0, 64 * 1), 16)).to.equal(0) // _startingQueueIndex
expect(parseInt(logData.slice(64 * 1, 64 * 2), 16)).to.equal(0) // _numQueueElements
expect(parseInt(logData.slice(64 * 2, 64 * 3), 16)).to.equal(11) // _totalElements
Expand All @@ -192,12 +194,12 @@ describe('TransactionBatchSubmitter', () => {
queueOrigin: QueueOrigin.L1ToL2,
} as any)
let receipt = await batchSubmitter.submitNextBatch()
let logData = remove0x(receipt.logs[0].data)
let logData = remove0x(receipt.logs[1].data)
expect(parseInt(logData.slice(64 * 0, 64 * 1), 16)).to.equal(0) // _startingQueueIndex
expect(parseInt(logData.slice(64 * 1, 64 * 2), 16)).to.equal(6) // _numQueueElements
expect(parseInt(logData.slice(64 * 2, 64 * 3), 16)).to.equal(6) // _totalElements
receipt = await batchSubmitter.submitNextBatch()
logData = remove0x(receipt.logs[0].data)
logData = remove0x(receipt.logs[1].data)
expect(parseInt(logData.slice(64 * 0, 64 * 1), 16)).to.equal(6) // _startingQueueIndex
expect(parseInt(logData.slice(64 * 1, 64 * 2), 16)).to.equal(5) // _numQueueElements
expect(parseInt(logData.slice(64 * 2, 64 * 3), 16)).to.equal(11) // _totalElements
Expand Down Expand Up @@ -230,7 +232,7 @@ describe('TransactionBatchSubmitter', () => {
6
)
const receipt = await batchSubmitter.submitNextBatch()
const logData = remove0x(receipt.logs[0].data)
const logData = remove0x(receipt.logs[1].data)
expect(parseInt(logData.slice(64 * 0, 64 * 1), 16)).to.equal(0) // _startingQueueIndex
expect(parseInt(logData.slice(64 * 1, 64 * 2), 16)).to.equal(8) // _numQueueElements
expect(parseInt(logData.slice(64 * 2, 64 * 3), 16)).to.equal(11) // _totalElements
Expand Down
1 change: 0 additions & 1 deletion packages/core-db/README.md

This file was deleted.

5 changes: 0 additions & 5 deletions packages/core-db/index.ts

This file was deleted.

65 changes: 0 additions & 65 deletions packages/core-db/package.json

This file was deleted.

Loading