5 votes
Accepted

Are EOS smart contract self executing? Can a contract monitor an external API call from a weather site and send a transaction if it's sunny?

If not do I need to have cron run every minute on my system and monitor the weather api and if its sunny, it will execute the smart contract on EOS? Yes, you'd need to make an explicit call to the ...
confused00's user avatar
  • 5,554
4 votes
Accepted

In the eosio.token contract, why are the structs private?

The contract rightfully encapsulates the implementation details as private. Instead, it provides the following function as the public interface: static asset get_balance( name token_contract_account,...
Gassa's user avatar
  • 598
3 votes
Accepted

How to send a data from on contract to other?

Take a look at inline actions (executed in the same transaction) or deferred transactions (executed in another transaction. Inline Actions The link refers to the official developer portal. Inline ...
tmm's user avatar
  • 2,114
2 votes

no member named 'check' in namespace 'eosio'

You need to include eosio.hpp before the other includes. #include <eosio/eosio.hpp> Sidenote: this actually seems to be a problem with cdt 1.6.1 and will hopefully be fixed with next releases ...
cmadh's user avatar
  • 1,919
2 votes

How do I confirm that the person sending an action is the same as a user in the parameter?

require_auth(user) will ensure the sender of the transaction has the correct permission, which is what you're intending. Perhaps the way you're calling the action is incorrect? When using cleos push ...
Jason Bert's user avatar
1 vote

how to make sure the tx to be included in block

to get a better understand of how transactions make it to a block please read the following series of FAQs starting with this one and all that follow till the end. I hope it will help understand the ...
ovi's user avatar
  • 371
1 vote
Accepted

template function in contract code with a lambda

template <typename T, typename Lambda> void migrate_table(name code, uint16_t batch_size, name source_scope, name destn_scope, Lambda&& mapper) { T source(code, source_scope.value); ...
conr2d's user avatar
  • 2,290
1 vote

fatal error: 'future' file not found

It isn't possible to use future in smart contracts, because the whole thing is single-thread C++. Multithreading isn't supported and wouldn't work within the contract because it would potentially make ...
Phillip Hamnett - EOS42's user avatar
1 vote

Makefile Compiler Error

In recently version of eos_compiler. Some data type are deprecated. including account_name .. downgrade your compiler or edit code, or add typedef yourself. good day :)
leettamna's user avatar
  • 102
1 vote

EOS CDT: where are the *.h and the *.cpp files stored in the filesystem, I need reference to them to compile

using the command: dpkg -c eosio.cdt-1.3.2.x86_64.deb The folder where the files are installed are shown: the CDT files are stored in /usr/opt/eosio.cdt/
Luther's user avatar
  • 175
1 vote
Accepted

Why smart contract function fails with "Error 3090004: Missing required authority"?

The issue was inside an emplace(). Basically, I was not setting the payer. After, hard coding the payer as N(mycontract), I don't get the error anymore and the functions work correctly.
Riccardo Persiani's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible