indexed-finance / multicall Goto Github PK
View Code? Open in Web Editor NEWSolidity contract and typescript library for static multi-calls
Solidity contract and typescript library for static multi-calls
Minimal code to reproduce:
script/min.js
:
const MultiCall = require('@indexed-finance/multicall');
async function main() {
new MultiCall(ethers.provider);
}
main()
.then(() => process.exit(0))
.catch((error) => {
console.error(error);
process.exit(1);
});
Then run npx hardhat run script/min.js
, will report:
TypeError: MultiCall is not a constructor
at main (/Users/xuzhiqiang/Desktop/workspace/opensource/solidity/scripts/min.js:4:5)
at Object.<anonymous> (/Users/xuzhiqiang/Desktop/workspace/opensource/solidity/scripts/min.js:7:1)
Do you encounter this error after run a period?
hi, I think it's the most generic multicall I have ever seen, how can I use it by golang?
I'm wondering if there's any way to pass custom parameters to the aggregate function
example:
.call({from: "0x00000"})
First of all, this no-deploy constructor-based multicall is ingenious! I really like it
But there is one limitation that I have just come across trying to query too big of a multicall. Contracts have a max code size of 24kB, so these static multicalls are also bound by this limitation. Huge multicalls will return
reason: 'processing response error',
code: 'SERVER_ERROR',
body: '{"jsonrpc":"2.0","id":46,"error":{"code":-32000,"message":"max code size exceeded"}}'
I think this should be noted in the README somewhere as a caveat of this approach.
Apologies please delete
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.