0

Ask for help: compile OK, deployed OK push action OK, chain show error:

[22:50:57.901] debug Produced block 3a21a2476657b28e... #25666 @ 2021-05-01T05:50:58.000 signed by eosio [trxs: 0, lib: 25665, confirmed: 0]
[22:50:58.359] error params: {"account_name":"depsingleton","pos":-1,"offset":-25} 
[22:50:58.359] info  pos: -1 
[22:50:58.359] info  start: -3 end: 22 
[22:50:58.400] debug Produced block dd0c3a3a16c8551b... #25667 @ 2021-05-01T05:50:58.500 signed by eosio [trxs: 1, lib: 25666, confirmed: 0]

The code is here:

ACTION depositnlock::modsettings(uint32_t sp, uint32_t m){
   check( has_auth( get_self() ), "Provide permission to set stake percetage");
   /*
   auto the_settings = _settings_instance.get_or_create( get_self(), defaultsets );
   /*
       the_settings.stake_percentage = sp;
       the_settings.minimum_stake_time = m;
       _settings_instance.set( the_settings, get_self() );
   */
}

1 Answer 1

1

I cleaned up your question because it was unreadable. Please learn how to properly ask and format questions here.

The code you posted is still so badly formatted that it says the code for reading/creating and setting the singleton is commented and therefore neither compiled nor executed but I didn't want to change the whole text.

By interpreting the error message you posted it looks to me like your defaultsets is invalid but that's uncertain. Please post more - and correctly formatted code so that we can help.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.