-
Notifications
You must be signed in to change notification settings - Fork 773
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
Monorepo: Switch to hybrid ESM/CJS Build #2685
Merged
Merged
Changes from 32 commits
Commits
Show all changes
33 commits
Select commit
Hold shift + click to select a range
534ee3d
Exemplary ESM build for Block package, extended config ts-build.sh sc…
holgerd77 cd33a31
Skip ESM build for non-converted packages
holgerd77 7d116f5
Temporarily skip client build (build failures)
holgerd77 35801db
More fixes
holgerd77 45c877c
Yet another fix
holgerd77 3120188
Fixes
holgerd77 d57c5b0
Simplify exports in package.json (review suggestion)
holgerd77 5c05881
Updated rlp package (extra: bin folder adjustment)
holgerd77 e441e3b
Update Util package
holgerd77 8d7cb60
Update Common package
holgerd77 dc42390
Update Trie package (folder references still missing to ease Trie ref…
holgerd77 5d411d7
Open up Util provider path to fix block, tx fromRpcProvider test test…
holgerd77 ed398ec
devp2p: internalize k-bucket package (no types yet)
holgerd77 b4d5704
Update Tx package
holgerd77 5c68d90
Update Ethash package
holgerd77 d741b1a
Update Blockchain package
holgerd77 2e296b6
update StateManager package
holgerd77 ce18af5
Update VM package, remove direct EVM error msg imports, rename EvmErr…
holgerd77 c465f59
Fix direct EVM -> VM imports
holgerd77 983ee3d
Rename all tsconfig.prod.json occurrences to tsconfig.prod.cjs.json
holgerd77 f7c55cc
Fix VM BlockBuilder related client build failures, add BlockBuilder t…
holgerd77 9297fe4
Rebuild package-lock.json
holgerd77 798a7aa
Fix
holgerd77 177c1cc
Fix VM benchmark block fromRPC() import
holgerd77 96148a8
devp2p: remove ms dependency + types
holgerd77 cfe67da
Update EVM package
holgerd77 7d026c6
Various fixes and type export additions (blockchain, VM)
holgerd77 f6177f6
More fixes
holgerd77 dc018a9
More fixes
holgerd77 c5773b1
Even more fixes
holgerd77 ef72830
Fix VM Karma browser test run
holgerd77 be94048
Remove testdouble dep from block/tx tests
acolytec3 8e70475
Remove unused baseUrl config option from tsconfig
acolytec3 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"extends": "./tsconfig.json", | ||
"compilerOptions": { | ||
"module": "esnext" | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"extends": "../../config/tsconfig.prod.cjs.json", | ||
"compilerOptions": { | ||
"lib": ["dom"], | ||
"rootDir": "src", | ||
"outDir": "dist/cjs", | ||
"composite": true | ||
}, | ||
"include": ["src/**/*.ts"], | ||
"references": [ | ||
{ "path": "../rlp/tsconfig.prod.cjs.json" }, | ||
{ "path": "../trie/tsconfig.prod.cjs.json" }, | ||
{ "path": "../tx/tsconfig.prod.cjs.json" }, | ||
{ "path": "../util/tsconfig.prod.cjs.json" } | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"extends": "../../config/tsconfig.prod.esm.json", | ||
"compilerOptions": { | ||
"lib": ["dom"], | ||
"rootDir": "src", | ||
"outDir": "dist/esm", | ||
"composite": true | ||
}, | ||
"include": ["src/**/*.ts"], | ||
"references": [ | ||
{ "path": "../rlp/tsconfig.prod.cjs.json" }, | ||
{ "path": "../trie/tsconfig.prod.cjs.json" }, | ||
{ "path": "../tx/tsconfig.prod.cjs.json" }, | ||
{ "path": "../util/tsconfig.prod.cjs.json" } | ||
] | ||
} |
holgerd77 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
export { Blockchain } from './blockchain' | ||
export { CasperConsensus, CliqueConsensus, Consensus, EthashConsensus } from './consensus' | ||
export { BlockchainInterface, BlockchainOptions } from './types' | ||
export { DBOp, DBSaveLookups, DBSetBlockOrHeader, DBSetHashToNumber, DBSetTD } from './db/helpers' | ||
export * from './types' | ||
export * from './utils' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"extends": "../../config/tsconfig.prod.cjs.json", | ||
"compilerOptions": { | ||
"rootDir": "src", | ||
"outDir": "dist/cjs", | ||
"types": ["node"], | ||
"typeRoots": ["node_modules/@types"], | ||
"composite": true | ||
}, | ||
"include": ["src/**/*.ts", "src/**/*.json"], | ||
"references": [ | ||
{ "path": "../common/tsconfig.prod.cjs.json" }, | ||
{ "path": "../ethash/tsconfig.prod.cjs.json" }, | ||
{ "path": "../rlp/tsconfig.prod.cjs.json" }, | ||
{ "path": "../util/tsconfig.prod.cjs.json" } | ||
] | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, interesting. I would have never gotten to this solution. 🙂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It means we're no longer testing the Node16 route for fetching data (using
https
instead of thefetch
API but there are separate tests inutil
for testing that. The goal here is to test the constructor so this seemed like the least impactful route to that.