v7.4.3
Fixes
Miscellaneous
Changelog
Known Issues
Future Plans
As we close out the month of August where we focused most of our energy on removing tech debt from the Ganache codebase, we have a release with quite a few fixes, documentation updates, chores, and CI improvements. This, combined with the week that the whole team took off to rest, means that we should be ready for some serious momentum in the coming months! We have some great new features in the works and are excited to share them with you in the coming releases!
For this release, we'd like to thank our issue reporters (@VladLupashevskyi, @cds-amal) and PR openers (@jaketimothy, @l2ig). We really appreciate your contributions!
If you have some time, we encourage you to browse our issues to find anything you'd like implemented/fixed sooner. Give them a +1 and we'll use this community feedback to help prioritize what we work on! Or better yet, open a new issue or open a PR to fix an existing issue if you really want to get involved.
We've changed 55 files across 12 merged pull requests, tallying 935 additions and 462 deletions, since our last release.
- fix: assume unknown tx type is
TransactionType.Legacy
(#3523) - fix: after
provider.disconnect()
is called, Ganache should stop serving requests (#3433) - fix:
evm_setTime
doesn't work correctly withminer.timestampIncrement
(#3506) - fix: return exactly 32 bytes from
eth_getStorageAt
(#3527)
fix: assume unknown tx type is TransactionType.Legacy
(#3523)
This change, made by the great @jaketimothy, fixes a bug with Ganache where it would throw if an unknown transaction type is sent by a user. Now, Ganache will allow any transaction type and turn it into a Legacy transaction if the type is unknown. This fixes an issue (#3458) that many Arbitrum Nitro users have been facing. Thanks again, @jaketimothy!
fix: after provider.disconnect()
is called, Ganache should stop serving requests (#3433)
Previously, when provider.disconnect()
was called, a lot of the internals of Ganache would be stopped, but just enough was kept alive to serve requests. This could stop consumers from shutting down cleanly.
Now all pending requests, and any new requests will be rejected with a helpful error.
For example, before this change, the following would successfully return the block number:
const provider = Ganache.provider();
await provider.disconnect();
const blockNumber = await provider.send("eth_blockNumber");
But now:
Error: Cannot process request, Ganache is disconnected.
Caveat: any request that has started to process, but not yet complete, may fail with an unexpected error. See #3499 for details.
fix: evm_setTime
doesn't work correctly with miner.timestampIncrement
(#3506)
When using miner.timestampIncrement
, calling evm_setTime
can result in unexpected values, and potentially with an error being thrown.
This is because the timeAdjustment
is applied to the previous blocktime, so this offset is applied for every block that is mined.
With the following example, the initial block is mined correctly, as is the first block after setting the time, but subsequent blocks will have a descending block time, until the value becomes negative.
const p = await getProvider({
miner: { timestampIncrement: 1 },
chain: { time: 10000 }
});
const mineAndShowBlock = async () => {
await p.send("evm_mine");
const { number, timestamp } = await p.send("eth_getBlockByNumber", [
"latest"
]);
console.log({ number, timestamp: Quantity.toNumber(timestamp) });
};
await mineAndShowBlock();
await p.send("evm_setTime", [5000]);
while (true) {
await mineAndShowBlock();
}
{ number: '0x1', timestamp: 11 }
{ number: '0x2', timestamp: 6 }
{ number: '0x3', timestamp: 1 }
Error: Cannot wrap a negative value as a json-rpc type
fix: return exactly 32 bytes from eth_getStorageAt
(#3527)
eth_getStorageAt
was returning compact representations of data, e.g., "0x5"
instead of "0x0000000000000000000000000000000000000000000000000000000000000005"
. We now always return the padded whole 32 byte word.
- test: replace
assert.deepEqual
withassert.deepStrictEqual
(#3533) - chore: set default hardfork to
grayGlacier
; update@ethereumjs/*
packages (#3534, #3629) - docs: add trufflesuite.com to README (#3564)
- ci: add config for semantic-prs app (#3543)
- ci: remove docker from automated release workflow (#3547)
- test: skip test pending chainId added to transaction object (#3617)
- chore: add sepolia as a network option (#3580)
test: replace assert.deepEqual
with assert.deepStrictEqual
(#3533)
This PR improves the consistency of our tests but replacing all assert.deepEqual
calss with assert.deepStrictEqual
. Thanks, @l2ig!
chore: add support for grayGlacier
; update @ethereumjs/*
packages (#3534, #3629)
This change adds support for the grayGlacier
hardfork. This change also updates @ethereumjs/*
packages to their latest versions, which is what allows us to add the grayGlacier
hardfork (ganache --hardfork grayGlacier
). This hardfork does not change ganache behavior, other than make the hardfork name available.
docs: add trufflesuite.com to README (#3564)
We just thought it'd be useful to have a link to our website on our README 🔗
ci: add config for semantic-prs app (#3543)
This change adds a semantic.yml
file to configure how the Semantic-PRs app interacts with Ganache. This app will now require that all pull requests have a title with a conventional commit message.
ci: remove docker from automated release workflow (#3547, #3619)
Previously our automated release process would require successfully publishing to Docker to complete. Since publishing to Docker can sometimes be unreliable, this would occasionally cause the release to fail, meaning we'd have to manually fix our release process' commit history and publish to Docker.
This change moves the step to publish to Docker to its own action, which is run only if the actual release is fully successful. Because this is now a separate job in the release process, we can rerun that individual job if it fails.
Fixes #3546.
test: skip test pending chainId added to transaction object (#3617)
Pending resolution of #3616, forking > blocks > should get a block from the original chain
test is now skipped.
chore: add sepolia as a network option (#3580)
This change adds support for the sepolia testnet. You can now use Ganache's zero-config mainnet forking to fork the sepolia testnet. To do this, simply run ganache --fork sepolia
in your console.
- #3523 fix: assume unknown tx type is
TransactionType.Legacy
(@jaketimothy) - #3533 test: replace
assert.deepEqual
withassert.deepStrictEqual
(@l2ig) - #3534 chore: set default hardfork to
grayGlacier
; update@ethereumjs/*
packages (@davidmurdoch) - #3433 fix: after
provider.disconnect()
is called, Ganache should stop serving requests (@jeffsmale90) - #3564 docs: add trufflesuite.com to README (@davidmurdoch)
- #3506 fix:
evm_setTime
doesn't work correctly withminer.timestampIncrement
(@jeffsmale90) - #3527 fix: return exactly 32 bytes from
eth_getStorageAt
(@davidmurdoch) - #3543 ci: add config for semantic-prs app (@MicaiahReid)
- #3547 ci: remove docker from automated release workflow (@MicaiahReid)
- #3617 test: skip test pending chainId added to transaction object (@jeffsmale90)
- #3619 ci: fix docker publish (@MicaiahReid)
- #3580 chore: add sepolia as a network option (@tenthirtyone)
Top Priority:
debug_storageRangeAt
fails to find storage when the slot was created earlier in the same block (#3338)- Architecture not supported (#2256)
- Add
eth_feeHistory
RPC endpoint (#1470) - Add
eth_createAccessList
RPC method (#1056)
Coming Soon™:
- Implications failed: fork.headers -> url (#2627)
- In Geth chain-mode, logic to accept/reject transactions based on gas price/limit should match Geth (#2176)
evm_mine
andminer_start
don't respect --mode.instamine=eager (#2029)evm_setAccount*
is race-conditiony (#1646)@ganache/filecoin@alpha
doesn't work withganache@alpha
(#1150)- Launching ganache with fork is throwing revert errors when communicating with 3rd party contracts (#956)
- Build a real pending block! (#772)
- VM Exception when interfacing with Kyber contract (#606)
- After calling
evm_mine
,eth_getLogs
returns same logs for all blocks (#533) - personal_unlockAccount works with any password (#165)
- --db Option Requires Same Mnemonic and Network ID (#1030)
Top Priority:
Coming Soon™:
- Switch to esbuild to make build times faster/reasonable (#1555)
- Add eip-155 support (#880)
- Allow to sync forked chain to the latest block (#643)
- Implement a streaming trace capability (#381)
- Improve log performance when forking (#145)
- Log contract events (#45)
Open new issues (or join our team) to influence what we gets implemented and prioritized.
💖 The Truffle Team