Thank you Mr Scott, now i see the reason why everyone is spreading your name on every blog and media, calling you a trade god, i wish every trader can be so nice and kind like you, thank you sir for sharing your great strategy with me, i just made my first $18k within the first week of trading with your strategy, Am grateful sir.
My life changed for the best the first day i saw Scott's video, he made me to understand a lot more about trading forex/binary options and now i can trade with out the fear of losing
Hello am a newbie and I would like to know about Mr Scott's strategy, how it works and how do i contact him for information about his strategy? Please I need a reply ASAP
Guys well done, this has been incredible. Im moving over from bitcoin into ethereum and this is the first video that I've seen that goes into great detail - great questions asked by Jordan - know you know most of the answers already but you relate to what people might be wondering and then ask great questions - very powerful. Well done
Great video, man. I love how you always stop to ask the important clarifying questions, no matter how small or simple they might seem. Even if you already know the answer. Really good habit for instructional purposes. Much love from UMD.
Wow, you guys are so smart. You made this video in a way that it is easy to understand the basic installation and getting started. With all questions, smartely asked already in the process.
Great video! Really helpful!! I've been looking at Ethereum for a while and couldn't understand where to start. This video is the best 101 introduction out there. Thanks again!
When i wake up thinking, im gonna be an ethereum developer and get paid lots of money, im reminded of reality. i suppose i understand, but smart contracting and all these moving parts make me think again
Truffle change to call this way ``` HelloWorld.deployed().then(a => console.log(a.address)) ``` HelloWorld.deployed().then(a => console.log(a.balance().then(console.log)))
29:16 That is an instance of bignumber, required by and often returned by web3. Its toString function is already re-implemented to print the number in decimal form, but you didn't call toString on it, so it appears like that. You'd have to access c from within the callback. What you did would try to read c from the promise returned by .then()
If you are just watching and having problem with migrating around 22:00 check if you have testrpc running. Also - the truffle that I have downloaded (4th May 2017) need to include "artifacts.require" in the deploy migration file.
I'm about to gif you at 24:45 haha ! Anyway this video is really neat I've some background on this but I was kinda lost and this video clear/reset/put in order all things you have already learn or see and it's reaaaally effective ! I don't even finish this video I'm sure to follow the other. NICE JOB!
Hey guys! Stumbled across your channel and this video is extremely informative and valuable. Being an aspiring smart contract developer myself, I find that I learn best through someone demonstrating and explaining what they are doing line by line. You are doing a fantastic job of that - it's definitely helping me out here in South Korea!! Just one quick question, how are you broadcasting videos at the same time on the lower right corner? Are you using OBS and multiple cams? What video talk software are you using? How are you setting your bitrate and does your bandwidth not lag? We are also a blockchain channel over in Korea and just getting started on this RUclips thing. Would be a tremendous help if you could offer some tips. Have a fantastic day!! Keep those smart contract dev videos coming!!!!! ;)
Great video! Small recommendation: it would have been great if you could make a video setting up your development configuration. Installing truffle, testrpc, geth, etc. Other than that, perfect!
Great tutorial. Please switch your keyboard to a silent one. It makes a lot of noise when you type and listening you guys is way more fun that the key taps. :)
That is a very cool video, cleared a lot of things to me, thanks to Jordan and his pal. Can you also make or point me to some resources to understand how to interpret the data fields in a block.
Hi! First of all thank you very much for this tutorial. I'll be watching the next ones very soon. I have just one question about the end of the video: I can't manage to migrate to the geth --testnet instead of testrpc, I run the synced testnet and then "truffle migrate" and it gives me back an error. What changes do I need to do to the truffle.js file in order to migrate it to the geth testnet? Thanks a lot and keep up the good work :)
@46:00 public accessor functions are created for mappings also which can be called by providing a key as the parameter. e.g. mapping (address => uint) public foo; > someContract.foo('0x.....'); goo.gl/DNTG5u
Now you have to use a new syntax to store the helloworld var you have to go in the truffle console : HelloWorld.deployed().then(function(instance){helloworld=instance})
Hi Luke first of all thank you so very much you helped save a lot of my time, secondly I would like to ask you where or how did you learn about this so that I may continue my study in that section, once again thank you very much and I am truly grateful for this piece of information.
Ahmed Hamadto I figured it out thanks to the documentation of truffle. But it isn't obvious I found. that's why I wrote it down here. I guess it have to do with the fact that the functions return promises so you can't set the result to a variable, you have to use .then() to handle the return of the promise and set it to the variable in case of success. More on functional programming on MPJ's amazing channel +funfunfunction
Rajat Goel it shouldn't. What changes the most is the creation of the contract object. after you call your functions with the dot. syntax. contract.function(parameters)
Hello guys, thanks a lot for your valuable input. What I still ask myself is the block thing. A smart contact is stored in a block. Transactions which change the state of a smart contract are also stored in blocks. How do the blocks then reference the smart contract? Do the tx contain the address of the smart contract plus the new status or how is this being handled?
Guys need some help here. I believe there were changes in the truffle directory structure as per their documentation. I just tried truffle init and I only get contracts, migrations, test, and truffle.js in the root directory. I am missing the app and build folders, and i do not have the 2_deploy_migration.js file. I am using Windows 10 32-bit. I'm not sure if I should just proceed. Any help would be great. Thanks!
(1) Install it using NPM. In Linux you can execute the following command sudo npm install -g ethereumjs-testrpc or if you are using NodeJS 4.6.0 sudo npm install --unsafe-perm -g ethereumjs-testrpc (2) In your command line execute the following: testrpc
Can someone explain to me whey I can't see all the functions on the right side of the page "bytecode" "interface" etc Mine looks different and only shows "Environment" "account" Gas limit etc Thanks!
Jordan - have added a repo for both peoplelistui and peoplelist on github, so that people who may need to look at the code can do. Hope it's all right. peoplelist: github.com/apraka16/peoplelist peoplelistui: github.com/apraka16/peoplelistui
Hey does anyone have any idea how to host a react site like this on AWS S3? I tried uploading it to AWS but whenever I load the site its just a blank screen. Any ideas? Thanks
Hey, I had a problem in one of the steps. The step where you run helloWorld.deposit(500).then(console.log)...so i get the error here saying "helloWorld.deposit is not a function". I dont know how to get past this. Then the same error occurred while running helloWorld.balance.call() Thanks in advance
Yes, Arvind, I tried both ways. 1) by declaring the variable helloworld (var helloworld = helloworld.deployed()) 2) by not doing the above step and running (helloworld.balance.call()) In both the cases I am getting the error: Cannot read property 'call' of undefined Any advice will be helpful!
Problem Solved! Truffle has changed the way (from syntax point of view: for worse ) you call a function (like balance) as: HelloWorld.deployed().then(function(instance) { return instance.balance.call(); }).then(function(balance) { console.log(balance); }); Read complete answer on the Ethereum SE ethereum.stackexchange.com/questions/11935/problem-with-truffle-console-cannot-read-property-call-of-undefined
Could anyone tell me what's the difference of a smart contract vs digital signature from Bitcoin? Are they the same thing? or does a digital signature lie inside the smart contract?
Hey Jordan. I am trying to follow the tutorials on monax but to test the contract there I have to transfer funds from an account to contract. I know how to transfer them from account 0 to 1, using console, its easy: web3.eth.sendTransaction({from:web3.eth.accounts[0], to:web3.eth.accounts[1], value: web3.toWei(1000, "ether")}) but when i try to transfer them on the contract addres, i get errors. To get my deposit address i type: FundManager.deployed().deposit().then(console.log) i also tried: FundManager.deployed().address but when I am trying to transfer there my virtual ether: truffle(default)> web3.eth.sendTransaction({from:web3.eth.accounts[0], to:FundManager.deployed().deposit(), value: web3.toWei(1000, "ether")}) or truffle(default)> web3.eth.sendTransaction({from:web3.eth.accounts[0], to:FundManager.deployed().address, value: web3.toWei(1000, "ether")}) I get error. How do I do it properly? Thanks.
Nice! Though for an absolute beginner in this space, it'd be great to understand how to install truffle. As it requires npm this created a bunch of yak-shaving I've still yet to resolve.
***** nice that's really useful. Please let me know when you figure all that out. Any sneak previews in the meantime would be good I'm doing a workshop on Monday and leg-ups would be most appreciated.
contract Bank{ function deposit(uint amount) public { } function balance() internal view returns (uint) { } } contract myFirstContract is Bank{ } 1 ) If function deposit in Bank is public after compile i can access it from myFirstContract but function balance is internal, why can't i access it after compile from myFirstContract? 2) If myFirstContract is not inherited from Bank ie, contract myFirstContract { } Can i still access deposit function of Bank as it is public or i have to necessarily inherit Bank in to access it? If you could help me with this question asap that would help me.
browser/1.sol:1:1: Warning: Source file does not specify required compiler version!Consider adding "pragma solidity ^0.4.17? how to deal with it? thanks
Great video. "It's not so different from normal programming" Yeah, unless you start to think about race conditions, non-honest miners, opponents peeking into transactions before they are mined and act accordingly, and millions of other stuff :) I would say SECURITY and secure programming are the pain points of smart contracts, since they are immutable and open-source.
Hey, Jordan, Great stuff. Who's the other guy? He seems to know smart contracts at a low level but gave far too many "I don't know" or "I believe" answers to your (necessary) questions. Non-authoritative answers just leave us hanging. Do you have a definitive guide to smart contracts? Dave
Excellent tutorial!! This is so much better than most videos I have come across. I have question with mapping type. I see that the variable "balances" stores the "value" in the "key=>value" pair for the associative array created. Is there a way to store the "key" values too in a variable? If yes how?
I'm going to be honest and say I am a noob to all to solidity and programming in general but I know blockchain technology is something you should learn. Jordan where should I start to set a good foundation? Any help would be greatly appreciated. Thanks
hii awesome video!! men one stupid question why in my atom editor, when i write code in . sol contracts my code doesnt turn in colors??? do u know what it is? tksu alot
apm install linter #if you don't have AtomLinter/Linter installed apm install linter-solidity close your project, then reopen and linter will run through installation
Are you executing the last contract which these guys have created? Note that there is no function/ constant named balance. It was existing in the second last contract.
You can no longer do helloWorld.balance.call. It is now: HelloWorld.deployed().then(function(instance) { return instance.balance.call(); }).then(function(balance) { console.log(balance); });
im not sure. I think the point is that you can get a object of your contract. You could try writing function specifically to explore the contract, but i just skipped ahead.
TypeError: helloWorld.desposit is not a function at evalmachine.:1:12 at ContextifyScript.Script.runInContext (vm.js:35:29) at Object.runInContext (vm.js:89:6) at TruffleInterpreter.interpret (/usr/local/lib/node_modules/truffle/build/cli.bundled.js:213786:17) at bound (domain.js:280:14) at REPLServer.runBound [as eval] (domain.js:293:12) at REPLServer. (repl.js:538:10) at emitOne (events.js:96:13) at REPLServer.emit (events.js:188:7) at REPLServer.Interface._onLine (readline.js:233:10) deposit is alreedy defined....! i tried reseting but nothing happened.! what happeninig?
NOTE: The text length of your variable and functions names do not matter. Like HelloWorld costs just as much Gas as naming it Hello or H. At first I thought minimizing the text reduced cost but comments and size of variable names do not matter I believe because the compiler doesnt care about them. So name your variables descriptively and add many comments. =)
Great tutorial. Thanks for sharing your thoughts. I´m having a problem with the basic call method for the balance (querying the balance). I created a post here: ethereum.stackexchange.com/questions/11935/problem-with-truffle-console-cannot-read-property-call-of-undefined Any idea??
Hi, FYI: the API has changed, so if you´re using truffle 3.x.x, you should run the following code: HelloWorld.deployed().then(function(instance) { return instance.balance.call();}).then(function(balance) { console.log(balance);}); to get the balance!
Hi Wojtek, Thanks for solution mentioned here. I tried this out and I get the below message. Would you be able to help please? TypeError: Cannot read property 'call' of undefined at evalmachine.:1:72 at process._tickDomainCallback (internal/process/next_tick.js:129:7)
HelloWorld is the contract deployed and HelloWorld.deployed() object is displaying all the contract related methods and properties (sorry about the jargon)
this is much more helpful than the 4 weeks i've spent on a paid ethereum developer course...
is this the one on udemy?
Thank you Mr Scott, now i see the reason why everyone is spreading your name on every blog and media, calling you a trade god, i wish every trader can be so nice and kind like you, thank you sir for sharing your great strategy with me, i just made my first $18k within the first week of trading with your strategy, Am grateful sir.
with his strategy i have been able to save more than enough for my daughter to go college, scotts strategy is so reliable
My life changed for the best the first day i saw Scott's video, he made me to understand a lot more about trading forex/binary options and now i can trade with out the fear of losing
Hello am a newbie and I would like to know about Mr Scott's strategy, how it works and how do i contact him for information about his strategy? Please I need a reply ASAP
You can reach him via his personal GMAIL :: scottadrian1952@gmail.com
Guys well done, this has been incredible. Im moving over from bitcoin into ethereum and this is the first video that I've seen that goes into great detail - great questions asked by Jordan - know you know most of the answers already but you relate to what people might be wondering and then ask great questions - very powerful. Well done
Great video, man. I love how you always stop to ask the important clarifying questions, no matter how small or simple they might seem. Even if you already know the answer. Really good habit for instructional purposes. Much love from UMD.
Wow, you guys are so smart. You made this video in a way that it is easy to understand the basic installation and getting started. With all questions, smartely asked already in the process.
Guy on the right looks like a young Erlich Bachman during the Aviato days...
Hey Jordan, thanks for existing. Don't stop existing
As someone who's semi new to programming and completely green with Solidity, thank you. Trying to get a course listed at my college for solidity.
Hey guys, just wanted to say that as an introduction this was really informative content. Perfect level of detail. Thanks for sharing.
Great video! Really helpful!! I've been looking at Ethereum for a while and couldn't understand where to start. This video is the best 101 introduction out there. Thanks again!
damn. one of the most helpful videos for newbies wanting to learn! well done. watched the whole thing end to end.
Need to add pragma
```
pragma solidity ^0.4.8;
contract HelloWorld {
uint public balance;
function HelloWorld() {
balance = 1000;
}
}
```
When i wake up thinking, im gonna be an ethereum developer and get paid lots of money, im reminded of reality.
i suppose i understand, but smart contracting and all these moving parts make me think again
Truffle change to call this way
```
HelloWorld.deployed().then(a => console.log(a.address))
```
HelloWorld.deployed().then(a => console.log(a.balance().then(console.log)))
I was looking for it!
Or using helloWorld variable: helloWorld.then(a => console.log(a.balance().then(console.log)))
with promise chaining:
HelloWorld.deployed().then(a => a.balance()).then(console.log);
29:16 That is an instance of bignumber, required by and often returned by web3. Its toString function is already re-implemented to print the number in decimal form, but you didn't call toString on it, so it appears like that.
You'd have to access c from within the callback. What you did would try to read c from the promise returned by .then()
If you are just watching and having problem with migrating around 22:00 check if you have testrpc running. Also - the truffle that I have downloaded (4th May 2017) need to include "artifacts.require" in the deploy migration file.
Hey I know those guys!!
Good stuff fellas - SF Ethereum Devs 4 lyfe ;)
the way he said "i--i-i don't,..... the marmot stuff is kinda weird"
that had me ROFL
I'm about to gif you at 24:45 haha !
Anyway this video is really neat I've some background on this but I was kinda lost and this video clear/reset/put in order all things you have already learn or see and it's reaaaally effective ! I don't even finish this video I'm sure to follow the other.
NICE JOB!
29:17 It's a BigNumber format. Basically it's there to take care if number becomes too big for JS to handle it natively.
Thanks for the video - very informative. Keep up the good work...
Hey guys! Stumbled across your channel and this video is extremely informative and valuable. Being an aspiring smart contract developer myself, I find that I learn best through someone demonstrating and explaining what they are doing line by line. You are doing a fantastic job of that - it's definitely helping me out here in South Korea!!
Just one quick question, how are you broadcasting videos at the same time on the lower right corner? Are you using OBS and multiple cams? What video talk software are you using? How are you setting your bitrate and does your bandwidth not lag?
We are also a blockchain channel over in Korea and just getting started on this RUclips thing. Would be a tremendous help if you could offer some tips.
Have a fantastic day!! Keep those smart contract dev videos coming!!!!! ;)
Thx for replying!!!! :)
Hey, also an aspiring smart contract developer in Korea. I'll check out your channel! Don't speak Korean though.
Didn't even realize you guys were in the same room until the high five at the end lmao
Great video! Small recommendation: it would have been great if you could make a video setting up your development configuration. Installing truffle, testrpc, geth, etc. Other than that, perfect!
Great! Thanks! By the way, these are the best ethereum dev tutorials that I've seen!
This is great man, thank you for doing these!
Great tutorial. Please switch your keyboard to a silent one. It makes a lot of noise when you type and listening you guys is way more fun that the key taps. :)
Thanks for uploading this, is very informative.
That is a very cool video, cleared a lot of things to me, thanks to Jordan and his pal. Can you also make or point me to some resources to understand how to interpret the data fields in a block.
hello, is it possible to import like a string or numbers from a text file using the solidity programming?
If anyone is having issues compiling the HelloWorld contract be sure to add "pragma solidity ^0.4.4;" on the first line of your HelloWorld file.
Hi! First of all thank you very much for this tutorial. I'll be watching the next ones very soon. I have just one question about the end of the video: I can't manage to migrate to the geth --testnet instead of testrpc, I run the synced testnet and then "truffle migrate" and it gives me back an error. What changes do I need to do to the truffle.js file in order to migrate it to the geth testnet?
Thanks a lot and keep up the good work :)
I tried this on [video time 26.51], my truffle doesn't return a promise. it just returns the data. Could this be a truffle update?
@46:00 public accessor functions are created for mappings also which can be called by providing a key as the parameter.
e.g.
mapping (address => uint) public foo;
> someContract.foo('0x.....');
goo.gl/DNTG5u
Now you have to use a new syntax to store the helloworld var you have to go in the truffle console :
HelloWorld.deployed().then(function(instance){helloworld=instance})
and the deposit function should be payable as so :
function deposit(uint _value) payable returns(uint _newValue)
Hi Luke first of all thank you so very much you helped save a lot of my time, secondly I would like to ask you where or how did you learn about this so that I may continue my study in that section, once again thank you very much and I am truly grateful for this piece of information.
Ahmed Hamadto I figured it out thanks to the documentation of truffle. But it isn't obvious I found. that's why I wrote it down here. I guess it have to do with the fact that the functions return promises so you can't set the result to a variable, you have to use .then() to handle the return of the promise and set it to the variable in case of success. More on functional programming on MPJ's amazing channel +funfunfunction
Hi, Luke! So if I want to check my balance how the syntax should change?
Rajat Goel it shouldn't. What changes the most is the creation of the contract object. after you call your functions with the dot. syntax. contract.function(parameters)
Hello guys, thanks a lot for your valuable input. What I still ask myself is the block thing. A smart contact is stored in a block. Transactions which change the state of a smart contract are also stored in blocks. How do the blocks then reference the smart contract? Do the tx contain the address of the smart contract plus the new status or how is this being handled?
Guys need some help here. I believe there were changes in the truffle directory structure as per their documentation. I just tried truffle init and I only get contracts, migrations, test, and truffle.js in the root directory. I am missing the app and build folders, and i do not have the 2_deploy_migration.js file. I am using Windows 10 32-bit. I'm not sure if I should just proceed. Any help would be great. Thanks!
Great vid, very useful!
Hi! I don't get the part when you start testrpc. You do it from geth console? Could you please explain the steps for someone to start testrpc? Thanks!
(1) Install it using NPM. In Linux you can execute the following command
sudo npm install -g ethereumjs-testrpc
or if you are using NodeJS 4.6.0
sudo npm install --unsafe-perm -g ethereumjs-testrpc
(2) In your command line execute the following:
testrpc
This is so awesome !!
How is the transfer function transactional? Is it just transactional automatically? Or do you have do anything to make sure that it is transactional?
Can someone explain to me whey I can't see all the functions on the right side of the page "bytecode" "interface" etc Mine looks different and only shows "Environment" "account" Gas limit etc Thanks!
Gotcha
Jordan -
have added a repo for both peoplelistui and peoplelist on github, so that people who may need to look at the code can do. Hope it's all right.
peoplelist: github.com/apraka16/peoplelist
peoplelistui: github.com/apraka16/peoplelistui
Great! took me a while but works!
Hello? Sorry but can I find the other parts of it anywhere? Link is broken :/
Good stuff guys thanks for this
hi jordan , my balances of the account1 still shows 0 even if i initialized to 1000 , can you help me understand, whats going on here?
Hey does anyone have any idea how to host a react site like this on AWS S3? I tried uploading it to AWS but whenever I load the site its just a blank screen. Any ideas? Thanks
Hey, I had a problem in one of the steps. The step where you run helloWorld.deposit(500).then(console.log)...so i get the error here saying "helloWorld.deposit is not a function". I dont know how to get past this. Then the same error occurred while running helloWorld.balance.call()
Thanks in advance
Hey Rajat...I wonder if you first made a var helloWorld and assign it the helloWorld.deployed() response like he did?
Yes, Arvind, I tried both ways.
1) by declaring the variable helloworld (var helloworld = helloworld.deployed())
2) by not doing the above step and running (helloworld.balance.call())
In both the cases I am getting the error: Cannot read property 'call' of undefined
Any advice will be helpful!
Problem Solved!
Truffle has changed the way (from syntax point of view: for worse ) you call a function (like balance) as:
HelloWorld.deployed().then(function(instance) {
return instance.balance.call();
}).then(function(balance) {
console.log(balance);
});
Read complete answer on the Ethereum SE
ethereum.stackexchange.com/questions/11935/problem-with-truffle-console-cannot-read-property-call-of-undefined
Cool.. Thanks!
Im having the same error with deposit!! could you tell me the exact command line please? thanks
on windows type truffle.cmd compile or truffle.cmd migrate.
otherwise your truffle.js will attempt to be executed and you will get an error.
Could anyone tell me what's the difference of a smart contract vs digital signature from Bitcoin? Are they the same thing? or does a digital signature lie inside the smart contract?
What program are you using to share screen/keyboard with your co-host/guests?
I think they are in the same room
Hey Jordan. I am trying to follow the tutorials on monax but to test the contract there I have to transfer funds from an account to contract. I know how to transfer them from account 0 to 1, using console, its easy:
web3.eth.sendTransaction({from:web3.eth.accounts[0], to:web3.eth.accounts[1], value: web3.toWei(1000, "ether")})
but when i try to transfer them on the contract addres, i get errors. To get my deposit address i type:
FundManager.deployed().deposit().then(console.log)
i also tried:
FundManager.deployed().address
but when I am trying to transfer there my virtual ether:
truffle(default)> web3.eth.sendTransaction({from:web3.eth.accounts[0], to:FundManager.deployed().deposit(), value: web3.toWei(1000, "ether")})
or
truffle(default)> web3.eth.sendTransaction({from:web3.eth.accounts[0], to:FundManager.deployed().address, value: web3.toWei(1000, "ether")})
I get error. How do I do it properly? Thanks.
It looks like latest truffle 3.0 produce ABI json directly, not a JS file it's also based on contract name, not a filename
am in africa n i have a fully synced node n i mine. so yes, we try
@22:00 - @23:20 package management on the fricken blockchain/merkle tree!
Nice! Though for an absolute beginner in this space, it'd be great to understand how to install truffle. As it requires npm this created a bunch of yak-shaving I've still yet to resolve.
***** nice that's really useful. Please let me know when you figure all that out. Any sneak previews in the meantime would be good I'm doing a workshop on Monday and leg-ups would be most appreciated.
have you done this yet, as on windows truffle did seem to comlicate and produce loads of errors
at truffle migrate, im getting an Invalid JSON RPC response
Which language do they use? Can I use python for solidity? Help me please Im confused
contract Bank{
function deposit(uint amount) public {
}
function balance() internal view returns (uint) {
}
}
contract myFirstContract is Bank{
}
1 ) If function deposit in Bank is public after compile i can access it from myFirstContract but function balance is internal, why can't i access it after compile from myFirstContract?
2) If myFirstContract is not inherited from Bank
ie, contract myFirstContract {
}
Can i still access deposit function of Bank as it is public or i have to necessarily inherit Bank in to access it?
If you could help me with this question asap that would help me.
Have you guys ever looked at any transactive contracts ?
browser/1.sol:1:1: Warning: Source file does not specify required compiler version!Consider adding "pragma solidity ^0.4.17?
how to deal with it? thanks
Do what it says. The first line in your code should be "pragma solidity ^0.4.17" (without the quotes)
Are either of you available to help out with an ICO?
Great video. "It's not so different from normal programming" Yeah, unless you start to think about race conditions, non-honest miners, opponents peeking into transactions before they are mined and act accordingly, and millions of other stuff :) I would say SECURITY and secure programming are the pain points of smart contracts, since they are immutable and open-source.
I would be really glad if security was emphasized enough (or even mentioned ^^ )
Hey, Jordan,
Great stuff. Who's the other guy?
He seems to know smart contracts at a low level but gave far too many "I don't know" or "I believe" answers to your (necessary) questions. Non-authoritative answers just leave us hanging. Do you have a definitive guide to smart contracts?
Dave
Excellent tutorial!! This is so much better than most videos I have come across. I have question with mapping type. I see that the variable "balances" stores the "value" in the "key=>value" pair for the associative array created. Is there a way to store the "key" values too in a variable? If yes how?
Also why is the contractAddress for a given transaction always set to null?
truffle(development)> hello.then(function(instance) { return instance.transfer(acc2, 1)}).then(console.log)
{ tx: '0xd33622cd36687073feecc0ff8814d15783505fd7a97626270dc8beab3e937548',
receipt:
{ transactionHash: '0xd33622cd36687073feecc0ff8814d15783505fd7a97626270dc8beab3e937548',
transactionIndex: 0,
blockHash: '0x4cfe64b3c11eccc44123a6c999287e7fdaaed6785c060d3c6f35a98b9537f2df',
blockNumber: 6,
gasUsed: 48618,
cumulativeGasUsed: 48618,
contractAddress: null,
logs: [] },
logs: [] }
Woah! I had no clue about this.
I'm going to be honest and say I am a noob to all to solidity and programming in general but I know blockchain technology is something you should learn.
Jordan where should I start to set a good foundation? Any help would be greatly appreciated.
Thanks
+Jordan Leigh (AlwaysBCoding) alright thanks. I have
how do you set it up to use truffle init command?
Install truffle sir!
$ sudo npm install -g ethereumjs-testrpc (for Mac)
apmanga.livejournal.com/3051.html
hii awesome video!! men one stupid question why in my atom editor, when i write code in . sol contracts my code doesnt turn in colors??? do u know what it is? tksu alot
apm install linter #if you don't have AtomLinter/Linter installed
apm install linter-solidity
close your project, then reopen and linter will run through installation
thanks!
truffle(development)> helloWorld.balance.call()
TypeError: Cannot read property 'call' of undefined
Can someone please explain this error to me?
Are you executing the last contract which these guys have created? Note that there is no function/ constant named balance. It was existing in the second last contract.
How do I call deposit function ? and pass the parameter ?
var helloether
HelloEther.deployed().then(function(a) { helloether = a; })
helloether.deposit(500).call(console.log)
Thanks for creating the video. Can you help me with a question? Can Ethereum Smart Contract be used to receive and send bitcoins?
You can no longer do helloWorld.balance.call. It is now:
HelloWorld.deployed().then(function(instance) {
return instance.balance.call();
}).then(function(balance) {
console.log(balance);
});
This isn't working for me either. I get instance.balance is undefined. Any tips?
im not sure. I think the point is that you can get a object of your contract. You could try writing function specifically to explore the contract, but i just skipped ahead.
he wrapped that up so good lmao
I thought doubly linked list data structure was commonly known.
TypeError: helloWorld.desposit is not a function
at evalmachine.:1:12
at ContextifyScript.Script.runInContext (vm.js:35:29)
at Object.runInContext (vm.js:89:6)
at TruffleInterpreter.interpret (/usr/local/lib/node_modules/truffle/build/cli.bundled.js:213786:17)
at bound (domain.js:280:14)
at REPLServer.runBound [as eval] (domain.js:293:12)
at REPLServer. (repl.js:538:10)
at emitOne (events.js:96:13)
at REPLServer.emit (events.js:188:7)
at REPLServer.Interface._onLine (readline.js:233:10)
deposit is alreedy defined....!
i tried reseting but nothing happened.!
what happeninig?
= Describe why it’s hard to code a random number generator in Ethereum. Summarize a few reasons why most intuitive solutions fail
NOTE: The text length of your variable and functions names do not matter. Like HelloWorld costs just as much Gas as naming it Hello or H. At first I thought minimizing the text reduced cost but comments and size of variable names do not matter I believe because the compiler doesnt care about them. So name your variables descriptively and add many comments. =)
Informative tutorial, But can you guys try not to talk at the same time and not cut off each other ?
Thanks guys. Too bad the one guy didn't know how to talk to people. Lol
Great tutorial. Thanks for sharing your thoughts. I´m having a problem with the basic call method for the balance (querying the balance). I created a post here: ethereum.stackexchange.com/questions/11935/problem-with-truffle-console-cannot-read-property-call-of-undefined
Any idea??
Hi, FYI: the API has changed, so if you´re using truffle 3.x.x, you should run the following code:
HelloWorld.deployed().then(function(instance) { return instance.balance.call();}).then(function(balance) { console.log(balance);});
to get the balance!
Hi Wojtek, Thanks for solution mentioned here. I tried this out and I get the below message. Would you be able to help please?
TypeError: Cannot read property 'call' of undefined
at evalmachine.:1:72
at process._tickDomainCallback (internal/process/next_tick.js:129:7)
HelloWorld is the contract deployed and HelloWorld.deployed() object is displaying all the contract related methods and properties (sorry about the jargon)
@Wojtek Hejna - Thank you. IT WORKED. As the message says I was using the property 'balances' instead of 'balance' in my contract.
@Prashanth Kumar: great, I am happy that you figured it out!
"Africa are you even trying" hahaha!
52' nice..
holy shit are you Silas Weir Mitchell
aka Haywire from prison break
cant watch this. one guy is so laud, and the other is so quiet.
1:06:46 africa are you even trying lol