complete 1.js file is being displayed in the terminal if ganache used programatically
See original GitHub issueIn my project i was using ganache programatically and passing options as an argument to the provider. If any error occurs it should show only error but it prints complete 1.js file in the terminal in my node project.
We can handle the issue with, 1. Prettifying minified 1.js file and other is to use try catch whenever using ganache instance.
This problem is similar to solidity’s solcjson.js error.
var ganache = require('ganache');
options = { miner: { blockGasLimit: "5F5E100" }, }
provider = ganache.provider(options);
Here gaslimit should be in hex but i have put this without 0x to recreate the errror.
It would be great if this problem is solved.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Executing shell command using child process - Stack Overflow
When I replace the command with 'dir', it works perfectly and lists the files in the directory. Even if I remove the node...
Read more >ganache - npm
A tool for creating a local blockchain for fast Ethereum development. Features • Getting Started • Documentation • Community • Docker ...
Read more >Ganache 7 Ethereum Simulator - Building on Web3 is now ...
We are excited to announce the wide release of the latest version of Ganache today, ... Ganache 7 can be used programmatically in...
Read more >v7.0.0 · Discussion #2121 · trufflesuite/ganache - GitHub
If you do, or if you want to keep up with all things Ganache, ... We're proud of this one and will likely...
Read more >Deploying and interacting with smart contracts
The Ethereum blockchain (often called "mainnet", for "main network") requires spending real money to use it, in the form of Ether (its native...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thank you so much for the answer !
We bundle our packages to reduce installation time, and at the same time we minify it all. In doing so we generate source maps, files that can map characters in the minified file to their original source.
Node.js doesn’t automatically read these source map files (but browsers do, in certain situations), so you have to use source-map-support to add support.
The downside to using source-map-support for you is that this will slow down the initialization of your application (i’m not sure how slow ganache’s source map loading can be). There is also a downside for everyone, even if they don’t use source-map-support, since it increases our bundle size, which defeats the purpose of minifying in the first place!