Note: I have already visited the related links which have similar questions posted, but I didn't find any solution which I could use to solve the issue Im facing.
Im following this Coursetro tutorial, which basically guides those new to blockchain to create a simple smart contract. The contract is defined as follows:
pragma solidity ^0.4.18;
contract Coursetro {
string fName;
uint age;
function setInstructor(string _fName, uint _age) public {
fName = _fName;
age = _age;
}
function getInstructor() public constant returns (string, uint) {
return (fName, age);
}
}
However when I change the environment in the remix IDE from Javascript env to Web 3 env(To connect to the testrpc instance running locally on terminal), I get the following error:
creation of browser/Coursetro.sol:Coursetro pending...
creation of browser/Coursetro.sol:Coursetro errored: Error: base fee
exceeds gas limit
at runCall (/usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:70875:17)
at /usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:12643:24
at replenish (/usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:9736:17)
at iterateeCallback (/usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:9721:17)
at /usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:9696:16
at /usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:12648:13
at /usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:67073:16
at replenish (/usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:67020:25)
at /usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:67029:9
at eachLimit (/usr/local/lib/node_modules/ethereumjs-
testrpc/build/cli.node.js:66953:36)
I understand that the fee for executing any contract must never exceed the Gas limit set, but in this case, Im unable to deduce where to set the Gas limit. Im new to this so kindly guide me as to how to solve the above error.