Skip to content

Commit

Permalink
GLEEC_OLD: exception to fix following the notarizations (#637)
Browse files Browse the repository at this point in the history
* GLEEC_OLD: exception to fix following the notarizations

This configuration assumes that we have the `~/.komodo/GLEEC_OLD`
directory for the old GLEEC chain. The daemon should be launched
with `-datadir=$HOME/.komodo/GLEEC_OLD`, and the data directory
should contain `GLEEC.conf` along with a symlink to it
named `GLEEC_OLD.conf`.

* timeshifting transient verb

---------

Co-authored-by: smk762 <[email protected]>
  • Loading branch information
DeckerSU and smk762 authored Oct 17, 2024
1 parent bf8ace3 commit 820fe50
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/chainparams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -951,6 +951,9 @@ const CChainParams::CCheckpointData GetACCheckPoints()
// Check for GLEEC chain with old and new parameters
if (chainName.ToString() == "GLEEC") {
if (ASSETCHAINS_SUPPLY == 210000000 && ASSETCHAINS_STAKED == 100) { /* old GLEEC */
ClearDatadirCache();
chainName = assetchain("GLEEC_OLD"); /* exception to fix following notarizations,
we shouldn't do things like that! */
return checkpointDataGLEECOld;
}
return checkpointDataDefault; // TODO: return new checkpoints, when we will have enough data
Expand Down
9 changes: 9 additions & 0 deletions src/komodo_utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1006,6 +1006,15 @@ void komodo_args(char *argv0)
uint16_t nonz=0; // keep track of # CCs enabled
int32_t extralen = 0;

// prevent starting old GLEEC chain without datadir specified
if (GetArg("-ac_name","") == "GLEEC" && GetArg("-ac_supply",10) == 210000000 && GetArg("-ac_staked",0) == 100) {
if (mapArgs.count("-datadir") == 0) {
const std::string strOldGLEECStartUpError = "It's mandatory to launch old GLEEC chain with -datadir specified!";
std::cerr << strOldGLEECStartUpError << std::endl;
throw std::runtime_error(strOldGLEECStartUpError);
}
}

const std::string ntz_dest_path = GetArg("-notary", "");
IS_KOMODO_NOTARY = ntz_dest_path == "" ? 0 : 1;

Expand Down

0 comments on commit 820fe50

Please sign in to comment.